Sybase NNTP forums - End Of Life (EOL)

The NNTP forums from Sybase - forums.sybase.com - are now closed.

All new questions should be directed to the appropriate forum at the SAP Community Network (SCN).

Individual products have links to the respective forums on SCN, or you can go to SCN and search for your product in the search box (upper right corner) to find your specific developer center.

Text Column Error while retrieving through READTEXT

12 posts in General Discussion Last posting was on 2009-07-04 18:13:51.0Z
Sam Posted on 2009-07-01 09:50:26.0Z
From: Sam <swaminathan.mn@gmail.com>
Newsgroups: sybase.public.ase.general
Subject: Text Column Error while retrieving through READTEXT
Date: Wed, 1 Jul 2009 02:50:26 -0700 (PDT)
Organization: http://groups.google.com
Lines: 32
Message-ID: <c12832be-1b2f-4759-8e3e-a463028b25d7@l34g2000vbi.googlegroups.com>
NNTP-Posting-Host: 167.230.38.115
Mime-Version: 1.0
Content-Type: text/plain; charset=windows-1252
Content-Transfer-Encoding: quoted-printable
X-Trace: posting.google.com 1246441828 30521 127.0.0.1 (1 Jul 2009 09:50:28 GMT)
X-Complaints-To: groups-abuse@google.com
NNTP-Posting-Date: Wed, 1 Jul 2009 09:50:28 +0000 (UTC)
Complaints-To: groups-abuse@google.com
Injection-Info: l34g2000vbi.googlegroups.com; posting-host=167.230.38.115; posting-account=9mhdQwkAAACFHDB2vHeFfHSP7Ru8fXGS
User-Agent: G2/1.0
X-HTTP-UserAgent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.9.0.4) Gecko/2008102920 Firefox/3.0.4,gzip(gfe),gzip(gfe)
X-HTTP-Via: 1.1 aigctcproxy:5634 (squid/2.5.STABLE6)
Path: forums-1-dub!forums-master!newssvr.sybase.com!news-sj-1.sprintlink.net!news-peer1.sprintlink.net!nntp1.phx1.gblx.net!nntp.gblx.net!nntp.gblx.net!border2.nntp.dca.giganews.com!nntp.giganews.com!postnews.google.com!l34g2000vbi.googlegroups.com!not-for-mail
Xref: forums-1-dub sybase.public.ase.general:27936
Article PK: 77184

ASE server is terminating when I reposition the starting
column in Sybase 15 version. Execution 1, executes well and
returning row, but execution 2 does not executes and end up
with the error ASE server is terminating.

Execution 1: Not getting any errors
[
DECLARE @ptr varbinary(16)
SELECT @ptr=TEXTPTR(doc_text) FROM ttextdoc
READTEXT ttextdoc.doc_text @ptr 1 2000
]

Execution 2: Getting error when repositioning
[
DECLARE @ptr varbinary(16)
SELECT @ptr=TEXTPTR(doc_text) FROM ttextdoc


READTEXT ttextdoc.doc_text @ptr 2001 2000
]

Error: “08:14:52.023 DBMS IRLD3R301V15 -- Layer
(5), Origin (2), Severity (7), Number (12) ct_send():
network packet layer: internal Client Library error: State
error: trying to write when connection is expecting a
read.”


Please help.
Thanks in advance

Sam


"Mark A. Parsons" <iron_horse Posted on 2009-07-01 14:21:28.0Z
From: "Mark A. Parsons" <iron_horse@no_spamola.compuserve.com>
User-Agent: Thunderbird 1.5.0.10 (Windows/20070221)
MIME-Version: 1.0
Newsgroups: sybase.public.ase.general
Subject: Re: Text Column Error while retrieving through READTEXT
References: <c12832be-1b2f-4759-8e3e-a463028b25d7@l34g2000vbi.googlegroups.com>
In-Reply-To: <c12832be-1b2f-4759-8e3e-a463028b25d7@l34g2000vbi.googlegroups.com>
Content-Type: text/plain; charset=windows-1252; format=flowed
Content-Transfer-Encoding: 8bit
X-Antivirus: avast! (VPS 090629-0, 06/29/2009), Outbound message
X-Antivirus-Status: Clean
NNTP-Posting-Host: vip152.sybase.com
X-Original-NNTP-Posting-Host: vip152.sybase.com
Message-ID: <4a4b70e8$1@forums-3-dub.sybase.com>
Date: 1 Jul 2009 07:21:28 -0700
X-Trace: forums-3-dub.sybase.com 1246458088 10.22.241.152 (1 Jul 2009 07:21:28 -0700)
X-Original-Trace: 1 Jul 2009 07:21:28 -0700, vip152.sybase.com
Lines: 67
Path: forums-1-dub!forums-master!forums-3-dub.sybase.com!not-for-mail
Xref: forums-1-dub sybase.public.ase.general:27939
Article PK: 77186

It's not clear from your post if:

- this is the only SQL performed by your application

or

- if the error is related to the 2nd READTEXT, or another piece of SQL in your program

-----------------------

This error typically shows up when a program a) issues a SQL statement, b) fails to completely process the results of
the SQL statement, and c) then tries to issue a new SQL statement. ("Duh, Mark!" ?)

Is your program performing any other SQL besides the 2 snippets you've provided?

What happens if you log into your database with isql and run:

===================
DECLARE @ptr varbinary(16)
SELECT @ptr=TEXTPTR(doc_text) FROM ttextdoc
READTEXT ttextdoc.doc_text @ptr 1 2000
go
DECLARE @ptr varbinary(16)
SELECT @ptr=TEXTPTR(doc_text) FROM ttextdoc
READTEXT ttextdoc.doc_text @ptr 2001 2000
go
===================

If you get an error ... open a case with Sybase TechSupport (same thing Rob's already suggested).

If you do *NOT* get an error ... you'll need to do some debugging on your program; you'll want to figure out which SQL
statement is generating the error, then find the previously issued SQL statement and figure out why the program is not
properly processing the previous SQL statement.

Sam wrote:
> ASE server is terminating when I reposition the starting
> column in Sybase 15 version. Execution 1, executes well and
> returning row, but execution 2 does not executes and end up
> with the error ASE server is terminating.
>
> Execution 1: Not getting any errors
> [
> DECLARE @ptr varbinary(16)
> SELECT @ptr=TEXTPTR(doc_text) FROM ttextdoc
> READTEXT ttextdoc.doc_text @ptr 1 2000
> ]
>
> Execution 2: Getting error when repositioning
> [
> DECLARE @ptr varbinary(16)
> SELECT @ptr=TEXTPTR(doc_text) FROM ttextdoc
>
>
> READTEXT ttextdoc.doc_text @ptr 2001 2000
> ]
>
> Error: “08:14:52.023 DBMS IRLD3R301V15 -- Layer
> (5), Origin (2), Severity (7), Number (12) ct_send():
> network packet layer: internal Client Library error: State
> error: trying to write when connection is expecting a
> read.”
>
>
> Please help.
> Thanks in advance
>
> Sam


Sam Posted on 2009-07-02 03:31:11.0Z
From: Sam <swaminathan.mn@gmail.com>
Newsgroups: sybase.public.ase.general
Subject: Re: Text Column Error while retrieving through READTEXT
Date: Wed, 1 Jul 2009 20:31:11 -0700 (PDT)
Organization: http://groups.google.com
Lines: 118
Message-ID: <b04e6469-47a5-4f92-9a82-bf9a11dabefc@c36g2000yqn.googlegroups.com>
References: <c12832be-1b2f-4759-8e3e-a463028b25d7@l34g2000vbi.googlegroups.com> <4a4b70e8$1@forums-3-dub.sybase.com>
NNTP-Posting-Host: 167.230.38.115
Mime-Version: 1.0
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
X-Trace: posting.google.com 1246505471 10028 127.0.0.1 (2 Jul 2009 03:31:11 GMT)
X-Complaints-To: groups-abuse@google.com
NNTP-Posting-Date: Thu, 2 Jul 2009 03:31:11 +0000 (UTC)
Complaints-To: groups-abuse@google.com
Injection-Info: c36g2000yqn.googlegroups.com; posting-host=167.230.38.115; posting-account=9mhdQwkAAACFHDB2vHeFfHSP7Ru8fXGS
User-Agent: G2/1.0
X-HTTP-UserAgent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.9.0.4) Gecko/2008102920 Firefox/3.0.4,gzip(gfe),gzip(gfe)
X-HTTP-Via: 1.1 aigctcproxy:5634 (squid/2.5.STABLE6)
Path: forums-1-dub!forums-master!newssvr.sybase.com!news-sj-1.sprintlink.net!news-peer1.sprintlink.net!newsfeed.yul.equant.net!novia!news-out.readnews.com!transit4.readnews.com!postnews.google.com!c36g2000yqn.googlegroups.com!not-for-mail
Xref: forums-1-dub sybase.public.ase.general:27942
Article PK: 77189

