 |
|
|
| View previous topic :: View next topic |
| Author |
Message |
darksniperx
Joined: 29 Jan 2009 Posts: 2
|
Posted: Thu Jan 29, 2009 5:54 pm Post subject: mssql query analyser returns results,while php doesnt return |
|
|
Hello,
I run the query(stored procedure) in mssql query analyser , everything works and I get an output. When I run the same code in php and I do print_r, I get an array that contains my query with no results. Maybe I need to turn on some features in pear mdb2 so that I could see the results from running a stored procedure.
| Code: |
$qry = $mdb2->query("SET ANSI_NULLS ON; EXEC GetItems @item='1', @page=2");
|
| Quote: | | I have pear mdb2 mssql 1.2.1 installed |
|
|
| Back to top |
|
 |
mark

Joined: 07 Jan 2007 Posts: 1230
|
|
| Back to top |
|
 |
darksniperx
Joined: 29 Jan 2009 Posts: 2
|
Posted: Thu Jan 29, 2009 11:39 pm Post subject: |
|
|
executeStoredProcedure() complains on "ON" when I run the following code:
| Code: |
$qry = $mdb2->func->query("SET ANSI_NULLS ON; EXEC GetItems", $input);
|
If I dont add "SET ANSI_NULLS ON"
| Code: |
$qry = $mdb2->func->query("GetItems", $input);
|
I get the following error:
| Code: |
[Native message: Heterogeneous queries require the ANSI_NULLS and ANSI_WARNINGS options to be set for the connection. This ensures consistent query semantics. Enable these options and then reissue your query.]
|
|
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|