Set Value of Field in 1 table based on another table

XcuseBlondeness

Registered User.
Local time
Today, 15:20
Joined
Aug 26, 2004
Messages
11
Please forgive me, I'm just in a serious blonde moment it seems. I'm having a major block on something I'm sure is very simple. I'm also new to SQL language so that's really giving me a run for my money.
I have 2 tables - 1 is only 2 columns DOS and Reading_Dr and is updated each month with a date and a corresponding physician number (the dates are not repeated, but the physician numbers obviously are).
The other table is created each month by importing a csv file from the hospital with several fields, 1 of which is DOS (but in this table it is repeated, of course). This table is never opened by the user, but is the source for the report that gets generated.
My problem is that I need to get the large table to automatically generate the Reading_Dr (a 1 or 2-digit number) based upon the DOS, corresponding to the smaller table's DOS and Reading_Dr.

I'm lost. I've tried append queries, update queries, Dlookup, and I'm just not writing something correctly. It either gives me no data or it puts EVERY DOS/Referring_Dr into EVERY patient on the large table, creating over 350,000 records - AAAAH! I've deleted all queries and just need a little assistance. I'm sure it's something simple, but I just can't seem to get it.
I appreciate any help
 
Yes, I set DOS as primary key in the small table and set up relationship, but at this point I probably did that wrong too - I've tried so many things I've gotten myself confused...LOL
 
when you are in your query design, do you see a line joining your two tables in the upper pane ?
 
Actually, I don't have to update the table necessarily if there's a code snippet I can right for the Reading_Dr field on the report to make it pull that data at the time the report is generated.

Thanks
 

Users who are viewing this thread

Back
Top Bottom