On Jul 1, 7:21 pm, "Mark A. Parsons"

<iron_horse@no_spamola.compuserve.com> wrote:
> It's not clear from your post if:
>
> - this is the only SQL performed by your application
>
> or
>
> - if the error is related to the 2ndREADTEXT, or another piece of SQL in your program
>
> -----------------------
>
> This error typically shows up when a program a) issues a SQL statement, b) fails to completely process the results of
> the SQL statement, and c) then tries to issue a new SQL statement.  ("Duh, Mark!" ?)
>
> Is your program performing any other SQL besides the 2 snippets you've provided?
>
> What happens if you log into your database with isql and run:
>
> ===================
> DECLARE @ptr varbinary(16)
> SELECT  @ptr=TEXTPTR(doc_text) FROM ttextdocREADTEXTttextdoc.doc_text @ptr 1 2000
> go
> DECLARE @ptr varbinary(16)
> SELECT  @ptr=TEXTPTR(doc_text) FROM ttextdocREADTEXTttextdoc.doc_text @ptr 2001 2000
> go
> ===================
>
> If you get an error ... open a case with Sybase TechSupport (same thing Rob's already suggested).
>
> If you do *NOT* get an error ... you'll need to do some debugging on your program; you'll want to figure out which SQL
> statement is generating the error, then find the previously issued SQL statement and figure out why the program is not
> properly processing the previous SQL statement.
>
> Sam wrote:
> > ASE server is terminating when I reposition the starting
> > column in Sybase 15 version.  Execution 1, executes well and
> > returning row, but execution 2 does not executes and end up
> > with the error ASE server is terminating.
>
> > Execution 1: Not getting any errors
> > [
> > DECLARE @ptr varbinary(16)
> > SELECT  @ptr=TEXTPTR(doc_text) FROM ttextdoc
> >READTEXTttextdoc.doc_text @ptr 1 2000
> > ]
>
> > Execution 2: Getting error when repositioning
> > [
> > DECLARE @ptr varbinary(16)
> > SELECT  @ptr=TEXTPTR(doc_text) FROM ttextdoc
>
> >READTEXTttextdoc.doc_text @ptr 2001 2000
> > ]
>
> > Error: 08:14:52.023    DBMS    IRLD3R301V15 -- Layer
> > (5), Origin (2), Severity (7), Number (12) ct_send():
> > network packet layer: internal Client Library error: State
> > error: trying to write when connection is expecting a
> > read.
>
> > Please help.
> > Thanks in advance
>
> > Sam

Hi Mark,

At the outset thanks for your prompt reply

I have a stored procedure where I am passing the offset value
(character begin) and size. My SP will look below


CREATE PROCEDURE ExtractTextColumn
@Offset INT,
@NoOfBytes INT
AS
BEGIN
DECLARE @ptr varbinary(16)
SELECT @ptr=TEXTPTR(doc_text) FROM ttextdoc WHERE
Empl_No=18242
READTEXTttextdoc.doc_text @ptr @Offset @NoOfBytes
END

I am trying to extract the binary information stored in the Text
Column bytes by bytes (say 2024 bytes for each execution)

This procedure is working fine and returning values in the Sybase
11.0.0.3, but recently we upgraded our database to 15.0.3 with that
version it is not working fine if the offset value goes more than 1800

Below Execution 1, returns value.

ExtractTextColumn 1, 2000

Execution 2, throws error

ExtractTextColumn 2000, 2000

Error: 08:14:52.023 DBMS IRLD3R301V15 -- Layer (5), Origin (2),
Severity (7), Number (12) ct_send(): network packet layer: internal
Client Library error: State error: trying to write when connection is
expecting a read.

I hope this is very clear, kindly help me with your advice asap.

Thanks
Sam


"Mark A. Parsons" <iron_horse Posted on 2009-07-02 09:42:26.0Z
From: "Mark A. Parsons" <iron_horse@no_spamola.compuserve.com>
User-Agent: Thunderbird 1.5.0.10 (Windows/20070221)
MIME-Version: 1.0
Newsgroups: sybase.public.ase.general
Subject: Re: Text Column Error while retrieving through READTEXT
References: <c12832be-1b2f-4759-8e3e-a463028b25d7@l34g2000vbi.googlegroups.com> <4a4b70e8$1@forums-3-dub.sybase.com> <b04e6469-47a5-4f92-9a82-bf9a11dabefc@c36g2000yqn.googlegroups.com>
In-Reply-To: <b04e6469-47a5-4f92-9a82-bf9a11dabefc@c36g2000yqn.googlegroups.com>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit
X-Antivirus: avast! (VPS 090629-0, 06/29/2009), Outbound message
X-Antivirus-Status: Clean
NNTP-Posting-Host: vip152.sybase.com
X-Original-NNTP-Posting-Host: vip152.sybase.com
Message-ID: <4a4c8102@forums-3-dub.sybase.com>
Date: 2 Jul 2009 02:42:26 -0700
X-Trace: forums-3-dub.sybase.com 1246527746 10.22.241.152 (2 Jul 2009 02:42:26 -0700)
X-Original-Trace: 2 Jul 2009 02:42:26 -0700, vip152.sybase.com
Lines: 70
Path: forums-1-dub!forums-master!forums-3-dub.sybase.com!not-for-mail
Xref: forums-1-dub sybase.public.ase.general:27943
Article PK: 77190

The error message is being generated by the client application.

If, as you say, the only component that's changed in your system is the ASE version, then perhaps your client
application is having problems due its use of an older version of OCS.

Have you tried modifying (recompiling?) your client application to use a 15.x version of SDK? (NOTE: name change - OCS
is now called SDK)

--------------

As a first step in tracking down the problem I still recommend you take the client application out of the equation.
This consists of submitting your queries via isql; preferably the same command-line isql that comes with the ASE 15.0.3
dataserver.

I'm not talking about wisql, dbisql, SQLAdvantage, nor any GUI tool ... run your 2 stored proc invocations through the
command-line version of isql that comes with ASE 15.0.3. This will insure that the client application (command-line
isql) is using an up-to-date version of SDK. [Objective is to see if the stored proc code runs in ASE 15.0.3 correctly
without having to worry about SDK/connectivity issues.]

================= isql -U... -P... -S...
use <dbname>
go
exec ExtractTextColumn 1, 2000
go
exec ExtractTextColumn 2001, 2000
go
=================

Sam wrote:
> I have a stored procedure where I am passing the offset value
> (character begin) and size. My SP will look below
>
>
> CREATE PROCEDURE ExtractTextColumn
> @Offset INT,
> @NoOfBytes INT
> AS
> BEGIN
> DECLARE @ptr varbinary(16)
> SELECT @ptr=TEXTPTR(doc_text) FROM ttextdoc WHERE
> Empl_No=18242
> READTEXTttextdoc.doc_text @ptr @Offset @NoOfBytes
> END
>
> I am trying to extract the binary information stored in the Text
> Column bytes by bytes (say 2024 bytes for each execution)
>
> This procedure is working fine and returning values in the Sybase
> 11.0.0.3, but recently we upgraded our database to 15.0.3 with that
> version it is not working fine if the offset value goes more than 1800
>
> Below Execution 1, returns value.
>
> ExtractTextColumn 1, 2000
>
> Execution 2, throws error
>
> ExtractTextColumn 2000, 2000
>
> Error: 08:14:52.023 DBMS IRLD3R301V15 -- Layer (5), Origin (2),
> Severity (7), Number (12) ct_send(): network packet layer: internal
> Client Library error: State error: trying to write when connection is
> expecting a read.
>
> I hope this is very clear, kindly help me with your advice asap.
>
> Thanks
> Sam


Sam Posted on 2009-07-02 10:36:26.0Z
From: Sam <swaminathan.mn@gmail.com>
Newsgroups: sybase.public.ase.general
Subject: Re: Text Column Error while retrieving through READTEXT
Date: Thu, 2 Jul 2009 03:36:26 -0700 (PDT)
Organization: http://groups.google.com
Lines: 87
Message-ID: <c7602e1f-9d13-4749-b35b-6b4557f35671@i6g2000yqj.googlegroups.com>
References: <c12832be-1b2f-4759-8e3e-a463028b25d7@l34g2000vbi.googlegroups.com> <4a4b70e8$1@forums-3-dub.sybase.com> <b04e6469-47a5-4f92-9a82-bf9a11dabefc@c36g2000yqn.googlegroups.com> <4a4c8102@forums-3-dub.sybase.com>
NNTP-Posting-Host: 167.230.38.115
Mime-Version: 1.0
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
X-Trace: posting.google.com 1246531091 27737 127.0.0.1 (2 Jul 2009 10:38:11 GMT)
X-Complaints-To: groups-abuse@google.com
NNTP-Posting-Date: Thu, 2 Jul 2009 10:38:11 +0000 (UTC)
Complaints-To: groups-abuse@google.com
Injection-Info: i6g2000yqj.googlegroups.com; posting-host=167.230.38.115; posting-account=9mhdQwkAAACFHDB2vHeFfHSP7Ru8fXGS
User-Agent: G2/1.0
X-HTTP-UserAgent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.9.0.4) Gecko/2008102920 Firefox/3.0.4,gzip(gfe),gzip(gfe)
X-HTTP-Via: 1.1 aigctcproxy:5634 (squid/2.5.STABLE6)
Path: forums-1-dub!forums-master!newssvr.sybase.com!news-sj-1.sprintlink.net!news-peer1.sprintlink.net!nntp1.phx1.gblx.net!nntp.gblx.net!nntp.gblx.net!border2.nntp.dca.giganews.com!nntp.giganews.com!postnews.google.com!i6g2000yqj.googlegroups.com!not-for-mail
Xref: forums-1-dub sybase.public.ase.general:27944
Article PK: 77193

