in reply to Perl Database Select Results Being Truncated

Another, much more likely possibility is that the information is being cropped on input rather than output. Have you checked your database file, either by looking at the file itself or through an admin utility, to make sure there's more than 255 characters of data?

And yes, Sybase varchar is usually 255 characters max.

  • Comment on Re: Perl Database Select Results Being Truncated

Replies are listed 'Best First'.
Re^2: Perl Database Select Results Being Truncated
by mpeppler (Vicar) on Apr 28, 2005 at 19:12 UTC
    The 255 char limit was dropped in 12.5, and is now raised to a few bytes shorter than a page (a page being 2k, 4k, 8k or 16k).

    However as I mentioned above, because this change requires a change in the protocol between client and server you need to have a (relatively) recent version of the client for this to work correctly.

    Michael

      That did it...thank you so much for the help. I was pointing to older versions of the perl executable, and once I updated to versino 5.8.3, it worked the first time.

      Thanks again for the help.

      Chris
Re^2: Perl Database Select Results Being Truncated
by cpatrick (Novice) on Apr 28, 2005 at 17:25 UTC
    Hi there-

    Actually, that was the first thing I did. Within the database file, I can query and retrieve the entire entry without truncation, so I know the file is valid.

    Thanks again for all of the help...
      Greetings again,
      I read through the source of DBD::Sybase and came upon this little snippet
      # Calling sp_datatype_info returns the appropriate data for the server + that # we are currently connected to. # In general the data is static, so it's not really necessary, but ASE + 12.5 # introduces some changes, in particular char/varchar max lenghts that + depend # on the server's page size. 12.5.1 introduces the DATE and TIME datat +ypes.

      might be worth investigating? If not, I think mpeppler is the author of this module, perhaps you can /msg him about this.

      -InjunJoel

      "I do not feel obliged to believe that the same God who endowed us with sense, reason and intellect has intended us to forego their use." -Galileo