Solved

can DB library support char more than 255

Posted on 2002-05-31
3
236 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
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 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

A Stored Procedure in Microsoft SQL Server is a powerful feature that it can be used to execute the Data Manipulation Language (DML) or Data Definition Language (DDL). Depending on business requirements, a single Stored Procedure can return differe…
Recently we ran in to an issue while running some SQL jobs where we were trying to process the cubes.  We got an error saying failure stating 'NT SERVICE\SQLSERVERAGENT does not have access to Analysis Services. So this is a way to automate that wit…
Using examples as well as descriptions, and references to Books Online, show the documentation available for date manipulation functions and by using a select few of these functions, show how date based data can be manipulated with these functions.
This videos aims to give the viewer a basic demonstration of how a user can query current session information by using the SYS_CONTEXT function

724 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