Results 1 to 2 of 2
  1. #1
    KerryA is offline Novice
    Windows XP Access 2000
    Join Date
    Feb 2010
    Posts
    1

    Talking Extracting data after a keyword

    I have a memofield in an Access dB that contains physician dictations. I am trying to capture a patients allergies and place them in a new field if they were dictated. He is an example of a dictation where Allergies is a keyword somewhere in the dictation:



    .....
    Allergies g24
    Sulfa Drugs.
    Allergies to drugs, herbals, foods, radiocontrasts, latex, and environmentals were reviewed with the patient.
    No changes were reported.eg

    I would like to extract "Sulfa Drugs" and place it in a new column. The rest of the information needs to be placed in an additional column.

    Here is a another dictation with a different format using a key word.

    CURRENT MEDICATIONS:
    .
    .
    .

    ALLERGIES:
    SEPTRA AND PROLOPRIM.

    SOCIAL HISTORY:
    .
    .
    .

    Thank you for your assistance,
    Kerry

  2. #2
    llkhoutx is offline Competent Performer
    Windows Vista Access 2007
    Join Date
    Jan 2010
    Location
    Houston, Texas USA
    Posts
    373
    Step 1: Use the InString function to get the character position in the dictation of the character following the string "ALLERGIES:" and call it intStart, integer.
    Step 2: Use the InString function to get the character position in the dictation of the character preceding the string "SOCIAL HISTORY:" and call it intStop, an integer.
    Step 3: Parse all words in the dictation between intStart and intStop, excluding the string "and" and special characters.
    Last edited by llkhoutx; 02-11-2010 at 10:31 PM. Reason: Initial answer was incorrect.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Extracting data from a disastrous excel-style Table
    By milehighfreak in forum Import/Export Data
    Replies: 2
    Last Post: 12-16-2009, 07:13 AM
  2. Replies: 1
    Last Post: 07-10-2009, 07:25 AM
  3. Extracting Database Schema From Access
    By ChloeRadshaw in forum Access
    Replies: 0
    Last Post: 01-29-2009, 04:49 PM
  4. Find data, load data, and save as a new record
    By hawzmolly in forum Access
    Replies: 0
    Last Post: 10-05-2008, 03:18 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums