Skip to Content.
Sympa Menu

freetds - Trapping mssql raiserror statements in PHP4 via FreeTDS

freetds AT lists.ibiblio.org

Subject: FreeTDS Development Group

List archive

Chronological Thread  
  • From: "Mark Gruetzner" <mgruetzner AT rw3.com>
  • To: freetds AT franklin.oit.unc.edu
  • Subject: Trapping mssql raiserror statements in PHP4 via FreeTDS
  • Date: Wed, 8 May 2002 11:10:21 -0400


I've successfully installed and have been using FreeTDS 0.53 with Apache
1.3.23 and PHP 4.1.2 to port over a data-driven web site that uses MS SQL
Server 7.0. Everything seems to work EXCEPT, I cannot seem to get error
messages back from MS SQl stored procedures that call the RAISERROR
function. As long as you turn on track_errors in the php.ini file, you
should be able to call mssql_get_last_message after calling mssql_query
(to execute the stored procedure which calls RAISEROR('QueryLimit',9,1))
and mssql_get_last_message should return the string 'QueryLimit' but it is
not. Any ideas before I dig into the source code?




Archive powered by MHonArc 2.6.24.

Top of Page