Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

ODBC and space padding

2 views
Skip to first unread message

Wendell Rios

unread,
Dec 2, 1999, 3:00:00 AM12/2/99
to
Hi all!

Using the native driver for Sybase System 10 to acess a fixed character
field char(12) the query returned just the field content: 8 characters.
Accessing the same field using an ODBC Driver the same query returned the
field content plus 3 spaces padding, resulting in 12 characters

There are some difference on spaces padding when using native or ODBC
drivers?

There are any workaround?

Linda Klem

unread,
Dec 2, 1999, 3:00:00 AM12/2/99
to
Wendell,

The spaces that pad the field are deliberately removed so that for example
in a datawindow the user doesn't have to delete the spaces before he/she can
type into the field. You can change the behavior when using ODBC by
modifying your pb odb ini file. You add the following to the paragraph for
your Sybase ODBC driver: PBTrimCharColumns='YES'. BTW search your ini file
for the string I pasted in below. This will take you to the section of this
file that shows all of the overrides for ODBC and what the default behavior
is. The file is self-documenting in this regard.

PBTrimCharColumns='YES' - trim trailing blanks after fetching character
; data, default is NO

Linda Klem
PowerBuilder Product Support


Wendell Rios <wende...@i.am> wrote in message
news:tMkorQPP$GA....@forums.sybase.com...

0 new messages