Thanks Mark,

I tried executing my stored procedure in the ISQL (commond prompt)
still I am getting the same error



On Jul 2, 2:42 pm, "Mark A. Parsons"

<iron_horse@no_spamola.compuserve.com> wrote:
> The error message is being generated by the client application.
>
> If, as you say, the only component that's changed in your system is the ASE version, then perhaps your client
> application is having problems due its use of an older version of OCS.
>
> Have you tried modifying (recompiling?) your client application to use a 15.x version of SDK?  (NOTE: name change - OCS
> is now called SDK)
>
> --------------
>
> As a first step in tracking down the problem I still recommend you take the client application out of the equation.
> This consists of submitting your queries via isql; preferably the same command-line isql that comes with the ASE 15.0.3
> dataserver.
>
> I'm not talking about wisql, dbisql, SQLAdvantage, nor any GUI tool ... run your 2 stored proc invocations through the
> command-line version of isql that comes with ASE 15.0.3.  This will insure that the client application (command-line
> isql) is using an up-to-date version of SDK.  [Objective is to see if the stored proc code runs in ASE 15.0.3 correctly
> without having to worry about SDK/connectivity issues.]
>
> =================  isql -U... -P... -S...
> use <dbname>
> go
> exec ExtractTextColumn 1, 2000
> go
> exec ExtractTextColumn 2001, 2000
> go
> =================
>
> Sam wrote:
> > I have a stored procedure where I am passing the offset value
> > (character begin) and size.  My SP will look below
>
> > CREATE PROCEDURE ExtractTextColumn
> > @Offset INT,
> > @NoOfBytes INT
> > AS
> > BEGIN
> >           DECLARE @ptr varbinary(16)
> >           SELECT  @ptr=TEXTPTR(doc_text) FROM ttextdoc WHERE
> > Empl_No=18242
> >           READTEXTttextdoc.doc_text @ptr @Offset @NoOfBytes
> > END
>
> > I am trying to extract the binary information stored in the Text
> > Column bytes by bytes (say 2024 bytes for each execution)
>
> > This procedure is working fine and returning values in the Sybase
> > 11.0.0.3, but recently we upgraded our database to 15.0.3 with that
> > version it is not working fine if the offset value goes more than 1800
>
> > Below Execution 1, returns value.
>
> > ExtractTextColumn 1, 2000
>
> > Execution 2, throws error
>
> > ExtractTextColumn 2000, 2000
>
> > Error: 08:14:52.023    DBMS    IRLD3R301V15 -- Layer (5), Origin (2),
> > Severity (7), Number (12) ct_send(): network packet layer: internal
> > Client Library error: State error: trying to write when connection is
> > expecting a read.
>
> > I hope this is very clear, kindly help me with your advice asap.
>
> > Thanks
> > Sam


"Mark A. Parsons" <iron_horse Posted on 2009-07-02 18:23:39.0Z
From: "Mark A. Parsons" <iron_horse@no_spamola.compuserve.com>
User-Agent: Thunderbird 1.5.0.10 (Windows/20070221)
MIME-Version: 1.0
Newsgroups: sybase.public.ase.general
Subject: Re: Text Column Error while retrieving through READTEXT
References: <c12832be-1b2f-4759-8e3e-a463028b25d7@l34g2000vbi.googlegroups.com> <4a4b70e8$1@forums-3-dub.sybase.com> <b04e6469-47a5-4f92-9a82-bf9a11dabefc@c36g2000yqn.googlegroups.com> <4a4c8102@forums-3-dub.sybase.com> <c7602e1f-9d13-4749-b35b-6b4557f35671@i6g2000yqj.googlegroups.com>
In-Reply-To: <c7602e1f-9d13-4749-b35b-6b4557f35671@i6g2000yqj.googlegroups.com>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit
X-Antivirus: avast! (VPS 090702-0, 07/02/2009), Outbound message
X-Antivirus-Status: Clean
NNTP-Posting-Host: vip152.sybase.com
X-Original-NNTP-Posting-Host: vip152.sybase.com
Message-ID: <4a4cfb2b$2@forums-3-dub.sybase.com>
Date: 2 Jul 2009 11:23:39 -0700
X-Trace: forums-3-dub.sybase.com 1246559019 10.22.241.152 (2 Jul 2009 11:23:39 -0700)
X-Original-Trace: 2 Jul 2009 11:23:39 -0700, vip152.sybase.com
Lines: 75
X-Authenticated-User: TeamSybase
Path: forums-1-dub!forums-master!forums-3-dub.sybase.com!not-for-mail
Xref: forums-1-dub sybase.public.ase.general:27952
Article PK: 77197

I'm running ASE 15.0.3 ESD #1 on WindowsXP and I can get your same code (via isql command line) to work for a text
column containing 5000 characters.

At this point you'll need to open a case with Sybase TechSupport.

