mattv10
05-24-2007, 10:49 AM
Hi everyone..
I have a strange issue that has been very confusing to me.. Currently I am looping through a list of servers, connecting to each server and executing a query that will return one value. This value is getting placed into an excel spreadsheet using XML.. So hopefully you can picture that.. Its just one big loop doing all this..
I started to have this issue where I was getting XML errors where it said I was missing an end tag.. I knew I was not missing an end tag because I checked the code over so many times.. So, I logged into each server and ran the query in SQL Server hoping I will narrow down the problem.. I notice that 5 of my "environments" are returning NULL as the recordset...
So I went to my code and added some logic to test for a NULL value in my recordset.. I still had the same issue.. (Missing the XML end tag) Now, to verify these nulls were causing the issue I wrote some logic to print nothing in the Excel cell if the server names = (the specific servers).. And it worked!!!
What I would like to know is how can I test for this a more generic way? I tried the following functions in PHP..
--isset
--is_null
--empty
Nothing seems to work.. Any Ideas?? Oh by the way I querying from Microsoft SQL Server 2000 using an ADO Connection..
Any insight would be appreciated.. If you need anymore information I will be happy to give it to you...
Thx!
I have a strange issue that has been very confusing to me.. Currently I am looping through a list of servers, connecting to each server and executing a query that will return one value. This value is getting placed into an excel spreadsheet using XML.. So hopefully you can picture that.. Its just one big loop doing all this..
I started to have this issue where I was getting XML errors where it said I was missing an end tag.. I knew I was not missing an end tag because I checked the code over so many times.. So, I logged into each server and ran the query in SQL Server hoping I will narrow down the problem.. I notice that 5 of my "environments" are returning NULL as the recordset...
So I went to my code and added some logic to test for a NULL value in my recordset.. I still had the same issue.. (Missing the XML end tag) Now, to verify these nulls were causing the issue I wrote some logic to print nothing in the Excel cell if the server names = (the specific servers).. And it worked!!!
What I would like to know is how can I test for this a more generic way? I tried the following functions in PHP..
--isset
--is_null
--empty
Nothing seems to work.. Any Ideas?? Oh by the way I querying from Microsoft SQL Server 2000 using an ADO Connection..
Any insight would be appreciated.. If you need anymore information I will be happy to give it to you...
Thx!