Skip to Content.
Sympa Menu

freetds - RE: [freetds] RPC/Packet Type 3 Format

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: <lists-tds AT mymailfilter.net>
  • To: FreeTDS Development Group <freetds AT lists.ibiblio.org>
  • Subject: RE: [freetds] RPC/Packet Type 3 Format
  • Date: Thu, 17 Jul 2003 15:52:03 -0500 (CDT)

Thanks James, I've included some additional information based on your
responses below in hopes that someone can provide additional details.

On Thu, 17 Jul 2003, Lowden, James K wrote:

> > Also, there are sometimes characters inserted within the SQL code (in
> > between parameters and such (N' 2 & etc). Are the rules
> > surrounding this known?
>
> Your example doesn't show any such. The first explanation that comes to
> mind is that some character data must be explicitly UCS-2, represented as
>
> N'your stuff here'

Quite right, my example didn't show the characters. Yet, your response
indicates what I should know to be true: the parameter types MUST be known
somehow, so the N' can be inserted. Correct? If so, are the parameter
types sent BEFORE the procedure call or with it?

> > And finally, there is a bit of a "trailer" on the end of each
> > packet.
>
> 0120 00 74 00 0d 00 0a 00 00 00 26 04 04 01 00 00 00
> \0 t \0 CR \0 LF \0 \0 ?? ?? ?? ^^ ^^ ^^^^^ ^^
> | | | 3 more?
> | | + length=0
> | + final
> + Response packet
>
> I see a CR/LF pair, a null terminator (or so), two unknown bytes, and a
> server response. I think.

What is your reference to "3 more?" Three more what? I'm not sure if
that's a clarification for me or if you're saying some bytes are missing?

I don't know if it's a server response, as this packet was sent from the
client to the server. Could it still be a server response? I'm just not
sure, but this packet was definitely on the wire going TOWARD the server.





Archive powered by MHonArc 2.6.24.

Top of Page