Sam wrote:
> Thanks Mark,
>
> I tried executing my stored procedure in the ISQL (commond prompt)
> still I am getting the same error
>
>
>
> On Jul 2, 2:42 pm, "Mark A. Parsons"
> <iron_horse@no_spamola.compuserve.com> wrote:
>> The error message is being generated by the client application.
>>
>> If, as you say, the only component that's changed in your system is the ASE version, then perhaps your client
>> application is having problems due its use of an older version of OCS.
>>
>> Have you tried modifying (recompiling?) your client application to use a 15.x version of SDK? (NOTE: name change - OCS
>> is now called SDK)
>>
>> --------------
>>
>> As a first step in tracking down the problem I still recommend you take the client application out of the equation.
>> This consists of submitting your queries via isql; preferably the same command-line isql that comes with the ASE 15.0.3
>> dataserver.
>>
>> I'm not talking about wisql, dbisql, SQLAdvantage, nor any GUI tool ... run your 2 stored proc invocations through the
>> command-line version of isql that comes with ASE 15.0.3. This will insure that the client application (command-line
>> isql) is using an up-to-date version of SDK. [Objective is to see if the stored proc code runs in ASE 15.0.3 correctly
>> without having to worry about SDK/connectivity issues.]
>>
>> ================= isql -U... -P... -S...
>> use <dbname>
>> go
>> exec ExtractTextColumn 1, 2000
>> go
>> exec ExtractTextColumn 2001, 2000
>> go
>> =================
>>
>> Sam wrote:
>>> I have a stored procedure where I am passing the offset value
>>> (character begin) and size. My SP will look below
>>> CREATE PROCEDURE ExtractTextColumn
>>> @Offset INT,
>>> @NoOfBytes INT
>>> AS
>>> BEGIN
>>> DECLARE @ptr varbinary(16)
>>> SELECT @ptr=TEXTPTR(doc_text) FROM ttextdoc WHERE
>>> Empl_No=18242
>>> READTEXTttextdoc.doc_text @ptr @Offset @NoOfBytes
>>> END
>>> I am trying to extract the binary information stored in the Text
>>> Column bytes by bytes (say 2024 bytes for each execution)
>>> This procedure is working fine and returning values in the Sybase
>>> 11.0.0.3, but recently we upgraded our database to 15.0.3 with that
>>> version it is not working fine if the offset value goes more than 1800
>>> Below Execution 1, returns value.
>>> ExtractTextColumn 1, 2000
>>> Execution 2, throws error
>>> ExtractTextColumn 2000, 2000
>>> Error: 08:14:52.023 DBMS IRLD3R301V15 -- Layer (5), Origin (2),
>>> Severity (7), Number (12) ct_send(): network packet layer: internal
>>> Client Library error: State error: trying to write when connection is
>>> expecting a read.
>>> I hope this is very clear, kindly help me with your advice asap.
>>> Thanks
>>> Sam
>


"Mark A. Parsons" <iron_horse Posted on 2009-07-02 18:36:11.0Z
From: "Mark A. Parsons" <iron_horse@no_spamola.compuserve.com>
User-Agent: Thunderbird 1.5.0.10 (Windows/20070221)
MIME-Version: 1.0
Newsgroups: sybase.public.ase.general
Subject: Re: Text Column Error while retrieving through READTEXT
References: <c12832be-1b2f-4759-8e3e-a463028b25d7@l34g2000vbi.googlegroups.com> <4a4b70e8$1@forums-3-dub.sybase.com> <b04e6469-47a5-4f92-9a82-bf9a11dabefc@c36g2000yqn.googlegroups.com> <4a4c8102@forums-3-dub.sybase.com> <c7602e1f-9d13-4749-b35b-6b4557f35671@i6g2000yqj.googlegroups.com> <4a4cfb2b$2@forums-3-dub.sybase.com>
In-Reply-To: <4a4cfb2b$2@forums-3-dub.sybase.com>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit
X-Antivirus: avast! (VPS 090702-0, 07/02/2009), Outbound message
X-Antivirus-Status: Clean
NNTP-Posting-Host: vip152.sybase.com
X-Original-NNTP-Posting-Host: vip152.sybase.com
Message-ID: <4a4cfe1b$2@forums-3-dub.sybase.com>
Date: 2 Jul 2009 11:36:11 -0700
X-Trace: forums-3-dub.sybase.com 1246559771 10.22.241.152 (2 Jul 2009 11:36:11 -0700)
X-Original-Trace: 2 Jul 2009 11:36:11 -0700, vip152.sybase.com
Lines: 88
Path: forums-1-dub!forums-master!forums-3-dub.sybase.com!not-for-mail
Xref: forums-1-dub sybase.public.ase.general:27954
Article PK: 77200

FWIW, I've also got your original code (via isql command line) working fine with ASE 15.0.2 ESD #5 (Linux).

Mark A. Parsons wrote:
> I'm running ASE 15.0.3 ESD #1 on WindowsXP and I can get your same code
> (via isql command line) to work for a text column containing 5000
> characters.
>
> At this point you'll need to open a case with Sybase TechSupport.
>
>
>
> Sam wrote:
>> Thanks Mark,
>>
>> I tried executing my stored procedure in the ISQL (commond prompt)
>> still I am getting the same error
>>
>>
>>
>> On Jul 2, 2:42 pm, "Mark A. Parsons"
>> <iron_horse@no_spamola.compuserve.com> wrote:
>>> The error message is being generated by the client application.
>>>
>>> If, as you say, the only component that's changed in your system is
>>> the ASE version, then perhaps your client
>>> application is having problems due its use of an older version of OCS.
>>>
>>> Have you tried modifying (recompiling?) your client application to
>>> use a 15.x version of SDK? (NOTE: name change - OCS
>>> is now called SDK)
>>>
>>> --------------
>>>
>>> As a first step in tracking down the problem I still recommend you
>>> take the client application out of the equation.
>>> This consists of submitting your queries via isql; preferably the
>>> same command-line isql that comes with the ASE 15.0.3
>>> dataserver.
>>>
>>> I'm not talking about wisql, dbisql, SQLAdvantage, nor any GUI tool
>>> ... run your 2 stored proc invocations through the
>>> command-line version of isql that comes with ASE 15.0.3. This will
>>> insure that the client application (command-line
>>> isql) is using an up-to-date version of SDK. [Objective is to see if
>>> the stored proc code runs in ASE 15.0.3 correctly
>>> without having to worry about SDK/connectivity issues.]
>>>
>>> ================= isql -U... -P... -S...
>>> use <dbname>
>>> go
>>> exec ExtractTextColumn 1, 2000
>>> go
>>> exec ExtractTextColumn 2001, 2000
>>> go
>>> =================
>>>
>>> Sam wrote:
>>>> I have a stored procedure where I am passing the offset value
>>>> (character begin) and size. My SP will look below
>>>> CREATE PROCEDURE ExtractTextColumn
>>>> @Offset INT,
>>>> @NoOfBytes INT
>>>> AS
>>>> BEGIN
>>>> DECLARE @ptr varbinary(16)
>>>> SELECT @ptr=TEXTPTR(doc_text) FROM ttextdoc WHERE
>>>> Empl_No=18242
>>>> READTEXTttextdoc.doc_text @ptr @Offset @NoOfBytes
>>>> END
>>>> I am trying to extract the binary information stored in the Text
>>>> Column bytes by bytes (say 2024 bytes for each execution)
>>>> This procedure is working fine and returning values in the Sybase
>>>> 11.0.0.3, but recently we upgraded our database to 15.0.3 with that
>>>> version it is not working fine if the offset value goes more than 1800
>>>> Below Execution 1, returns value.
>>>> ExtractTextColumn 1, 2000
>>>> Execution 2, throws error
>>>> ExtractTextColumn 2000, 2000
>>>> Error: 08:14:52.023 DBMS IRLD3R301V15 -- Layer (5), Origin (2),
>>>> Severity (7), Number (12) ct_send(): network packet layer: internal
>>>> Client Library error: State error: trying to write when connection is
>>>> expecting a read.
>>>> I hope this is very clear, kindly help me with your advice asap.
>>>> Thanks
>>>> Sam
>>


