freetds AT lists.ibiblio.org
Subject: FreeTDS Development Group
List archive
[workaround] php-3/freetds/mssql 6.5 BLOB TEXT an BINARY
- From: Franck Martin <Franck AT sopac.org.fj>
- To: 'TDS Development Group' <freetds AT franklin.oit.unc.edu>
- Subject: [workaround] php-3/freetds/mssql 6.5 BLOB TEXT an BINARY
- Date: Tue, 9 May 2000 09:42:03 +1200
I don't know which fault is it freetds or php, but a BLOB of type TEXT
cannot be retreived in its total length...
Therefore you extract it by chuncks of 255 character or less with the
command
$i=1;
$result2=sybase_query("select SUBSTRING(Contents,1,200) as subcontents from
[*****] Where PRID=".$PRID,$conn);
$arr_row2=sybase_fetch_row($result2);
While ($arr_row2[0]!="")
{
echo(nl2br($arr_row2[0]));
$ok=sybase_free_result($result2);
$i+=200;
$result2=sybase_query("select SUBSTRING(Contents,$i,200) as
subcontents from [*****] Where PRID=".$PRID,$conn);
$arr_row2=sybase_fetch_row($result2);
}
I'm trying to do the same thing with binary BLOB (JPEG image), but it does
not work (crash?). I don't know if it is because php cannot handle binary
data, but only strings or float or if i
Anybody has an idea on the subject ?
Franck Martin
Network and Database Development Officer
SOPAC South Pacific Applied Geoscience Commission
Fiji
E-mail: franck AT sopac.org.fj <mailto:franck AT sopac.org.fj>
Web site: www.sopac.org.fj <http://www.sopac.org.fj>
- [workaround] php-3/freetds/mssql 6.5 BLOB TEXT an BINARY, Franck Martin, 05/08/2000
Archive powered by MHonArc 2.6.24.