Employee Name Character Field

Posted by LegacyUser on 15-Jan-2001 14:42

I have a Manufacturing/Accounting package called Symix which uses Progress V6.2. Within the database, I have an employee file that has a name field. In the database, the employee's last names are listed first followed by a comma, then a space and then the first name. However, when I print payroll checks the name appears in correct order. I am writing a program where I need the employee name to appear in regular order(first, middle, last). How do I program this field to display the name in the proper order? Any help would be greatly appreciated!!!

All Replies

Posted by LegacyUser on 17-Jan-2001 06:13

You could try something along the lines of the following;

surname = substring(namefield,1,(entry(1,namefield,","))

/* this takes the left part of the string up to the comma */

forename = substring(namefield,len(surname) + 2,len(namefield))

/* this takes the rest of the string (the +2 avoids the comma and space) */

"Todd Gladfelter" wrote:

>

>I have a Manufacturing/Accounting package called Symix

>which uses Progress V6.2. Within the database, I have

>an employee file that has a name field. In the database,

>the employee's last names are listed first followed by

>a comma, then a space and then the first name. However,

>when I print payroll checks the name appears in correct

>order. I am writing a program where I need the employee

>name to appear in regular order(first, middle, last).

>How do I program this field to display the name in the

>proper

>order? Any help would be greatly appreciated!!!

Posted by LegacyUser on 17-Jan-2001 07:28

Sorry about that, heres some code thats more likely to produce your results;

surname = entry(1,namefield,',').

forename = substring(namefield,(length(forename) + 2), length(namefield).

Have Fun

This thread is closed