New topic in Databases: 

MS SQL Server nText Fields

softbase - Fri Mar 28, 2008 4:08 pm

<http://forums.realsoftware.com/viewtopic.php?t=21497>
                                                                                
                                                                                
I have a large MS SQL Server database (with an installed base of over 100 
companies using the app) that contain nText fields in serveral tables.  I have 
VB6 apps that have been running against this data for many years with no 
problems.

With RB, however, apps running in Windows will not return anything for these 
fields while the very same RB apps running on a Mac are working perfectly.  The 
RB apps are using the ODBCDatabase Pluggin that ships with RB.  I've tried this 
on 2007r3, 2007r4, 2007r5, and 2008r1.  None will work for Windows, while all 
will work for Mac's.

If I test change a nText field to a VarChar(4000) it works perfectly.  If I 
change it to a VarChar(Max), it fails just like the nText type fails.  Again, 
this all works on a Mac.

One other interesting quark, on the Mac, if the table I am reading individual 
fields for has many fields, in this case around 57 fields, and I read the other 
fields first and later on the Comments fields (the nText field), it won't work 
on the Mac.  But, with nothing else changed, read the Comments (nText) field 
first or nearly first, it works on the Mac everytime.  No mater what I try with 
Windows this type of field (and I tried multiple tables with this type of 
field) will fail everytime and never return a value.

Does anyone have any insight into this?  I can't afford to split up my tables 
in this particular app (partly because of the large installed base) in order to 
change these fields to VarChar(4000)'s.  If I tried to leave them in the 
existing table, I would be running into the 8K byte Record Size limit in MS SQL 
Server.

(When reading a record from a table, you have an 8k limit to the length of the 
record.  Except, nText fields only count 16 bytes towards this limit.  But, if 
I change this field to a VarChar the entire contents will count toward the 8k 
limit.)

Thanks!                                                                         
        
_________________
------------------------------------------------------
Mac Pro 2.66 Ghz Quad Core 7GB Ram
RB 2008 R1 Pro on Mac OS X Leopard 10.5.2
RB 2008 R1 Pro on Windows Vista                                 
                                                                                
                                                                                
                                                                                
                                                                                
                                        




-- 
Over 900 classes with 18000 functions in one REALbasic plug-in. 
The Monkeybread Software Realbasic Plugin v8.1. 

&lt;http://www.monkeybreadsoftware.de/realbasic/plugins.shtml&gt;

[email protected]

Reply via email to