freetds AT lists.ibiblio.org
Subject: FreeTDS Development Group
List archive
mssql_query error (additional chars return or nothing)
- From: "ThoMo" <thomo AT gmx.de>
- To: freetds AT franklin.oit.unc.edu
- Subject: mssql_query error (additional chars return or nothing)
- Date: Thu, 17 Jan 2002 05:41:35 -0500
Hello,
if I use the following example programm to connect from my linux box to a
MS SQL 7.0 Server I get different answers in netscape (linux) and ie 5.5
(w2k) (see below).
Using netscape only 1 line is returned while ie 5.5 shows all lines but
append to the data an additional char. It looks like it is a char of a
previous line.
Any suggestions?
system desc.:
rh 7.1
apache 1.3.22
freetds 0.53
php 4.0.6
w2k server
MS SQL 7 (SP x)
---- example program --------
$dbc = mssql_connect($db_server,$db_user,$db_passwd);
if ($dbc)
{
print "Connected<br>";
$res = mssql_query(
"SELECT DISTINCT ANSPRECHPARTNER FROM ISW_MELDUNGEN ");
while ($row = mssql_fetch_row($res))
{
if (!strlen($row[0])) continue;
print_r($row);
}
mssql_free_result($res);
mssql_close($dbc);
}
else
{
print "no connection<br>";
}
------- NETSCAPE OUTPUT (linux) ----------
<body>
Verbindung hergestellt<br>Array
(
[0] => Muller</body>
------------------------------------------
------- IE 5.5 OUTPUT --------------------
<body>
Verbindung hergestellt<br>Array
(
[0] => Muller
)
Array
(
[0] => paul r <-- the "r" are wrong
)
Array
(
[0] => yyyy r <-- the "r" are wrong
)
Array
(
[0] => k.a. r <-- the "r" are wrong
)
Array
(
[0] => xx . <-- the "." are wrong
)
Array
(
[0] => Naier
)
</body>
------------------------------------------
------- RESULT OF the same query in sql query analyser ---------
SQL QUERY ANALYSER
ANSPRECHPARTNER
--------------------------------------------------
Muller
paul
yyyy
k.a.
xx
NULL
Naier
(8 row(s) affected)
- mssql_query error (additional chars return or nothing), ThoMo, 01/17/2002
Archive powered by MHonArc 2.6.24.