Skip to Content.
Sympa Menu

freetds - RE: [freetds] output parameters and "unknown marker"

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: "Lowden, James K" <LowdenJK AT bernstein.com>
  • To: "FreeTDS Development Group" <freetds AT lists.ibiblio.org>
  • Subject: RE: [freetds] output parameters and "unknown marker"
  • Date: Thu, 6 Jan 2005 12:00:20 -0500

> From: Thompson, Bill D (London)
> Sent: Thursday, January 06, 2005 11:33 AM
>
> certainly our code seems not to handle the data that's coming our way...
> I think the issue might be with using TDS 8.0 rather than 7.0 - I didn't
> know there was a difference in the AC(param) token between these two
> versions but there does appear to be...

Bill,

Could it be that datatype 3D (datetime) should be treated as variable length?


Here's my analysis of the packet, based on
http://www.freetds.org/tds.html#responses:

Return Status:
79 00 00 00 00
(zero)


Output Parameter 1:
ac 1100 05 4000 6c00 6100 7300 7400 01 3d 00 00 00 3d 00
(5-char name) (5 bytes unk.) ^^ length?


Output Parameter 2:
ac 1100 05 4000 7000 7200 6500 7600 01 3d 00 00 00 3d 00
(5-char name) (5 bytes unk.) ^^ length?

Process Done:
fe 0000 e000 01000000
(no more results, row count not valid)

I imagine the "unknown" bytes are collation data.


--jkl

