B4J Question net.sourceforge.jtds.jdbc.ClobImpl ?! RDC Client

MrKim

Well-Known Member
Licensed User
Longtime User
I, too am confused. The following query in RDC.
B4X:
sql.GetPartMasterPicsQry=SELECT PartMasterPics.Pmp_PictureName, PartMasterPics.Pmp_Notes, PartMasterPics.Pmp_PrintOnTrav FROM PartMasterPics WHERE (((PartMasterPics.Pmp_PmLinkID)=?)) ORDER BY PartMasterPics.Pmp_SortOrder;
Returns:

The first and last field are fine. I have no idea what to do with the second. It should be returning a line or so of text.
here is the relevant code:
B4X:
Dim result As DBResult = reqManager2.HandleJob(Job)
If result.Tag = "GetPartMasterPicsQry" Then
   For Each records() As Object In result.Rows
      PicsList.AddTwoLines2(records(0), records(1), records(0))
   Next
End IF
The field in SQL Server is nvarchar(MAX). Perhaps the easiest thing to do is CAST it to a regular text in the query?
 
Last edited:
Upvote 0

MrKim

Well-Known Member
Licensed User
Longtime User
Interesting, I solved the problem by changing the query and Changing the return field type:
B4X:
SELECT PartMasterPics.Pmp_PictureName, Cast(PartMasterPics.Pmp_Notes AS nvarchar(100)), PartMasterPics.Pmp_PrintOnTrav FROM PartMasterPics WHERE (((PartMasterPics.Pmp_PmLinkID)=19890)) ORDER BY PartMasterPics.Pmp_SortOrder;
But I would still like to know how to handle very long note fields in the future.
 
Upvote 0
Cookies are required to use this site. You must accept them to continue using the site. Learn more…