This discussion is archived
0 Replies Latest reply: Feb 21, 2012 2:24 AM by 914261 RSS

Exception:Unrecognized sql type:nvarchar(max) while querying from database

914261 Newbie
Currently Being Moderated
Hi ,
I am developing API application from oracle web center interaction , i am using sqlserver 2008 as database .
since i have to read data from table using query . I try to read data from table COLLABDB.DBO.CSFORUMMESSAGE which contains column name of data type
nvarchar(MAX) . While I query using
dbCursor = internalSession.CreateCursor(_sql);
dbResults = dbCursor.Open(intMaxRow);
it throws error as : - Exception: Unrecognized sql type: nvarchar(max), column name: BODY3 SQ :SELECT OBJECTID, NAME, DESCRIPTION, OWNERID, CREATED, MODIFIED, PARENTID, BODY1, BODY2, BODY3, APPROVED FROM COLLABDB.DBO.CSFORUMMESSAGE WHERE FORUMID = 53 .

Note that for other tables the query executes successfully .
Even if i manually change the data type from nvarchar(MAX) to nvarchar(1500) the query executes sucessfully.

Thanks
Binaya Acharya

Edited by: 911258 on Feb 21, 2012 4:08 PM

Legend

  • Correct Answers - 10 points
  • Helpful Answers - 5 points