php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Doc Bug #41887 Adding to mssql_execute documentation
Submitted: 2007-07-03 12:44 UTC Modified: 2007-08-16 13:12 UTC
From: mark dot vanrossum at bris dot ac dot uk Assigned:
Status: Not a bug Package: Documentation problem
PHP Version: Irrelevant OS:
Private report: No CVE-ID: None
 [2007-07-03 12:44 UTC] mark dot vanrossum at bris dot ac dot uk
Description:
------------
I was pulling my hair out getting the error:
  "stored procedure execution failed"
when trying to run mssql_execute but could run:
  $results = mssql_query('sp_test'); 
fine.

I was connecting using the string:
  $dbserver="xxx.xxx.xxx.xxx:1433";
  $cn = mssql_connect($dbserver, $dbuser, $dbpass);

where xxx is the IP address.

It seems that this doesn't work, you need to do the following:
edit your freetds.conf file and add the connection in here, eg:
[YourServer]
        host =xxx.xxx.xxx.xxx
        port = 1433
        tds version = 8.0

Then try and connect as:
$cn = mssql_connect('YourServer', $dbuser, $dbpass);

This could be made clearer in the docs.  I've added this as a note as well.  There are a couple of bug reported about this, which if the docs were clearer wouldn't get reported hopefully.


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2007-08-16 13:12 UTC] vrana@php.net
It is probably caused by bug #42046.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Apr 19 13:01:30 2024 UTC