mssql_guid_string

(PHP 4 >= 4.1.0, PHP 5)

mssql_guid_string --  Converts a 16 byte binary GUID to a string

Description

string mssql_guid_string ( string binary [, int short_format] )

Внимание

К настоящему времени эта функция еще не была документирована; для ознакомления доступен только список аргументов.



mssql_guid_string
08-Jul-2005 08:52
php3 to php4 note

warning!
php4 handles MSSQL GUID like binaries values and not like a string as php3 used to do.
Even if you set  in your php.ini :
mssql.compatability_mode = On
jhorvath at bcn dot hu
19-Mar-2003 07:25
Using MSSQL2000 and PHP4.3.1 and FreeTDS-0.61 (always compile it with --enable-msdblib --with-tdsver=7.0 for proper working) this function won't give you the strings what you can see in MS's Enterprise Manager for uniqueidentifiers!
And the given strings also useless in SELECTs!
To get the number what you can reuse in later SELECTs, use this:

$q1 = mssql_query("SELECT cast(id as varchar(36)) FROM sales WHERE ...");

where in table 'sales' the column 'id' type is uniqueidentifier.

<mssql_get_last_messagemssql_init>
 Last updated: Tue, 15 Nov 2005