Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

This topic is 5620 days old. Please don't post here. Open a new topic instead.

Recommended Posts

  • Newbies
Posted

This seems to be beyond my skill set. I'm attempting to auto generate a client number based on the following criteria:

First letter of first name

Last letter of last name

M or F for gender

Two digit month of birth

Two digit date of birth

Last three digits of birth year

Last four digits of SSN

The fields I have are:

NameFirst

NameLast

Gender

DOB (date formatted XX/XX/XXXX)

SSN

ClientNumber (the field I need calculated)

If the client information is

Sally Jones ,05/19/1965, XXX-XX-1234

the client number is:

SSF05199651234

Is there any way to do this in a calculation?

Tom

Posted

This is very easy to do - but utterly worthless for any purpose I can think of:


Left ( NameFirst ; 1 ) & 

Left ( NameLast ; 1 ) &

Gender &

SerialIncrement ( "0000000" ; 100000 * Month ( DOB ) + 1000 * Day ( DOB ) + Mod ( Year ( DOB ) ; 1000 ) ) &

Right ( SSN ; 4 )

Posted (edited)

I agree that this information would have limited use.

There is an error in the LastName caluculation, the OP wanted Right one Charater, and Upper.

I amended your calc


Left ( FirstName ; 1 ) & 

Upper (Right ( LastName ; 1 ) ) &

Gender &

SerialIncrement ( "0000000" ; 100000 * Month ( DOB ) + 1000 * Day ( DOB ) + Mod ( Year ( DOB ) ; 1000 ) ) &

Right ( SSN ; 4 )

HTH

Lee

Edited by Guest
  • Newbies
Posted

Thank-you for your quick replies, I see where I was going wrong now.

I agree that this is a nonsense number, however it is required by the state. My tax dollars at work.

Tom

This topic is 5620 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.