"Mark A. Parsons" <iron_horse Posted on 2009-07-02 21:45:38.0Z
From: "Mark A. Parsons" <iron_horse@no_spamola.compuserve.com>
User-Agent: Thunderbird 1.5.0.10 (Windows/20070221)
MIME-Version: 1.0
Newsgroups: sybase.public.ase.general
Subject: Re: Text Column Error while retrieving through READTEXT
References: <c12832be-1b2f-4759-8e3e-a463028b25d7@l34g2000vbi.googlegroups.com> <4a4b70e8$1@forums-3-dub.sybase.com> <b04e6469-47a5-4f92-9a82-bf9a11dabefc@c36g2000yqn.googlegroups.com> <4a4c8102@forums-3-dub.sybase.com> <c7602e1f-9d13-4749-b35b-6b4557f35671@i6g2000yqj.googlegroups.com>
In-Reply-To: <c7602e1f-9d13-4749-b35b-6b4557f35671@i6g2000yqj.googlegroups.com>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit
X-Antivirus: avast! (VPS 090702-0, 07/02/2009), Outbound message
X-Antivirus-Status: Clean
NNTP-Posting-Host: vip152.sybase.com
X-Original-NNTP-Posting-Host: vip152.sybase.com
Message-ID: <4a4d2a82$4@forums-3-dub.sybase.com>
Date: 2 Jul 2009 14:45:38 -0700
X-Trace: forums-3-dub.sybase.com 1246571138 10.22.241.152 (2 Jul 2009 14:45:38 -0700)
X-Original-Trace: 2 Jul 2009 14:45:38 -0700, vip152.sybase.com
Lines: 77
X-Authenticated-User: TeamSybase
Path: forums-1-dub!forums-master!forums-3-dub.sybase.com!not-for-mail
Xref: forums-1-dub sybase.public.ase.general:27955
Article PK: 77201

Please post:

1 - the results of running 'isql -v'

2 - the full/complete text of the error as generated by isql

Sam wrote:
> Thanks Mark,
>
> I tried executing my stored procedure in the ISQL (commond prompt)
> still I am getting the same error
>
>
>
> On Jul 2, 2:42 pm, "Mark A. Parsons"
> <iron_horse@no_spamola.compuserve.com> wrote:
>> The error message is being generated by the client application.
>>
>> If, as you say, the only component that's changed in your system is the ASE version, then perhaps your client
>> application is having problems due its use of an older version of OCS.
>>
>> Have you tried modifying (recompiling?) your client application to use a 15.x version of SDK? (NOTE: name change - OCS
>> is now called SDK)
>>
>> --------------
>>
>> As a first step in tracking down the problem I still recommend you take the client application out of the equation.
>> This consists of submitting your queries via isql; preferably the same command-line isql that comes with the ASE 15.0.3
>> dataserver.
>>
>> I'm not talking about wisql, dbisql, SQLAdvantage, nor any GUI tool ... run your 2 stored proc invocations through the
>> command-line version of isql that comes with ASE 15.0.3. This will insure that the client application (command-line
>> isql) is using an up-to-date version of SDK. [Objective is to see if the stored proc code runs in ASE 15.0.3 correctly
>> without having to worry about SDK/connectivity issues.]
>>
>> ================= isql -U... -P... -S...
>> use <dbname>
>> go
>> exec ExtractTextColumn 1, 2000
>> go
>> exec ExtractTextColumn 2001, 2000
>> go
>> =================
>>
>> Sam wrote:
>>> I have a stored procedure where I am passing the offset value
>>> (character begin) and size. My SP will look below
>>> CREATE PROCEDURE ExtractTextColumn
>>> @Offset INT,
>>> @NoOfBytes INT
>>> AS
>>> BEGIN
>>> DECLARE @ptr varbinary(16)
>>> SELECT @ptr=TEXTPTR(doc_text) FROM ttextdoc WHERE
>>> Empl_No=18242
>>> READTEXTttextdoc.doc_text @ptr @Offset @NoOfBytes
>>> END
>>> I am trying to extract the binary information stored in the Text
>>> Column bytes by bytes (say 2024 bytes for each execution)
>>> This procedure is working fine and returning values in the Sybase
>>> 11.0.0.3, but recently we upgraded our database to 15.0.3 with that
>>> version it is not working fine if the offset value goes more than 1800
>>> Below Execution 1, returns value.
>>> ExtractTextColumn 1, 2000
>>> Execution 2, throws error
>>> ExtractTextColumn 2000, 2000
>>> Error: 08:14:52.023 DBMS IRLD3R301V15 -- Layer (5), Origin (2),
>>> Severity (7), Number (12) ct_send(): network packet layer: internal
>>> Client Library error: State error: trying to write when connection is
>>> expecting a read.
>>> I hope this is very clear, kindly help me with your advice asap.
>>> Thanks
>>> Sam
>


Sam Posted on 2009-07-03 06:49:38.0Z
From: Sam <swaminathan.mn@gmail.com>
Newsgroups: sybase.public.ase.general
Subject: Re: Text Column Error while retrieving through READTEXT
Date: Thu, 2 Jul 2009 23:49:38 -0700 (PDT)
Organization: http://groups.google.com
Lines: 165
Message-ID: <e7fffe08-0501-4679-b92f-811746de6186@n11g2000yqb.googlegroups.com>
References: <c12832be-1b2f-4759-8e3e-a463028b25d7@l34g2000vbi.googlegroups.com> <4a4b70e8$1@forums-3-dub.sybase.com> <b04e6469-47a5-4f92-9a82-bf9a11dabefc@c36g2000yqn.googlegroups.com> <4a4c8102@forums-3-dub.sybase.com> <c7602e1f-9d13-4749-b35b-6b4557f35671@i6g2000yqj.googlegroups.com> <4a4d2a82$4@forums-3-dub.sybase.com>
NNTP-Posting-Host: 167.230.38.115
Mime-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable
X-Trace: posting.google.com 1246603779 8139 127.0.0.1 (3 Jul 2009 06:49:39 GMT)
X-Complaints-To: groups-abuse@google.com
NNTP-Posting-Date: Fri, 3 Jul 2009 06:49:39 +0000 (UTC)
Complaints-To: groups-abuse@google.com
Injection-Info: n11g2000yqb.googlegroups.com; posting-host=167.230.38.115; posting-account=9mhdQwkAAACFHDB2vHeFfHSP7Ru8fXGS
User-Agent: G2/1.0
X-HTTP-UserAgent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.9.0.4) Gecko/2008102920 Firefox/3.0.4,gzip(gfe),gzip(gfe)
X-HTTP-Via: 1.1 aigctcproxy:5634 (squid/2.5.STABLE6)
Path: forums-1-dub!forums-master!newssvr.sybase.com!news-sj-1.sprintlink.net!news-peer1.sprintlink.net!newsfeed.yul.equant.net!novia!news-out.readnews.com!news-xxxfer.readnews.com!postnews.google.com!n11g2000yqb.googlegroups.com!not-for-mail
Xref: forums-1-dub sybase.public.ase.general:27958
Article PK: 77205

Hi Mark,

1. The results of running isql -v is as follows

Sybase CTISQL Utility/12.5.1 ASE Edition/P-EBF11378/PC Intel/
BUILD1251-004/OPT/Thu Aug 14 11:57:18 2003

Confidential property of Sybase, Inc.
Copyright 1987, 2003
Sybase, Inc. All rights reserved.
Unpublished rights reserved under U.S. copyright laws.

This software contains confidential and trade secret information of
Sybase,
Inc. Use, duplication or disclosure of the software and
documentation by
the U.S. Government is subject to restrictions set forth in a
license
agreement between the Government and Sybase, Inc. or other
written
agreement specifying the Government's rights to use the software
and any
applicable FAR provisions, for example, FAR 52.227-19.
Sybase, Inc. One Sybase Drive, Dublin, CA 94568, USA

