Codepage='65001' or any numeric value is throwing Incorrect Syntax error in OPENROWSET query
SeenaAugusty opened this issue · comments
SeenaAugusty commented
While running the below script in sqlproj using Visual Studio 17.9 preview 1, I am getting the error 'Incorrect syntax near '65001' while the same query runs successfully in SSMS 19.
SELECT *
FROM OPENROWSET(
BULK 'path_to_csv',
SINGLE_BLOB,
CODEPAGE = '65001' -- UTF-8 encoding
) AS t;
SeenaAugusty commented
Also, the codepage that has numeric value without single quotes seems to work in both SSDT and SSMS
SELECT *
FROM OPENROWSET(
BULK 'path_to_csv',
SINGLE_BLOB,
CODEPAGE = 65001 -- UTF-8 encoding
) AS t;