Board index » delphi » SQL Server 7 string field lengths >255 length

SQL Server 7 string field lengths >255 length

I have the following things:
SQL Server 7.0 in which is a database containing:
-a table with a field of varchar with length 2000
-a stored procedure to update this field, the appropriate parameter
   being 2000 in length
BDE 5.1.1
C++Builder 3.0 running on Windows NT 4.0

Now, my application has a TStoredProc I have pointed to the stored
procedure.  I assign any string over 255 characters to the
parameter in the TStoredProc (I can check the string has been
successfully assigned to the parameter by assigning it back to
an AnsiString).  The problem is that this parameter is not sent to
the SQL Server.

Using SQL monitor reveals that the BDE sends the parameters but
skips the parameter with >255 characters, and when the stored
procedure completes, garbage is stored in the field in the
table.

I'm currently using the native MSSQL driver.  Would switching to
use the ODBC driver help?  Are 2000 character fields unsupported
in the BDE?  If so, does anyone know where I can find information
on interfacing with the SQL Server independantly of the BDE?

Thank you to anyone who can help!

Alden.

 

Re:SQL Server 7 string field lengths >255 length


Only
Query.SQL.Add('commandling1');
Query.SQL.Add('commandling2');
Query.SQL.Add('commandling3');
Query.SQL.Add('commandling4');
Query.SQL.Add('commandling5');
Query.SQL.Add('commandling5');
Query.ExecSQL;

Other Threads