How to match events in a table?

padlocked17

Registered User.
Local time
Today, 17:15
Joined
Aug 29, 2007
Messages
276
I have a table called tblTasks where the Task_ID has two tasks that are very similiar. One is called AS11 and another is called SAS11. I want to create a query where all of the events that have an "S" in front of the "AS11" or other text such as "P190" are correctly "paired" together so that I can then pull dates for each event and get them to display on the same line in a report.

Does that make any sense and could anyone provide me some insight?
 
are you pulling these tasks by using a form? OR how are you going about doing it?
 
The table was created and then data appended from a linked text source. The table is structured like the following:


Code:
[U]TaskID(PK)[/U] [U]Task_ID[/U] [U]TaskTypeID[/U] [U]Remarks[/U]
3             AS11     1
4             P190      1
5             SAS11   2
6             SP190    2


The TaskTypeID is simply a table that defines the type of event. All of the events that has the "S" appended to the front of Task_ID has a TaskTypeID of 2.
 
Well my question is how are you going to choose what ones you want to show in the report? Or do you want to show all of the records at once and just have them grouped on the same line?
 
All of the tasks will be placed on the report. I'm planning on using the TaskTypeID as the filter for which section on the report to display the certain Task_ID.

The way I'm building the database is that it will be run once a day and PDF files of the report will be generated and available over a network share for download.
 
OK now I'm confused. You want to have them both on the same line, but separate them based on the tasktype?

Thought you wanted something like

AS11 1 SAS11 2

returned so they were on the same line?
 
Yeah I can see how I could confuse with that last statement. The events with TaskTypeID of 1 are events that are completed physically. The events with TaskTypeID of 2 are events that are completed electronically. I was originally going to create two columns on the report and use a subreport so that each of the Task_ID's were on the same line. Then I though, why duplicate and make that additional work when all I really need to do is pair them together. So while they have unique TaskTypeID's right now, that field is more or less a way to differentiate the type of task they are. I would still like to get them on the same field.

I thought I could use some type of Like *XXX statement in a query but haven't been too successful.

I also thought about creating a new table that has a TaskID and a CreditAsTaskID that will pair their PK's in a separate table and I could then run a query on the table that way. I was basically trying to avoid this since I think it might be an extra table and set of data to maintain when I don't necessarily have to I don't think.

I
 
Well ATM you have no way to tie those 2 tasks together, besides the fact that they have similar names.

Is this how the data is presented to you or can you adjust your tables?

I think I would design this a little different if I could.

If say AS11 and SAS11 are part of the same job, just different tasks then why not link them that way?

I might not be understanding what is going on with this situation though.
 
Unfortunately this is the way the data is given to me. It's from an old Oracle database that I'm running a Discoverer Browser window and then exporting to a text file.

Unfortunately the database is in no way relational and is making it a pain in the rear. I'm trying to keep as little "clutter" in interpreting the data as I can and that's why I'm looking for some of these solutions.

The way these events work is that one of them is in the simulator and one of them is in an aircraft. The one in the aircraft (AS11) can receive credit for doing the one in the sim (SAS11) but the one in the sim can't receive credit from the one in the aircraft.
 
Can you post an example or just type it in how you want it to look? Im still confused
 

Users who are viewing this thread

Back
Top Bottom