ADO record binding from SQL server to String type 
Author Message
 ADO record binding from SQL server to String type

I used to use DB-LIB to bind a row of data to my vc++ datatypes.  I could
use the NTBSTRINGBIND to get char data from SQL server into a null
terminated string, which truncated trailing blanks.  Now I am migrating to
ADO.  However when I bind the fields using ADO_VARIABLE_LENGTH_BINDING_ENTRY
with adVarChar type,  I get a null terminated string, but it does not
truncate trailing blanks.  I

Is there any way to get the binding process to do this with ADO???
I am using OLEDB as my provider, SQL 7.0,  vc++ 5.0

Thanks
Steve Rogers



Mon, 26 Nov 2001 03:00:00 GMT  
 ADO record binding from SQL server to String type
Figured out to juse RTRIM(column_name) in the select statement

Quote:
>I used to use DB-LIB to bind a row of data to my vc++ datatypes.  I could
>use the NTBSTRINGBIND to get char data from SQL server into a null
>terminated string, which truncated trailing blanks.  Now I am migrating to
>ADO.  However when I bind the fields using

ADO_VARIABLE_LENGTH_BINDING_ENTRY
Quote:
>with adVarChar type,  I get a null terminated string, but it does not
>truncate trailing blanks.  I



Tue, 27 Nov 2001 03:00:00 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. ADO C/C++ Record Binding Definitions (icrsint.h)

2. Crecordset Binding using Class Wizard w/ SQL Server 2000

3. ADO And Adding or Updating Records in SQL Table

4. Getting a random record from a SQL Server table

5. Locking a record in an MS-SQL Server

6. Error updating SQL-Server record via ODBC (CRecordset)

7. Problem Fetching Records in Bulk using MFC/ODBC/SQL Server

8. Cannot delete SQL server duplicate records

9. Adding records to SQL Server

10. CRecordset: Error when adding records SQL Server view

11. Records being locked in SQL Server database

12. Update call to SQL Server with large record never returns

 

 
Powered by phpBB® Forum Software