hello...
i m working in php and trying to connect with SQL Server database.but its creating problem
my syntax is ....
$con1 = mssql_connect("dbase","sa","");
mssql_select_db("exams",$con1)or die("Couldn't connect to SQL Server on myServer");
dbase: is my host name..
exams: is my dbname
what else should i do with that....please reply me as sooon as possible i will be very thankful.
regards,,
honey
Connecting Problem with sql Server
Moderator: General Moderators
-
me_not_4_php
- Forum Newbie
- Posts: 2
- Joined: Tue Nov 03, 2009 11:36 pm
- novice4eva
- Forum Contributor
- Posts: 327
- Joined: Thu Mar 29, 2007 3:48 am
- Location: Nepal
Re: Connecting Problem with sql Server
first start with enabling error reporting, this is done with these two little but very helpful codes
You should get some error/warnings printed that will give you hints of what could have gone wrong.
Code: Select all
//PLACE THEM ON TOP OF UR CODE
ini_set('display_errors', 1);
ini_set('error_reporting', E_ALL);