>
>
> -----Original Message-----
> From: freetds-bounces AT lists.ibiblio.org
> [mailto:freetds-bounces AT lists.ibiblio.org] On Behalf Of Paparo, Joshua
> Sent: 06 January 2005 16:08
> To: FreeTDS Development Group
> Subject: [freetds] output parameters and "unknown marker"
>
>
> Hello,
>
> I've been using freetds on linux (0.63RC5) to connect with SQL2000 and
> am running into problems with return parameters on stored procedures.
>
> I'm getting the "unknown marker" message when I call dbresults() which,
> as the FAQ mentions, is usually due to a mismatch between server and TDS
> version.
>
> I've been using version 8.0 the whole time and not previously seen this.
> I'm not sure if there are any other reasons for this particular message.
>
>
> I've include the tail of the dump file below.
>
> Thanks,
>
> Josh Paparo
>
>
> 15:51:54.951479 dbrpcinit() added rpcname "dbo.pdtGetDealRevalDates"
> 15:51:54.951507 dbrpcparam() added parameter "@dealid"
> 15:51:54.951535 dbrpcparam() added parameter "@pricingDate"
> 15:51:54.951571 dbrpcparam() added parameter "@last" /* LAST TWO ARE
> OUTPUT PARAMS*/
> 15:51:54.951600 dbrpcparam() added parameter "@prev"
> 15:51:54.951615 dbrpcsend()
> 15:51:54.951630 parm_info_alloc(): parameter null-ness = 0
> 15:51:54.951643 param_row_alloc, size = 4, offset = 4, row_size = 8
> 15:51:54.951651 param_row_alloc(): doing data from value
> 15:51:54.951657 param_row_alloc(): copying 4 bytes of data to parameter #0
> 15:51:54.951666 parm_info_alloc(): parameter null-ness = 0
> 15:51:54.951675 param_row_alloc, size = 8, offset = 8, row_size = 16
> 15:51:54.951683 param_row_alloc(): doing data from value
> 15:51:54.951690 param_row_alloc(): copying 8 bytes of data to parameter #1
> 15:51:54.951699 parm_info_alloc(): parameter null-ness = 0
> 15:51:54.951708 param_row_alloc, size = 8, offset = 16, row_size = 24
> 15:51:54.951716 param_row_alloc(): doing data from value
> 15:51:54.951723 param_row_alloc(): copying 8 bytes of data to parameter #2
> 15:51:54.951732 parm_info_alloc(): parameter null-ness = 0
> 15:51:54.951741 param_row_alloc, size = 8, offset = 24, row_size = 32
> 15:51:54.951748 param_row_alloc(): doing data from value
> 15:51:54.951755 param_row_alloc(): copying 8 bytes of data to parameter #3
> 15:51:54.951762 tds_free_all_results()
> 15:51:54.951782 tds_put_data_info putting param_name
> 15:51:54.951792 tds_put_data_info putting status
> 15:51:54.951800 tds_put_data: is_null = 0, colsize = 4
> 15:51:54.951809 tds_put_data: not null param varint_size = 0
> 15:51:54.951817 tds_put_data_info putting param_name
> 15:51:54.951826 tds_put_data_info putting status
> 15:51:54.951833 tds_put_data: is_null = 0, colsize = 8
> 15:51:54.951842 tds_put_data: not null param varint_size = 0
> 15:51:54.951849 tds_put_data_info putting param_name
> 15:51:54.951857 tds_put_data_info putting status
> 15:51:54.951865 tds_put_data: is_null = 0, colsize = 8
> 15:51:54.951873 tds_put_data: not null param varint_size = 0
> 15:51:54.951880 tds_put_data_info putting param_name
> 15:51:54.951888 tds_put_data_info putting status
> 15:51:54.951896 tds_put_data: is_null = 0, colsize = 8
> 15:51:54.951903 tds_put_data: not null param varint_size = 0
> 15:51:54.951920 Sending packet
> 0000 03 01 00 9e 00 00 01 00-18 00 64 00 62 00 6f 00 |........ ..d.b.o.|
> 0010 2e 00 70 00 64 00 74 00-47 00 65 00 74 00 44 00 |..p.d.t. G.e.t.D.|
> 0020 65 00 61 00 6c 00 52 00-65 00 76 00 61 00 6c 00 |e.a.l.R. e.v.a.l.|
> 0030 44 00 61 00 74 00 65 00-73 00 00 00 07 40 00 64 |D.a.t.e. s....@.d|
> 0040 00 65 00 61 00 6c 00 69-00 64 00 00 38 6e 78 00 |.e.a.l.i .d..8nx.|
> 0050 00 0c 40 00 70 00 72 00-69 00 63 00 69 00 6e 00 |..@.p.r. i.c.i.n.|
> 0060 67 00 44 00 61 00 74 00-65 00 00 3d d4 95 00 00 |g.D.a.t. e..=Ô...|
> 0070 00 00 00 00 05 40 00 6c-00 61 00 73 00 74 00 01 |.....@.l .a.s.t..|
> 0080 3d d4 95 00 00 00 00 00-00 05 40 00 70 00 72 00 |=Ô...... .@.p.r.|
> 0090 65 00 76 00 01 3d d4 95-00 00 00 00 00 00 |e.v..=Ô. .....|
>
> 15:51:54.952011 in dbsqlok()
> 15:51:54.952724 Received header
> 0000 04 01 00 52 00 37 01 00- |...R.7..|
>
> 15:51:54.952742 Received packet
> 0000 ff 11 00 c1 00 01 00 00-00 ff 11 00 c1 00 01 00 |ÿ..Á.... ÿ..Á...|
> 0010 00 00 79 00 00 00 00 ac-11 00 05 40 00 6c 00 61 |..y....¬ ..@.l.a|
> 0020 00 73 00 74 00 01 3d 00-00 00 3d 00 ac 11 00 05 |.s.t..=. .=.¬...|
> 0030 40 00 70 00 72 00 65 00-76 00 01 3d 00 00 00 3d |@.p.r.e. v..=...=|
> 0040 00 fe 00 00 e0 00 01 00-00 00 |.þ..à... ..|
>
> 15:51:54.952780 dbsqlok() marker is ff
> 15:51:54.952792 processing result tokens. marker is ff(DONEINPROC)
> 15:51:54.952801 tds_process_end: more_results = 1
> was_cancelled = 0
> error = 0
> done_count_valid = 1
> 15:51:54.952810 rows_affected = 1
> 15:51:54.952817 dbsqlok() marker is ff
> 15:51:54.952825 processing result tokens. marker is ff(DONEINPROC)
> 15:51:54.952833 tds_process_end: more_results = 1
> was_cancelled = 0
> error = 0
> done_count_valid = 1
> 15:51:54.952841 rows_affected = 1
> 15:51:54.952849 dbsqlok() marker is 79
> 15:51:54.952856 dbsqlok() found result token
> 15:52:42.655707 dbresults()
> 15:53:00.887910 processing result tokens. marker is 79(RETURNSTATUS)
> 15:53:00.887976 tds_process_result_tokens: return status is 0
> 15:53:03.847211 dbresults() process_result_tokens returned result_type =
> 4043 retcode = 1
> 15:53:07.865110 processing result tokens. marker is ac(PARAM)
> 15:53:07.865190 tds_get_string: reading 10 from wire to give 5 to client.
> 15:53:07.865212 processing result. type = 61(datetime), varint_size 0
> 15:53:07.865221 processing result. column_size 8
> 15:53:07.865232 processing row. column is 0 varint size = 0
> 15:53:07.865241 processing row. column size is 8
> 15:53:07.865248 clearing column 0 NULL bit
> 15:53:11.311076 dbresults() process_result_tokens returned result_type =
> 4042 retcode = 1
> 15:53:37.114574 processing result tokens. marker is 0()
> 15:53:37.114637 tds_process_default_tokens() marker is 0()
> 15:53:37.114727 tds_client_msg: #20020: "Unknown marker". Connection state
> is now 0.
> 15:53:37.114769 Unknown marker: 0(0)!!
> 15:54:25.586693 dbresults() process_result_tokens returned result_type =
> 4042 retcode = 0

-----------------------------------------
The information contained in this transmission may contain privileged and
confidential information and is intended only for the use of the person(s)
named above. If you are not the intended recipient, or an employee or agent
responsible for delivering this message to the intended recipient, any
review, dissemination, distribution or duplication of this communication is
strictly prohibited. If you are not the intended recipient, please contact
the sender immediately by reply e-mail and destroy all copies of the original
message. Please note that we do not accept account orders and/or instructions
by e-mail, and therefore will not be responsible for carrying out such orders
and/or instructions.
If you, as the intended recipient of this message, the purpose of which is to
inform and update our clients, prospects and consultants of developments
relating to our services and products, would not like to receive further
e-mail correspondence from the sender, please "reply" to the sender
indicating your wishes. In the U.S.: 1345 Avenue of the Americas, New York,
NY 10105.






Archive powered by MHonArc 2.6.24.

Top of Page