Skip to Content.
Sympa Menu

freetds - RE: [freetds] sqsh and msrepl_tran_version

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] sqsh and msrepl_tran_version
  • Date: Mon, 7 Jul 2003 16:00:55 -0400

> From: Arnar Birgisson [mailto:ArnarB AT oddi.is]
> Sent: July 7, 2003 8:42 AM
>
> msrepl_tran_version is of SQL Server specific type uniqueidentifier,
> which is a 16-byte value. I don't know how it appears in the protocol,
> wheter it's the raw 16 bytes, or if it's a hex string (which
> is accepted
> as the input for such fields) on the form
> xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx

Arnar,

Thank you for the clarification. :-)

IIRC, sqsh doesn't understand datatype "uniqueidentifier". If anyone wants
to post a patch for sqsh to fix that, I'd be happy to apply it.

Whether or not PHP handles it, I don't know.

FreeTDS's built-in conversion functions can convert uniqueidentifier to
char/varchar and back. That feature became available in 0.60:

$ tsql -U$U -P$P -S$S
locale is "C"
locale charset is "646"
Msg 5703, Level 0, State 1, Server NTS0214, Line 0
Changed language setting to us_english.
1> create table #a(u uniqueidentifier, i int)
2> insert #a values (newid(), 1) select * from #a
3> go
u i
95B3E114-B023-11D7-BAA5-0004ACE38BF3 1
1>

--jkl

> On Mon, 7 Jul 2003 03:59:15 +0000 (GMT), Andrew Stevenson
> <andrews AT ntt.net.au> wrote:
> > I have a database hosted under MS-SQL that I connect to via freetds
> > (0.60). The DB is replicated to another server and so the magical
> field
> > msrepl_tran_version appears in all the tables. I am unable to run a
> > query that returns this field.
> >
> > Using sqsh I get no results, just the colomn headings.
> Using perl/DBI
> I
> > get:
> >
> > error_handler: Data-conversion resulted in overflow.
-----------------------------------------
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.






Archive powered by MHonArc 2.6.24.

Top of Page