[EpiData-list] Re: EpiData-list Digest, Vol 95, Issue 8

epidata-list at lists.umanitoba.ca epidata-list at lists.umanitoba.ca
Sat Sep 10 13:16:17 CDT 2011


Thank you Jens. It worked perfectly with minor change, as I was looking for
EntryClient as below,

DateAIDS
  AFTER ENTRY
    DateAIDS=DateDiag1
    IF (DateDiag2 < DateAIDS) THEN
      DateAIDS=DateDiag2
    ENDIF
    IF (DateDiag3 < DateAIDS) THEN
      DateAIDS=DateDiag3
    ENDIF
    IF (DateDiag4 < DateAIDS) THEN
      DateAIDS=DateDiag4
    ENDIF
    IF (DateDiag5 < DateAIDS) THEN
      DateAIDS=DateDiag5
    ENDIF
    IF (DateDiag6 < DateAIDS) THEN
      DateAIDS=DateDiag6
    ENDIF
    IF (DateDiag7 < DateAIDS) THEN
      DateAIDS=DateDiag7
    ENDIF
  END
END

I tested, works just fine. THANK YOU!!!

Bijay


On Sat, Sep 10, 2011 at 11:00 AM,
<epidata-list-request at lists.umanitoba.ca>wrote:

> Send EpiData-list mailing list submissions to
>        epidata-list at lists.umanitoba.ca
>
> To subscribe or unsubscribe via the World Wide Web, visit
>        http://lists.umanitoba.ca/mailman/listinfo/epidata-list
> or, via email, send a message with subject or body 'help' to
>        epidata-list-request at lists.umanitoba.ca
>
> You can reach the person managing the list at
>        epidata-list-owner at lists.umanitoba.ca
>
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of EpiData-list digest..."
>
>
> EpiData-list mailing list
> ___________________________________
>
> Today's Topics:
>
>   1. How to select earlier date from multiple dates
>      (epidata-list at lists.umanitoba.ca)
>   2. Re: How to select earlier date from multiple dates
>      (epidata-list at lists.umanitoba.ca)
>
>
> ----------------------------------------------------------------------
>
> Message: 1
> Date: Fri, 9 Sep 2011 14:34:44 -0600
> From: epidata-list at lists.umanitoba.ca
> Subject: [EpiData-list] How to select earlier date from multiple dates
> To: epidata-list at lists.umanitoba.ca
> Message-ID:
>        <CAEHHyTmiNvCm7zPcw+vtxBu2U8biViuecby-OG37jikcg1XG1w at mail.gmail.com
> >
> Content-Type: text/plain; charset=ISO-8859-1
>
> Dear Forum Members,
>
> I was looking a way to select earliest date from multiple date fields.
> Example,
>
> Five date fields with dates as below,
> DateA - 13/01/2002
> DateB - *13/01/2001*
> DateC - 13/01/2002
> DateE - 13/01/2003
> DateF - 13/01/2004
>
> So, the programming to select earliest date (13/01/2001) in the field
> called
> "DateDiagnosis"
>
> Thanks in advance.
>
> Bijay Adhikari, PhD
> CD Epidemiologist
> Regina, SK
>
>
> ------------------------------
>
> Message: 2
> Date: Fri, 09 Sep 2011 22:50:12 +0200
> From: epidata-list at lists.umanitoba.ca
> Subject: Re: [EpiData-list] How to select earlier date from multiple
>        dates
> To: epidata-list at lists.umanitoba.ca
> Message-ID: <4E6A7C04.9070701 at epidata.dk>
> Content-Type: text/plain; charset=ISO-8859-1; format=flowed
>
> On 2011-09-09 22:34, epidata-list at lists.umanitoba.ca wrote:
> > Dear Forum Members,
> >
> > I was looking a way to select earliest date from multiple date fields.
> > Example,
> >
> > Five date fields with dates as below,
> > DateA - 13/01/2002
> > DateB - *13/01/2001*
> > DateC - 13/01/2002
> > DateE - 13/01/2003
> > DateF - 13/01/2004
> >
> > So, the programming to select earliest date (13/01/2001) in the field
> called
> > "DateDiagnosis"
> I have not tested this solution, but I would do something like:
>
> I assume this is in analysis:
> define datetmp <dd/mm/yyyy>
>
> datetmp = datea
> if (dateb < datetmp) then datetmp = dateb
> if (datec < datetmp) then datetmp = datec
> if (dated < datetmp) then datetmp = dated
> if (datee < datetmp) then datetmp = datee
> if (datef < datetmp) then datetmp = datef
> if (dateg < datetmp) then datetmp = dateg
>
> * now the datetmp contains the earliest of the dates mentioned.
>
> regards
> Jens Lauritsen
> EpiData Association
>
>
>
> ------------------------------
>
> ________________________________________
> EpiData-list at lists.umanitoba.ca
> http://lists.umanitoba.ca/mailman/listinfo/epidata-list
>
>
> End of EpiData-list Digest, Vol 95, Issue 8
> *******************************************
>


More information about the EpiData-list mailing list