zleviticus
-
Posts
6 -
Joined
-
Last visited
Never
Posts posted by zleviticus
-
-
Wow the issue was a combination of permission and weirdness. When i tried to connect using the instance name and port it would connect to the default instance of sql 2000 on the server. When i got rid fo the port # it connected up to the correct instance. That was AFTER i did some permission changes and such.
-
Ok more info.. I think i foudn what is going on but trying to figure out how to fix. It looks like the code is only looking at the default server instance and not the named. i connected to the database and ran a select on the master.dbo.sysdatabases through the code and it is showing DBs from the default instance. So we are getting closer.
-
I am having an issue with php and my 2005 sql server. When i connect to the database via visual basic through an excel macro i can connect just fine and do whatever i want to get the data i need. When i try to connect using php code i am getting the "Could not locate entry in sysdatabases for database 'mydb'/ No entry found with that name.
I have tried connecting using windows autentication and SQL. Same issue. I did have to replace a dlll for php because of a known issue with mssql and php 5. I am also connecting using the port address of the server in the sql_connect. Also the server is an named instance and not the default instance. I am at a loss as to what is causing the issue. The same code worked on a sql 2000 server with php 5. This 2000 sql is on the same server as the 2005 in another instance.
Here is what i am using to connect to the server:
$server = "192.168.1.9\\instance,1433"; $username = "someuser"; $password = "somepassword"; $sqlconnect = mssql_connect($server, $username, $password) or DIE("Can't Connect to server."); $sqldb = mssql_select_db('MyDB', $sqlconnect);
oh on a side note when i run a sp_helpdb against master i can see the DB i am trying to connect to listed.
-
Oh and it has the latest SP for sql as well.
-
Ok this is a weird issue and has me perplexed....I have search the forums but can not find anything related. maybe i can't search right....
Running a windows 2003 server with sp2
mssql 2000
php 5.2.1
The mssql server is on a different machine than the iis 6 server and php5.
I am connecting to the mssql using the basic msconnect function via ip address. When i try to run the php via IE it give a can't connect to server error.
The script was working prior to the installation of sp 2. Uninstalling sp2 is not a viable option. If i run the script in my editing program from my workstation it works and connects to the server fine. If i run the script from the iis server it fails.
Thanks for any insight you can give on this issue.
Z
Multiple database question.
in Microsoft SQL - MSSQL
Posted
why different databases? Why not one DB and query that one database based upon you conditions?