Jump to content

gunlomboy

New Members
  • Posts

    2
  • Joined

  • Last visited

    Never

Everything posted by gunlomboy

  1. Just discovered that all my queries work fine if I connect to the Northwind database ie. I don't have to put the database name in the query .... BUT .... my database still requires the db_name in there. Any help would be appreciated. Tks
  2. Hi, We are running a now quite outdated PHP installation (4.3.0) on W2K with MSSql. The PHP is working fine and I can connect to the sql server without any problems. However, I can only successfully run queries if I use the database name in the query. Eg. SELECT * FROM person ..... fails with this message: Warning: mssql_query() [function.mssql-query]: message: Invalid object name 'person'. (severity 16) BUT .... if the query is SELECT * FROM database_name.person ..... it's works fine I am using mssql_select_db('database_name') immediately after I connect, but it doesn't seem to do anything. ----------------------------- $conn = mssql_pconnect($sqlserver , $sqluser , $sqlpass); mssql_select_db($database); $result = mssql_query("SELECT * FROM person", $conn); ------------------------------ Any ideas? Thanks Jon.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.