ODBC doesn't Help me

I can see that the “bug” caused in SQL Server may be because the the Field Definition VARCHAR(MAX) may be not compatible with the SQLServer Version being used in XOJO (or something like that).

I noticed some praise given for ODBC Alternatives which I have tried, but get the following problem


VARCHAR(MAX) - Unknown (Used for large comment fields)
BIT - Unknown (Used for storing YES/NO Values)

Appreciate any comments on how you have all solved these hurdles

To change the way my original Tables were defined in MS Access 2000 (then imported to MSSQL Server 2012) would be a step backwards - but obviously very possible.

pretty sure this bug in the underlying ms libraries for accessing varchar(max) is on MS plate and has been for a long time
A google for “varchar(max) odbc” will give you a pile of hits
There’s a bug in the ms native client it seems

I have the same problem even though the field is a varbinary. I do much database development and this will send me back to .net for this project. Someday I hope that the connection to MSSQL Server will be solid.

The trick is to cast the column in your query for example:

SELECT CAST(comments AS NVARCHAR(4000)) AS comments FROM yourtable

Which seems to work around the MS hole.