Solved

can DB library support char more than 255

Posted on 2002-05-31
3
231 Views
Last Modified: 2010-05-18
I am facing the problem that when i select a record from a column more than 255 bytes(varchar), data is truncated at 255 bytes. how can i solve this problem?
0
Comment
Question by:glt10
  • 2
3 Comments
 
LVL 5

Expert Comment

by:spcmnspff
ID: 7047067
The Varchar datatype can be as large as 8000 characters, so something is is askew.  What sor of application are you using to select the data are connected through an ODBC connection?
0
 

Author Comment

by:glt10
ID: 7050273
hi
yes Varchar can support until 8000 but when i select the record, my result has been truncated to 255.
I am using SQL dblibrary, Sql Direct access API.
0
 
LVL 5

Accepted Solution

by:
spcmnspff earned 50 total points
ID: 7051105
Sheeeesh that's old.  That's a legacy technology from the old SyBase days!  This is a physical limitation of the API function. Is it possible to switch to ADO and avoid the API calls altogether?  If not try breaking it up and concatenating it on the front end.  Something like:

Select Left(MyField,255) A, Right(MyFeild(Len(MyField - 255)

Now you've accomodated for a possible lentgh of 510, and so on  . . .  Now just concatenate the fiekd in the fromnt end.

I know it's not fun but  . . .
0

Featured Post

Optimizing Cloud Backup for Low Bandwidth

With cloud storage prices going down a growing number of SMBs start to use it for backup storage. Unfortunately, business data volume rarely fits the average Internet speed. This article provides an overview of main Internet speed challenges and reveals backup best practices.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The Delta outage: 650 cancelled flights, more than 1200 delayed flights, thousands of frustrated customers, tens of millions of dollars in damages – plus untold reputational damage to one of the world’s most trusted airlines. All due to a catastroph…
Ever wondered why sometimes your SQL Server is slow or unresponsive with connections spiking up but by the time you go in, all is well? The following article will show you how to install and configure a SQL job that will send you email alerts includ…
Using examples as well as descriptions, and references to Books Online, show the documentation available for datatypes, explain the available data types and show how data can be passed into and out of variables.
Viewers will learn how to use the UPDATE and DELETE statements to change or remove existing data from their tables. Make a table: Update a specific column given a specific row using the UPDATE statement: Remove a set of values using the DELETE s…

937 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now