G
Guest
I am using the following SQL statement. I am trying to understand the syntax.
What is the logical way to read it.
I have been trying to remove the middle name field form it, but can't get
the syntax correct.
SELECT [LastName] & IIf([FirstName],", " & [FirstName],"") &
IIf([MiddleName]," " & [MiddleName]) AS LastNameFirst,
IIf([MiddleName],[FirstName] & " " & [MiddleName],[FirstName]) &
IIf([LastName]," " & [LastName],[LastName]) AS FirstNameFirst
FROM tblStaffumbers;
Any help would be great.
What is the logical way to read it.
I have been trying to remove the middle name field form it, but can't get
the syntax correct.
SELECT [LastName] & IIf([FirstName],", " & [FirstName],"") &
IIf([MiddleName]," " & [MiddleName]) AS LastNameFirst,
IIf([MiddleName],[FirstName] & " " & [MiddleName],[FirstName]) &
IIf([LastName]," " & [LastName],[LastName]) AS FirstNameFirst
FROM tblStaffumbers;
Any help would be great.