Welcome to SPN

Register and Join the most happening forum of Sikh community & intellectuals from around the world.

Sign Up Now!

merging records into one memo field

Discussion in 'Information Technology' started by AMN, Jul 28, 2006.

  1. AMN

    AMN
    Expand Collapse
    Guest

    Hi

    I have a table named History and table named Medications. The key in
    History is EncounterID and there is a memo field in History named MedList.
    The key in Medications is MedicationID and there is a one to many
    relationship between History and Medications tables as one EncounterID can
    have multiple MedicationIDs.

    I would like to write a code to query all the MedicationID data related to a
    certain EncounterID and addthem to the Medlist memo field in a list format.
    Preferable numbered but if that is not possible just as long as they are in a
    list one under the other.

    Thank you,
     
  2. Loading...

    Similar Threads Forum Date
    India Punjab emerging as major drug producing centre Breaking News Mar 13, 2013
    Under-19 emerging sikh cricketers Sports & Fitness Jan 22, 2010
    Merging in the Word Of Sabad Sikh Sikhi Sikhism Jan 26, 2008
    Sikh News Punjab emerging as new international education hub (New Kerala) Breaking News Sep 17, 2007
    Sikh News Punjab emerging as new international education hub (ANI via Yahoo! India News) Breaking News Sep 17, 2007

  3. Michael H

    Michael H
    Expand Collapse
    Guest

    Hi,

    I wouldn't recommend actually placing the data in the memo field. Doing so
    would mean having the same data in two different places in your database,
    which is against the rules of proper database normalization. In order to do
    something like displaying the Medication data on a form, consider just
    placing the data in an unbound TextBox.

    To accomplish this, you may want to have a look at the "Generic Function To
    Concatenate Child Records" sample DB at Roger's Access Library at
    http://www.rogersaccesslibrary.com . Click on "Other Developer Libraries",
    and look under Hookom, Duane.

    -Michael



    "AMN" wrote:

    > Hi
    >
    > I have a table named History and table named Medications. The key in
    > History is EncounterID and there is a memo field in History named MedList.
    > The key in Medications is MedicationID and there is a one to many
    > relationship between History and Medications tables as one EncounterID can
    > have multiple MedicationIDs.
    >
    > I would like to write a code to query all the MedicationID data related to a
    > certain EncounterID and addthem to the Medlist memo field in a list format.
    > Preferable numbered but if that is not possible just as long as they are in a
    > list one under the other.
    >
    > Thank you,
     
  4. AMN

    AMN
    Expand Collapse
    Guest

    thank you very much. This was extremely helpful.

    "Michael H" wrote:

    > Hi,
    >
    > I wouldn't recommend actually placing the data in the memo field. Doing so
    > would mean having the same data in two different places in your database,
    > which is against the rules of proper database normalization. In order to do
    > something like displaying the Medication data on a form, consider just
    > placing the data in an unbound TextBox.
    >
    > To accomplish this, you may want to have a look at the "Generic Function To
    > Concatenate Child Records" sample DB at Roger's Access Library at
    > http://www.rogersaccesslibrary.com . Click on "Other Developer Libraries",
    > and look under Hookom, Duane.
    >
    > -Michael
    >
    >
    >
    > "AMN" wrote:
    >
    > > Hi
    > >
    > > I have a table named History and table named Medications. The key in
    > > History is EncounterID and there is a memo field in History named MedList.
    > > The key in Medications is MedicationID and there is a one to many
    > > relationship between History and Medications tables as one EncounterID can
    > > have multiple MedicationIDs.
    > >
    > > I would like to write a code to query all the MedicationID data related to a
    > > certain EncounterID and addthem to the Medlist memo field in a list format.
    > > Preferable numbered but if that is not possible just as long as they are in a
    > > list one under the other.
    > >
    > > Thank you,
     

Share This Page