ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   SQL concatenation statement (https://www.excelbanter.com/excel-discussion-misc-queries/96781-sql-concatenation-statement.html)

CLamar

SQL concatenation statement
 
I am using the following the SQL statement in VBA to query an Access
database. The statement is supposed to query two different columns and
concatenate them together, but it gives me the error "Invalid use of vertical
bars" Can anyone tell me what the syntax of the concatenation statement
should be

The statement I have now is: Src = "SELECT SerialNo || Batch FROM Reference
WHERE Entry =" & "" & Entrynum & ""


All times are GMT +1. The time now is 08:30 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com