>I created a view which is based on ODBC setting for an SQL server table. IF VFP when I set a 10 character field a value
>of "ABC" in a new record, after I update the SQL table, the field is saved to the SQL server
>table as "ABC" padded to the right with 7 spaces. Is there any way either through a VFP command or ODBC setting
>or possibly an SQL server setting to prevent this from happening ?
>
>Thanks for your help
>Stephen J. Hunt
Stephen,
On SQL server side datatype should be varchar and 'ansi_padding on' when table created (default and recommended). In that case SQL server doesn't trim c(10) sent by VFP. However SQL varchar maps to VFP memo more closely rather than char type. If you map it to memo type then SQL server stores w/o trailing space.
Cetin