Creating subset in same file

Creating subset in same file

Post by Occuwizar » Sat, 18 Sep 1999 04:00:00



I have a solution with File A which records visits to a doctor's office. So
if a patient comes in on 9/12/99 with a diagnosis of flu we record that
visit with a self-generating serial number.   If the same patient comes in
with a different problem - say a skin rash - they get another new record
with a different serial number.

The question I have is -  if the patient comes in for a second or follow-up
visit that is related to the flu original visit - how can I create a subset
of all visits (original and followup) that are related to like visits (all
flu visits; all skin rash visits, etc)  without creating a second related
file (which is what we do now).

Is it possible to create a portal that meets these needs and if so how would
you set it up?

Any help would be greatly appreciated!!

 
 
 

Creating subset in same file

Post by Paul Brunea » Sat, 18 Sep 1999 04:00:00


You are so close you won't believe it. You stated it very well:

Quote:> how can I create a subset
> > of all visits (original and followup) that are related to like visits

The answer is called a "self-join" where you relate a file to itself.

I suggest adding a field called something like "originalVisitID". All
subsequent visits (and the original visit too!) would have the ID of the
original visit in originalVisitID. Then you can make a portal and all of
the related visits will show up, with the original visit on the top is
how I would do it.

We do the same thing for orders that were based upon an original earlier order.

Good luck!

PB


> I have a solution with File A which records visits to a doctor's office. So
> if a patient comes in on 9/12/99 with a diagnosis of flu we record that
> visit with a self-generating serial number.   If the same patient comes in
> with a different problem - say a skin rash - they get another new record
> with a different serial number.

> The question I have is -  if the patient comes in for a second or follow-up
> visit that is related to the flu original visit - how can I create a subset
> of all visits (original and followup) that are related to like visits (all
> flu visits; all skin rash visits, etc)  without creating a second related
> file (which is what we do now).

> Is it possible to create a portal that meets these needs and if so how would
> you set it up?

> Any help would be greatly appreciated!!


 
 
 

Creating subset in same file

Post by Glenn Schwand » Sat, 18 Sep 1999 04:00:00


Sounds like you should have 2 databases.  One with just patient information
and one with visit information.  Then you can create a portal in the
patient database (based upon Patient ID) to view all the visit record.  By
adding a calculation field that concatenate the Patient ID with a problem
code in the visit database, you can reduce the portal records to "like
visits".



: I have a solution with File A which records visits to a doctor's office.
So
: if a patient comes in on 9/12/99 with a diagnosis of flu we record that
: visit with a self-generating serial number.   If the same patient comes
in
: with a different problem - say a skin rash - they get another new record
: with a different serial number.
:
: The question I have is -  if the patient comes in for a second or
follow-up
: visit that is related to the flu original visit - how can I create a
subset
: of all visits (original and followup) that are related to like visits
(all
: flu visits; all skin rash visits, etc)  without creating a second related
: file (which is what we do now).
:
: Is it possible to create a portal that meets these needs and if so how
would
: you set it up?
:
: Any help would be greatly appreciated!!
:
:
:
:
:
:

 
 
 

1. Calculated subtotal of a subset of a subset in a file

I'm trying to get a calculated subtotal of a subset of a subset in a file to
appear in a calculated field.

Trades (file) (500 records)
    Account Number (text field) (50 records)
        Ticker (text field) (5 records)
            Net (number field) (5 records)

                looking for sum of 'Net' for those 5 records

Would like to have a calculated field display the sum total of the field
'Net' for all instances of a given stock in a given account.

Any ideas ???

Thanks, Scott

2. Document in several languages

3. Creating a subset database file

4. SB+ Field Names

5. Creating Multiple Subsets Using Replication

6. Reorg shrlevel reference with discard option

7. Tool to create database subset?

8. SQL Client Install

9. Create and Sychronize subsets of your Oracle Database

10. Creating a data subset in a grid

11. Drop down list with only subset of values from other file

12. Subset of Original record - portal or separate file?