|
Posted by David Portas on 10/20/05 23:18
SQL delimits string literals with single quotes rather than double:
SELECT IdFlight, OrganizerLastName + ', ' + OrganizerFirstName +
'Flt:' + FlightNumber AS Concat
FROM TableFlights
ORDER BY OrganizerLastName, OrganizerFirstName ;
--
David Portas
SQL Server MVP
--
"COHENMARVIN" <cohenmarvin@hotmail.com> wrote in message
news:1129835952.069950.284810@z14g2000cwz.googlegroups.com...
> The following sql statement fails:
> SELECT IdFlight, OrganizerLastName + ", " + OrganizerFirstName + "
> Flt:" + FlightNumber As Concat FROM TableFlights Order By
> OrganizerLastName, OrganizerFirstName
> I'm trying to concatenate fields and words, but my asp.net page gives
> me an error saying " Flt:" is not a field.
> Thanks,
> Marvin
>
Navigation:
[Reply to this message]
|