SubForm or what?

T

Tony S.

I have imported files from an excel spreedsheet into a new database in an
attempt merge some fields. In previous years this data was provided to me
with patient data being on "one" row with certain fields that have different
dates being denoted with the test perfomed and the letter of the month beside
it ex: hgbo for hemoglobin october. This year the contractor split the data
into "three" different rows to accomodate the three different months of tests
instead of the one row with three columns. How can I get this in the form I
need it? Do I create a subform or write a query? There are some 7k records
in this file. please help
 
T

TonyT

Hi Tony S,

Sounds like a job for a recordset loop code in vba to me, probably the
easiest way to concatenate various fields over various rows as you have the
ability to perform various if/then or Select Case options as you parse the
data.

If you can post some examples of data in actual row and column format
(awkward in small window), I'm sure someone will be able to post code
examples or get you started.

TonyT..
 
T

Tony S.

Here is the old and new format ( I want to get back to the old format).
Obviously, there are a more than just hemoglobin (hgb) tests in the data so I
need a solution that I can customize to accomodate those too.

Old format:
idnum hgbo hgbn hghd eporxo eporxn eporxd
0001 12.2 12.3 12.4 12.1 12.2 12.3

New format:
idnum hgb hgbdate eporx
0001 12.2 10/03/06 12.1
0001 12.3 11/03/06 12.2
0001 12.4 12/03/06 12.3
 
Top