Jump to content
Salesforce and other SMB Solutions are coming soon. ×

Assigning value based on last name


Mr. Bungle

Recommended Posts

Hi everyone-

 

I have a database that has a last name field and I would like to build calculation that assigns a value from a value list based on the first 2 characters in the last name field. I know there's a simple and effective way to do this, but maybe it's Friday-itis; I just can't see the solution in my head.

 

I've already created the calculation field that looks at the last name field and takes the first 2 characters, but how do I specify the alpha range in a calculation? I'd like it to look at this 2-character field and go "if the value is between A and DD, then select Value A. If the value is between DE and KE, then select value B, etc"...

 

Thanks,

 

Mr. B

Link to comment
Share on other sites

In addition to your Last Name field and your calculation field which takes the first two letters, you need a third field, (usually a global text field), which is where you SELECT which pair of letters you're interested in at the moment; your value list attached to the text global can be all values of CalcFieldFirstTwoLetters.

 

Then you have your actual field into which you want to pull the entire last name from a list of last names that start with those two letters. The value list attached to this would be related values only, via relationship of the global field to the CalcFieldFirstTwoLetters, of Last Name.

Link to comment
Share on other sites



×
×
  • Create New...

Important Information

Terms of Use