RE: [PHP-DB] Query problem with MS SQL on NT4

From: Date: Fri, 24 Nov 2000 11:57:31 +0000
Subject: RE: [PHP-DB] Query problem with MS SQL on NT4
Groups: php.db 
Request: Send a blank email to php-db+get-4715@lists.php.net to get a copy of this message
If it works in query analyzier it should work from php. mssql_query takes 2 arguments? Try something like the following to give you more of an idea what's going wrong $sql_result = mssql_query($sql, $connection) or die ("Error in ".__FILE__." at line ".__LINE__." with error ".mssql_get_last_message()."\n$sql"); Sub queries work execute fine but can cause other problems. When the page is displayed the progress bar keeps going (PHP is running as cgi and the process keeps running). Nick -----Original Message----- From: Joe Linger [mailto:jlinger@delphi.com] Sent: 24 November 2000 05:22 To: ML-PHP-DB Subject: [PHP-DB] Query problem with MS SQL on NT4 The following query is successful in MS SQL query analyzier, but fails in php code. $maxSel = "Select * from piclist where UID = (select max(UID) from piclist)"; $rs2 = mssql_query($maxSel); Can anyone shed some light on this? Thanks. Joe Linger -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: php-db-unsubscribe@lists.php.net For additional commands, e-mail: php-db-help@lists.php.net To contact the list administrators, e-mail: php-list-admin@lists.php.net

« previous php.db (#4715) next »