freetds AT lists.ibiblio.org
Subject: FreeTDS Development Group
List archive
- From: Mike Groeneweg <mikeg AT scorpion.murdoch.edu.au>
- To: freetds AT franklin.oit.unc.edu
- Subject: FreeTDS 0.47/0.50 & MS-SQL 7.0 & DBD::Sybase 0.21
- Date: Mon, 20 Dec 1999 13:06:22 +0800
Greetings,
Does anybody have any tips on what possibly I am doing wrong (if it is
me at all)?
I was using FreeTDS 0.47 and DBD::Sybase 0.21 to talk to a MS SQL Server
7.0 system. They were talking okay - ie I could information into and out
of the database... but every transaction that I did generated the
message: 'Unknown Property 7'
So, last last week, I was trawling around the 'net again, and saw that
FreeTDS 0.50 was out. I compiled it up - the only flag I set were to
force version 4.2 protocol and the --prefix install directory. I didn't
change DBD::Sybase (version 0.21). My same perl program now cannot
'prepare' the SQL query, issuing an error message "Unclosed quotation
mark before the character string '9002'".
The code fragment from perl was this:
my $inner_query = "SELECT primary_extension, last_name, first_name,
udf1_recID, udf2_recID, udf17_recID,
udf18_recID, udf19_recID, udf20_recID
FROM subscriber
WHERE primary_extension <> '$row[0]' AND
udf1_recID = '$row[3]' AND
udf2_recID = '$row[4]'
";
then I do:
my $sth2 = $dbh->prepare($inner_query);
to debug it, I printed the $inner_query variable to make sure the SQL
looked right, this is it:
SELECT primary_extension, last_name, first_name,
udf1_recID, udf2_recID, udf17_recID,
udf18_recID, udf19_recID, udf20_recID
FROM subscriber
WHERE primary_extension <> '9002' AND
udf1_recID = '611' AND
udf2_recID = '1012'
I've got code in before the $inner_query string is set, to ensure that
any "'" (single quote) is quoted again - to comply with MS-SQL 7.0
requirements (I assume same for Sybase).
But as you can see, the $inner_query string - SQL SELECT statement -
looks valid IMHO. What is going on? FreeTDS 0.47 will do it, but with
the 'Unknown Property 7' and FreeTDS 0.50 just baulks completely.
Other details: Perl is version 5.0502, DBD::Sybase is 0.21, running on
an Ultra10, Solaris 7.0 with most of the latest patches.
Any help appreciated.
Thanks
Mike Groeneweg
--
-=--=--=--=--=--=--=--=--=--=--=--=--=--=--=--=--=--=--=--=--=--=-
,-._|\ M.Groeneweg AT murdoch.edu.au
/ Oz \ Workstation & Network Officer
x_,--._/ ITS Murdoch University
v Western Australia
Ph: (+618) 9360 2766 Fax: (+618) 9360 6156
``Vi is my shepherd, I shall not font.''
-
FreeTDS 0.47/0.50 & MS-SQL 7.0 & DBD::Sybase 0.21,
Mike Groeneweg, 12/20/1999
- <Possible follow-up(s)>
- Re: FreeTDS 0.47/0.50 & MS-SQL 7.0 & DBD::Sybase 0.21, Brian Bruns, 12/21/1999
Archive powered by MHonArc 2.6.24.