|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2005-11-18 20:41 UTC] tony2001@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Mon Nov 03 18:00:01 2025 UTC |
Description: ------------ I tried to select data from an SQL2005 table witch contains the new SQL2005 datatype XML.I got no data, but an warning. Reproduce code: --------------- CREATE TABLE XMLDaten ( XDA_Titel varchar(30) NOT NULL, XDA_XML xml ) ------------------------------------------------ $con = new PDO('mssql:host=Server;initial catalog=Adressen','pschmidt','password'); foreach($con->query('SELECT * FROM dbo.XMLDaten') AS $Zeile) { echo '<br>'; var_dump($Zeile); } Expected result: ---------------- Data Actual result: -------------- Warning: Invalid argument supplied for foreach() in c:\Inetpub\wwwroot\sql2005.php on line 6