note 109582 added to function.mssql-guid-string
| From: | gonzalolarralde at gmail dot com | Date: | Mon, 30 Jul 2012 21:12:11 +0000 |
| Subject: | note 109582 added to function.mssql-guid-string | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-189517@lists.php.net to get a copy of this message | ||
Hi guys. Here is a simple implementation to fill the gap with FreeTDS:
$guid = unpack("h16a/H16b", $guid);
$guid =
strtoupper(strrev(substr($guid["a"],0,8)).strrev(substr($guid["a"],8,4)).strrev(substr($guid["a"],12,4)).$guid["b"]);
$guid = substr($guid, 0, 8) . "-" . substr($guid, 8, 4) . "-" . substr($guid,
12, 4) . "-" . substr($guid, 16, 4) . "-" . substr($guid, 20);
Cheers.
----
Server IP: 194.28.1.75
Probable Submitter: 181.31.1.63
----
Manual Page -- http://www.php.net/manual/en/function.mssql-guid-string.php
Edit -- https://master.php.net/note/edit/109582
Del: integrated -- https://master.php.net/note/delete/109582/integrated
Del: useless -- https://master.php.net/note/delete/109582/useless
Del: bad code -- https://master.php.net/note/delete/109582/bad+code
Del: spam -- https://master.php.net/note/delete/109582/spam
Del: non-english -- https://master.php.net/note/delete/109582/non-english
Del: in docs -- https://master.php.net/note/delete/109582/in+docs
Del: other reasons-- https://master.php.net/note/delete/109582
Reject -- https://master.php.net/note/reject/109582
Search -- https://master.php.net/manage/user-notes.php