2 - the full/complete text of the error as generated by isql
1> alps_cr_ttextdoc_prs '093001', 2000010985, 1, 1,2000
2> GO
→♠ →♠ →♠ →♠ →♠ + R☻ } j →♠ §
j☺ ?♦ ?♦ ?♦ ?♦ ?♦
→♠
j☺ j☺ ?♥ ?♥ ? /♠ ▬ 7♣ 7♣
7♣ ?♦
▬ j☺ ?♥ j☺ ?♥ ↑♠ 7♣
?♦ ↑♠ 7♣ 7♣ ▲
õ♣ ↑ j☺
j☺
╝♣ ?♥
Á♥ ♀ ­Wá¶│o?☺ Ò♥ Ê♦ ▬ ú♣ ?♣ L E♠
0 u♠
±♣ ■ ¿♦ ( ■ ► ╝♣ ~☺ ~☺
j☺ j☺
j☺ j☺ ■ j☺ ╝♣ ?
♦ ?♦
7♣ ?♦ ?♦ ?♦ ?
♦ ?♦
→♠ →♠ ~☺ ~☺ $☺ ¾☻ $☺ !♣ ▬ ~☺
~☺ ¾☻
☻ ☺☺



WARNING! Some character(s) could not be converted into client's
character set.

Unconverted bytes were changed to question marks ('?').

(1 row affected)
(return status = 0)
1> alps_cr_ttextdoc_prs '093001', 2000010985, 1, 2001,2000
2> GO
ASE is terminating this process.
1>

Hope you may get a clue with this information.

On Jul 3, 2:45 am, "Mark A. Parsons"

<iron_horse@no_spamola.compuserve.com> wrote:
> Please post:
>
> 1 - the results of running 'isql -v'
>
> 2 - the full/complete text of the error as generated by isql
>
> Sam wrote:
> > Thanks Mark,
>
> > I tried executing my stored procedure in the ISQL (commond prompt)
> > still I am getting the same error
>
> > On Jul 2, 2:42 pm, "Mark A. Parsons"
> > <iron_horse@no_spamola.compuserve.com> wrote:
> >> The error message is being generated by the client application.
>
> >> If, as you say, the only component that's changed in your system is the ASE version, then perhaps your client
> >> application is having problems due its use of an older version of OCS.
>
> >> Have you tried modifying (recompiling?) your client application to use a 15.x version of SDK?  (NOTE: name change - OCS
> >> is now called SDK)
>
> >> --------------
>
> >> As a first step in tracking down the problem I still recommend you take the client application out of the equation.
> >> This consists of submitting your queries via isql; preferably the same command-line isql that comes with the ASE 15.0.3
> >> dataserver.
>
> >> I'm not talking about wisql, dbisql, SQLAdvantage, nor any GUI tool ... run your 2 stored proc invocations through the
> >> command-line version of isql that comes with ASE 15.0.3.  This will insure that the client application (command-line
> >> isql) is using an up-to-date version of SDK.  [Objective is to see if the stored proc code runs in ASE 15.0.3 correctly
> >> without having to worry about SDK/connectivity issues.]
>
> >> =================  isql -U... -P... -S...
> >> use <dbname>
> >> go
> >> exec ExtractTextColumn 1, 2000
> >> go
> >> exec ExtractTextColumn 2001, 2000
> >> go
> >> =================
>
> >> Sam wrote:
> >>> I have a stored procedure where I am passing the offset value
> >>> (character begin) and size.  My SP will look below
> >>> CREATE PROCEDURE ExtractTextColumn
> >>> @Offset INT,
> >>> @NoOfBytes INT
> >>> AS
> >>> BEGIN
> >>>           DECLARE @ptr varbinary(16)
> >>>           SELECT  @ptr=TEXTPTR(doc_text) FROM ttextdoc WHERE
> >>> Empl_No=18242
> >>>           READTEXTttextdoc.doc_text @ptr @Offset @NoOfBytes
> >>> END
> >>> I am trying to extract the binary information stored in the Text
> >>> Column bytes by bytes (say 2024 bytes for each execution)
> >>> This procedure is working fine and returning values in the Sybase
> >>> 11.0.0.3, but recently we upgraded our database to 15.0.3 with that
> >>> version it is not working fine if the offset value goes more than 1800
> >>> Below Execution 1, returns value.
> >>> ExtractTextColumn 1, 2000
> >>> Execution 2, throws error
> >>> ExtractTextColumn 2000, 2000
> >>> Error: 08:14:52.023    DBMS    IRLD3R301V15 -- Layer (5), Origin (2),
> >>> Severity (7), Number (12) ct_send(): network packet layer: internal
> >>> Client Library error: State error: trying to write when connection is
> >>> expecting a read.
> >>> I hope this is very clear, kindly help me with your advice asap.
> >>> Thanks
> >>> Sam


"Mark A. Parsons" <iron_horse Posted on 2009-07-03 13:34:58.0Z
From: "Mark A. Parsons" <iron_horse@no_spamola.compuserve.com>
User-Agent: Thunderbird 1.5.0.10 (Windows/20070221)
MIME-Version: 1.0
Newsgroups: sybase.public.ase.general
Subject: Re: Text Column Error while retrieving through READTEXT
References: <c12832be-1b2f-4759-8e3e-a463028b25d7@l34g2000vbi.googlegroups.com> <4a4b70e8$1@forums-3-dub.sybase.com> <b04e6469-47a5-4f92-9a82-bf9a11dabefc@c36g2000yqn.googlegroups.com> <4a4c8102@forums-3-dub.sybase.com> <c7602e1f-9d13-4749-b35b-6b4557f35671@i6g2000yqj.googlegroups.com> <4a4d2a82$4@forums-3-dub.sybase.com> <e7fffe08-0501-4679-b92f-811746de6186@n11g2000yqb.googlegroups.com>
In-Reply-To: <e7fffe08-0501-4679-b92f-811746de6186@n11g2000yqb.googlegroups.com>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 8bit
X-Antivirus: avast! (VPS 090702-0, 07/02/2009), Outbound message
X-Antivirus-Status: Clean
NNTP-Posting-Host: vip152.sybase.com
X-Original-NNTP-Posting-Host: vip152.sybase.com
Message-ID: <4a4e0902$1@forums-3-dub.sybase.com>
Date: 3 Jul 2009 06:34:58 -0700
X-Trace: forums-3-dub.sybase.com 1246628098 10.22.241.152 (3 Jul 2009 06:34:58 -0700)
X-Original-Trace: 3 Jul 2009 06:34:58 -0700, vip152.sybase.com
Lines: 140
Path: forums-1-dub!forums-master!forums-3-dub.sybase.com!not-for-mail
Xref: forums-1-dub sybase.public.ase.general:27960
Article PK: 77206

1 - I said to try running the stored procs via the isql that came with the dataserver. The 'isql -v' version string
shows that you are running with version 12.5.1 ... the isql that comes with the dataserver should show a version string
of 15.0. Try running the stored procs via the 15.0 version of isql.

2 - Your posted error message came through as garbage ... I can't tell if this is an issue with your posting software,
or if this garbage is what you received from isql. If isql generated the garbage then you would appear to have a
problem with your character set configurations.

Sam wrote:
> Hi Mark,
>
> 1. The results of running isql -v is as follows
>
> Sybase CTISQL Utility/12.5.1 ASE Edition/P-EBF11378/PC Intel/
> BUILD1251-004/OPT/Thu Aug 14 11:57:18 2003
>
> Confidential property of Sybase, Inc.
> Copyright 1987, 2003
> Sybase, Inc. All rights reserved.
> Unpublished rights reserved under U.S. copyright laws.
>
> This software contains confidential and trade secret information of
> Sybase,
> Inc. Use, duplication or disclosure of the software and
> documentation by
> the U.S. Government is subject to restrictions set forth in a
> license
> agreement between the Government and Sybase, Inc. or other
> written
> agreement specifying the Government's rights to use the software
> and any
> applicable FAR provisions, for example, FAR 52.227-19.
> Sybase, Inc. One Sybase Drive, Dublin, CA 94568, USA
>
> 2 - the full/complete text of the error as generated by isql
> 1> alps_cr_ttextdoc_prs '093001', 2000010985, 1, 1,2000
> 2> GO
> →♠ →♠ →♠ →♠ →♠ + R☻ } j →♠ §
> j☺ ?♦ ?♦ ?♦ ?♦ ?♦
> →♠
> j☺ j☺ ?♥ ?♥ ? /♠ ▬ 7♣ 7♣
> 7♣ ?♦
> ▬ j☺ ?♥ j☺ ?♥ ↑♠ 7♣
> ?♦ ↑♠ 7♣ 7♣ ▲
> õ♣ ↑ j☺
> j☺
> ╝♣ ?♥
> Á♥ ♀ ­Wá¶│o?☺ Ò♥ Ê♦ ▬ ú♣ ?♣ L E♠
> 0 u♠
> ±♣ ■ ¿♦ ( ■ ► ╝♣ ~☺ ~☺
> j☺ j☺
> j☺ j☺ ■ j☺ ╝♣ ?
> ♦ ?♦
> 7♣ ?♦ ?♦ ?♦ ?
> ♦ ?♦
> →♠ →♠ ~☺ ~☺ $☺ ¾☻ $☺ !♣ ▬ ~☺
> ~☺ ¾☻
> ☻ ☺☺
>
>
>
> WARNING! Some character(s) could not be converted into client's
> character set.
>
> Unconverted bytes were changed to question marks ('?').
>
> (1 row affected)
> (return status = 0)
> 1> alps_cr_ttextdoc_prs '093001', 2000010985, 1, 2001,2000
> 2> GO
> ASE is terminating this process.
> 1>
>
> Hope you may get a clue with this information.
>
> On Jul 3, 2:45 am, "Mark A. Parsons"
> <iron_horse@no_spamola.compuserve.com> wrote:
>> Please post:
>>
>> 1 - the results of running 'isql -v'
>>
>> 2 - the full/complete text of the error as generated by isql
>>
>> Sam wrote:
>>> Thanks Mark,
>>> I tried executing my stored procedure in the ISQL (commond prompt)
>>> still I am getting the same error
>>> On Jul 2, 2:42 pm, "Mark A. Parsons"
>>> <iron_horse@no_spamola.compuserve.com> wrote:
>>>> The error message is being generated by the client application.
>>>> If, as you say, the only component that's changed in your system is the ASE version, then perhaps your client
>>>> application is having problems due its use of an older version of OCS.
>>>> Have you tried modifying (recompiling?) your client application to use a 15.x version of SDK? (NOTE: name change - OCS
>>>> is now called SDK)
>>>> --------------
>>>> As a first step in tracking down the problem I still recommend you take the client application out of the equation.
>>>> This consists of submitting your queries via isql; preferably the same command-line isql that comes with the ASE 15.0.3
>>>> dataserver.
>>>> I'm not talking about wisql, dbisql, SQLAdvantage, nor any GUI tool ... run your 2 stored proc invocations through the
>>>> command-line version of isql that comes with ASE 15.0.3. This will insure that the client application (command-line
>>>> isql) is using an up-to-date version of SDK. [Objective is to see if the stored proc code runs in ASE 15.0.3 correctly
>>>> without having to worry about SDK/connectivity issues.]
>>>> ================= isql -U... -P... -S...
>>>> use <dbname>
>>>> go
>>>> exec ExtractTextColumn 1, 2000
>>>> go
>>>> exec ExtractTextColumn 2001, 2000
>>>> go
>>>> =================
>>>> Sam wrote:
>>>>> I have a stored procedure where I am passing the offset value
>>>>> (character begin) and size. My SP will look below
>>>>> CREATE PROCEDURE ExtractTextColumn
>>>>> @Offset INT,
>>>>> @NoOfBytes INT
>>>>> AS
>>>>> BEGIN
>>>>> DECLARE @ptr varbinary(16)
>>>>> SELECT @ptr=TEXTPTR(doc_text) FROM ttextdoc WHERE
>>>>> Empl_No=18242
>>>>> READTEXTttextdoc.doc_text @ptr @Offset @NoOfBytes
>>>>> END
>>>>> I am trying to extract the binary information stored in the Text
>>>>> Column bytes by bytes (say 2024 bytes for each execution)
>>>>> This procedure is working fine and returning values in the Sybase
>>>>> 11.0.0.3, but recently we upgraded our database to 15.0.3 with that
>>>>> version it is not working fine if the offset value goes more than 1800
>>>>> Below Execution 1, returns value.
>>>>> ExtractTextColumn 1, 2000
>>>>> Execution 2, throws error
>>>>> ExtractTextColumn 2000, 2000
>>>>> Error: 08:14:52.023 DBMS IRLD3R301V15 -- Layer (5), Origin (2),
>>>>> Severity (7), Number (12) ct_send(): network packet layer: internal
>>>>> Client Library error: State error: trying to write when connection is
>>>>> expecting a read.
>>>>> I hope this is very clear, kindly help me with your advice asap.
>>>>> Thanks
>>>>> Sam
>


"Mark A. Parsons" <iron_horse Posted on 2009-07-04 18:13:51.0Z
From: "Mark A. Parsons" <iron_horse@no_spamola.compuserve.com>
User-Agent: Thunderbird 1.5.0.10 (Windows/20070221)
MIME-Version: 1.0
Newsgroups: sybase.public.ase.general
Subject: Re: Text Column Error while retrieving through READTEXT
References: <c12832be-1b2f-4759-8e3e-a463028b25d7@l34g2000vbi.googlegroups.com> <4a4b70e8$1@forums-3-dub.sybase.com> <b04e6469-47a5-4f92-9a82-bf9a11dabefc@c36g2000yqn.googlegroups.com> <4a4c8102@forums-3-dub.sybase.com> <c7602e1f-9d13-4749-b35b-6b4557f35671@i6g2000yqj.googlegroups.com> <4a4d2a82$4@forums-3-dub.sybase.com> <e7fffe08-0501-4679-b92f-811746de6186@n11g2000yqb.googlegroups.com> <4a4e0902$1@forums-3-dub.sybase.com>
In-Reply-To: <4a4e0902$1@forums-3-dub.sybase.com>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 8bit
X-Antivirus: avast! (VPS 090703-0, 07/03/2009), Outbound message
X-Antivirus-Status: Clean
NNTP-Posting-Host: vip152.sybase.com
X-Original-NNTP-Posting-Host: vip152.sybase.com
Message-ID: <4a4f9bdf$1@forums-3-dub.sybase.com>
Date: 4 Jul 2009 11:13:51 -0700
X-Trace: forums-3-dub.sybase.com 1246731231 10.22.241.152 (4 Jul 2009 11:13:51 -0700)
X-Original-Trace: 4 Jul 2009 11:13:51 -0700, vip152.sybase.com
Lines: 154
X-Authenticated-User: TeamSybase
Path: forums-1-dub!forums-master!forums-3-dub.sybase.com!not-for-mail
Xref: forums-1-dub sybase.public.ase.general:27961
Article PK: 77207

... and now you're calling a different stored proc than previously defined in this thread.

Mark A. Parsons wrote:
> 1 - I said to try running the stored procs via the isql that came with
> the dataserver. The 'isql -v' version string shows that you are running
> with version 12.5.1 ... the isql that comes with the dataserver should
> show a version string of 15.0. Try running the stored procs via the
> 15.0 version of isql.
>
> 2 - Your posted error message came through as garbage ... I can't tell
> if this is an issue with your posting software, or if this garbage is
> what you received from isql. If isql generated the garbage then you
> would appear to have a problem with your character set configurations.
>
> Sam wrote:
>> Hi Mark,
>>
>> 1. The results of running isql -v is as follows
>>
>> Sybase CTISQL Utility/12.5.1 ASE Edition/P-EBF11378/PC Intel/
>> BUILD1251-004/OPT/Thu Aug 14 11:57:18 2003
>>
>> Confidential property of Sybase, Inc.
>> Copyright 1987, 2003
>> Sybase, Inc. All rights reserved.
>> Unpublished rights reserved under U.S. copyright laws.
>>
>> This software contains confidential and trade secret information of
>> Sybase,
>> Inc. Use, duplication or disclosure of the software and
>> documentation by
>> the U.S. Government is subject to restrictions set forth in a
>> license
>> agreement between the Government and Sybase, Inc. or other
>> written
>> agreement specifying the Government's rights to use the software
>> and any
>> applicable FAR provisions, for example, FAR 52.227-19.
>> Sybase, Inc. One Sybase Drive, Dublin, CA 94568, USA
>>
>> 2 - the full/complete text of the error as generated by isql
>> 1> alps_cr_ttextdoc_prs '093001', 2000010985, 1, 1,2000
>> 2> GO
>> →♠ →♠ →♠ →♠ →♠ + R☻ } j →♠ §
>> j☺ ?♦ ?♦ ?♦ ?♦ ?♦
>> →♠
>> j☺ j☺ ?♥ ?♥ ? /♠ ▬ 7♣ 7♣
>> 7♣ ?♦
>> ▬ j☺ ?♥ j☺ ?♥ ↑♠ 7♣
>> ?♦ ↑♠ 7♣ 7♣ ▲
>> õ♣ ↑ j☺
>> j☺
>> ╝♣ ?♥
>> Á♥ ♀ ­Wá¶│o?☺ Ò♥ Ê♦ ▬ ú♣ ?♣ L E♠
>> 0 u♠
>> ±♣ ■ ¿♦ ( ■ ► ╝♣ ~☺ ~☺
>> j☺ j☺
>> j☺ j☺ ■ j☺ ╝♣ ?
>> ♦ ?♦
>> 7♣ ?♦ ?♦ ?♦ ?
>> ♦ ?♦
>> →♠ →♠ ~☺ ~☺ $☺ ¾☻ $☺ !♣ ▬ ~☺
>> ~☺ ¾☻
>> ☻ ☺☺
>>
>>
>>
>> WARNING! Some character(s) could not be converted into client's
>> character set.
>>
>> Unconverted bytes were changed to question marks ('?').
>>
>> (1 row affected)
>> (return status = 0)
>> 1> alps_cr_ttextdoc_prs '093001', 2000010985, 1, 2001,2000
>> 2> GO
>> ASE is terminating this process.
>> 1>
>>
>> Hope you may get a clue with this information.
>>
>> On Jul 3, 2:45 am, "Mark A. Parsons"
>> <iron_horse@no_spamola.compuserve.com> wrote:
>>> Please post:
>>>
>>> 1 - the results of running 'isql -v'
>>>
>>> 2 - the full/complete text of the error as generated by isql
>>>
>>> Sam wrote:
>>>> Thanks Mark,
>>>> I tried executing my stored procedure in the ISQL (commond prompt)
>>>> still I am getting the same error
>>>> On Jul 2, 2:42 pm, "Mark A. Parsons"
>>>> <iron_horse@no_spamola.compuserve.com> wrote:
>>>>> The error message is being generated by the client application.
>>>>> If, as you say, the only component that's changed in your system is
>>>>> the ASE version, then perhaps your client
>>>>> application is having problems due its use of an older version of OCS.
>>>>> Have you tried modifying (recompiling?) your client application to
>>>>> use a 15.x version of SDK? (NOTE: name change - OCS
>>>>> is now called SDK)
>>>>> --------------
>>>>> As a first step in tracking down the problem I still recommend you
>>>>> take the client application out of the equation.
>>>>> This consists of submitting your queries via isql; preferably the
>>>>> same command-line isql that comes with the ASE 15.0.3
>>>>> dataserver.
>>>>> I'm not talking about wisql, dbisql, SQLAdvantage, nor any GUI tool
>>>>> ... run your 2 stored proc invocations through the
>>>>> command-line version of isql that comes with ASE 15.0.3. This will
>>>>> insure that the client application (command-line
>>>>> isql) is using an up-to-date version of SDK. [Objective is to see
>>>>> if the stored proc code runs in ASE 15.0.3 correctly
>>>>> without having to worry about SDK/connectivity issues.]
>>>>> ================= isql -U... -P... -S...
>>>>> use <dbname>
>>>>> go
>>>>> exec ExtractTextColumn 1, 2000
>>>>> go
>>>>> exec ExtractTextColumn 2001, 2000
>>>>> go
>>>>> =================
>>>>> Sam wrote:
>>>>>> I have a stored procedure where I am passing the offset value
>>>>>> (character begin) and size. My SP will look below
>>>>>> CREATE PROCEDURE ExtractTextColumn
>>>>>> @Offset INT,
>>>>>> @NoOfBytes INT
>>>>>> AS
>>>>>> BEGIN
>>>>>> DECLARE @ptr varbinary(16)
>>>>>> SELECT @ptr=TEXTPTR(doc_text) FROM ttextdoc WHERE
>>>>>> Empl_No=18242
>>>>>> READTEXTttextdoc.doc_text @ptr @Offset @NoOfBytes
>>>>>> END
>>>>>> I am trying to extract the binary information stored in the Text
>>>>>> Column bytes by bytes (say 2024 bytes for each execution)
>>>>>> This procedure is working fine and returning values in the Sybase
>>>>>> 11.0.0.3, but recently we upgraded our database to 15.0.3 with that
>>>>>> version it is not working fine if the offset value goes more than
>>>>>> 1800
>>>>>> Below Execution 1, returns value.
>>>>>> ExtractTextColumn 1, 2000
>>>>>> Execution 2, throws error
>>>>>> ExtractTextColumn 2000, 2000
>>>>>> Error: 08:14:52.023 DBMS IRLD3R301V15 -- Layer (5), Origin (2),
>>>>>> Severity (7), Number (12) ct_send(): network packet layer: internal
>>>>>> Client Library error: State error: trying to write when connection is
>>>>>> expecting a read.
>>>>>> I hope this is very clear, kindly help me with your advice asap.
>>>>>> Thanks
>>>>>> Sam
>>


Rob V [Sybase] Posted on 2009-07-01 13:13:28.0Z
Reply-To: "Rob V [Sybase]" <robv@DO.NOT.SPAM.sypron.nl.REMOVE.THIS.DECOY>
From: "Rob V [Sybase]" <robv@DO.NOT.SPAM.sypron.nl.REMOVE.THIS.DECOY>
Newsgroups: sybase.public.ase.general
References: <c12832be-1b2f-4759-8e3e-a463028b25d7@l34g2000vbi.googlegroups.com>
Subject: Re: Text Column Error while retrieving through READTEXT
Lines: 58
Organization: Sypron BV / TeamSybase / Sybase Inc
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.3138
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.3350
X-RFC2646: Format=Flowed; Original
NNTP-Posting-Host: vip152.sybase.com
X-Original-NNTP-Posting-Host: vip152.sybase.com
Message-ID: <4a4b60f8@forums-3-dub.sybase.com>
Date: 1 Jul 2009 06:13:28 -0700
X-Trace: forums-3-dub.sybase.com 1246454008 10.22.241.152 (1 Jul 2009 06:13:28 -0700)
X-Original-Trace: 1 Jul 2009 06:13:28 -0700, vip152.sybase.com
Path: forums-1-dub!forums-master!forums-3-dub.sybase.com!not-for-mail
Xref: forums-1-dub sybase.public.ase.general:27938
Article PK: 77188

You should really open a case with Sybase TechSupport for this.

HTH,

Rob V.
-----------------------------------------------------------------
Rob Verschoor

Certified Sybase Professional DBA for ASE 15.0/12.5/12.0/11.5/11.0
and Replication Server 15.0.1/12.5 // TeamSybase

Author of Sybase books (order online at www.sypron.nl/shop):
"Tips, Tricks & Recipes for Sybase ASE" (ASE 15 edition)
"The Complete Sybase ASE Quick Reference Guide"
"The Complete Sybase Replication Server Quick Reference Guide"

mailto:rob@YOUR.SPAM.sypron.nl.NOT.FOR.ME
http://www.sypron.nl
Sypron B.V., Amersfoort, The Netherlands
Chamber of Commerce 27138666
-----------------------------------------------------------------

"Sam" <swaminathan.mn@gmail.com> wrote in message
news:c12832be-1b2f-4759-8e3e-a463028b25d7@l34g2000vbi.googlegroups.com...
ASE server is terminating when I reposition the starting
column in Sybase 15 version. Execution 1, executes well and
returning row, but execution 2 does not executes and end up
with the error ASE server is terminating.

Execution 1: Not getting any errors
[
DECLARE @ptr varbinary(16)
SELECT @ptr=TEXTPTR(doc_text) FROM ttextdoc
READTEXT ttextdoc.doc_text @ptr 1 2000
]

Execution 2: Getting error when repositioning
[
DECLARE @ptr varbinary(16)
SELECT @ptr=TEXTPTR(doc_text) FROM ttextdoc


READTEXT ttextdoc.doc_text @ptr 2001 2000
]

Error: “08:14:52.023 DBMS IRLD3R301V15 -- Layer
(5), Origin (2), Severity (7), Number (12) ct_send():
network packet layer: internal Client Library error: State
error: trying to write when connection is expecting a
read.”


Please help.
Thanks in advance

Sam