ekendricks
Posts: 34
|
Posted: 03/05/2005, 7:38 AM |
|
I'm trying to combine the First-Middle-Last name of employee and set as "Employee" session variable at time of login. Selecting one part of the name AS "Employee" works fine. My problem comes in trying to combine the names. Can someone look at the sql string and error msg below and tell me whats wrong.
Error Type:
Microsoft VBScript compilation (0x800A0401)
Expected end of statement
/Med/Common.asp, line 1703, column 37
SQL = "SELECT EmpID,GroupID, FName&" "&LName AS Employee FROM Employees WHERE UserName='" & Replace(Login, "'", "''") & "' AND Pswd='" & Replace(Password, "'", "''") & "'"
Thanks
Ernest
|
|
|
peterr
Posts: 5971
|
Posted: 03/05/2005, 3:35 PM |
|
The 2nd quote ends your SQL string. Try:
SQL = "SELECT EmpID,GroupID, FName&' '&LName...
_________________
Peter R.
YesSoftware Forums Moderator
For product support please visit http://support.yessoftware.com |
|
|
Ernest
|
Posted: 03/07/2005, 6:10 AM |
|
Thanks....
Solved the problem
Ernest
|
|
|
|