[Date Prev][Date Next][Thread Prev][Thread Next]
[Author Index] [Date Index] [Thread Index]
[SQR-USERS Info] [SQRUG Home Page]

Re: Name Format Validation



Tony,

Thank you.  The routine you sent will help me immensely during our remaining
data conversions from mainframe.  What I really need to do is ensure the
name is in the correct format so that the Rotname SQC's can parse the name,
i.e.,

  [lastname] [suffix],[prefix] [firstname] [middle name/initial]

The entry can contain alphabetic characters, spaces, periods, hyphens, and
apostrophes.  Valid entries might include:

    O'Brien,Michael
    Jones IV,James
    Phillips MD,Deanna Lynn
    Reynolds Jr.,Dr. John Q.
    Phipps-Scott,Adrienne
    Knauft,Gunter

So far I've included the Rotname3.SQC and if a resulting lastname or
firstname cannot be determined, the name writes to an error file.


Sandra Hope
DynCorp
hopes@dyncorp.com
New Phone:   (703) 264-8674

RESYSTEMIZATION
PeopleSoft

> ----------
> From:         Tony DeLia[SMTP:tdelia@EROLS.COM]
> Reply To:     SQR-USERS@USA.NET
> Sent:         Monday, January 11, 1999 10:57 PM
> To:   Multiple recipients of list SQR-USERS
> Subject:      Re: Name Format Validation
>
> Hi Sandra,
>    Here's a "quick" routine that will convert names to "PeopleSoft"
> format...
>
> Assuming the variable $name contains 'SMITH,JOE R'...
>
> do ULcase-Format ($name)
>
> $name will now contain... 'Smith,Joe R'
>
> Actually, this isn't really a PeopleSoft 'Name' formatter... I use it
> for various requirements... addresses for example...
>
> 'NEW YORK'         converts to 'New York'...
> '123 SOUTH STREET' converts to '123 South Street'...
> '12 N.LAKE ST.'    converts to '12 N.Lake St.'
>
> It simply forces any character to uppercase that follows a blank, comma
> or period (add additional symbols if needed)... The primary use for this
> routine is converting Mainframe data to PeopleSoft...
>
> Here's the routine...
>
> !**********************************************************************
> !*       Upper/Lower Case Formatting                                  *
> !**********************************************************************
>
> begin-procedure ULcase-Format(:$ULstring)
>
> let $ULdata      = $ULstring
>
> lowercase $ULdata
>
> let #ULlen       = length($ULdata)
> let $ULstring    = ''
> let #pos         = 1
>
> let $ULprev      = ' '
>
> while #pos      <= #ULlen
>
>    let $ULchar   = substr($ULdata, #pos, 1)
>
>    if  instr(' ,.',$ULprev,1) > 0
>        uppercase $ULchar
>    end-if
>
>    let $ULstring = $ULstring || $ULchar
>    let $ULprev   = $ULchar
>    let #pos      = #pos + 1
>
> end-while
>
> end-procedure
>
> !**********************************************************************
>
> This routine is simple but effective...
>
>                                            -Tony DeLia
>
>
>
> Hope, Sandra wrote:
> >
> > Is there a way to capture the existing PeopleSoft Name format validation
> > within an SQR so that data being converted or data already converted
> (via
> > SQR) goes through the PS name format test ?
> >
> > Thanks All.
> >
> > Sandra Hope
> > DynCorp
> > hopes@dyncorp.com
> > New Phone:   (703) 264-8674
> >
> > RESYSTEMIZATION
> > PeopleSoft
> >
> > Sandra Hope
> > DynCorp
> > hopes@dyncorp.com
> > New Phone:   (703) 264-8674
> >
> > RESYSTEMIZATION
> > PeopleSoft
>
> --
> Tony DeLia
> AnswerThink Consulting Group
> PeopleSoft Solutions Practice - Delphi Partners
> tdelia@erols.com
>