I am trying to call a stored procedure written in MS SQL SERVER 2008 from PHP ODBC through following code, but it does not seem to work:
$statement = odbc_prepare ( $con, "CALL take_snapshot(?)");
if ($statement !== FALSE) {
if (odbc_execute ( $statement, 2010) !== FALSE) {
return true;
}
}
In SQL server management studio I simply execute it by writing: exec take_snapshot 2010 in query window and it works fine.
Can anyone guide me with correct syntax of call a procedure from PHP ODBC.