[This topic is migrated from our old forums. The original author name has been removed]
To preface, I am an MS SQL guy, please don't judge. :-)
I have an ODBC connection to a Lotus Notes database and I am getting the following error:
[Lotus][ODBC Lotus Notes]Invalid datetime value
My initial thought is to convert the column to a string.
convert(varchar(255), Column_Name_1) as Column_Name_1
However, when I run this query, I get the following error:
[Error Code: 23064, SQL State: 37000] [Lotus][ODBC Lotus Notes]Incorrect syntax near 'SELECT'
If I try using 'CAST'
cast (Column_Name_1, varchar(255)) as Column_Name_1
I get this error:
[Error Code: 23013, SQL State: 37000] [Lotus][ODBC Lotus Notes]Keyword FROM expected
Anyone have any syntax suggestions?
about 3 years ago
[This reply is migrated from our old forums. The original author name has been removed]
Re: SQL convet to string
Regarding the CAST and CONVERT errors, it looks to me like you're trying to use SQL*Server syntax which is not supported by the Lotus Notes ODBC driver.
Regarding the initial error, there's not enough detail to be able to tell what's going on (which ODBC driver? what version? Lotus Notes version?) but I suspect that the driver being used doesn't fully support the version of Lotus Notes being accessed.
You would probably have better luck getting an answer on a forum for the ODBC driver being used.