Page 1 of 1

Need your help please got problems with MSSQL

Posted: Tue Oct 01, 2002 2:00 am
by Patrick Braun
Hi,
i got the following problem, i coded a small database programm in Mysql who can the user insert some infos over a intranetsite.. so long.. its done.. but the problem is, in mysql it woks all fine.. but now i want to use this programm on MS SQL ..ok not a problem.. i changed some definitions and now the code is
<?php

require("config.php");
#echo $sqlst;
$connect = mssql_connect($dbhost, $dbuser, $dbpass);
if(!$connect)
{
print "SORRY, db down...<br>";
die();
} else {
mssql_select_db("$dbname",$connect);
}


echo $sqlst = "INSERT INTO domain (domainID, name, description, server, responsibleID, port) VALUES ('$domainID', '$name', '$description', '$server', '$responsibleID', '$port')";
echo $eintrag = mssql_query($sqlst, $connect);
if(!$eintrag)
{
print "<p>db not working!";
} else {
print "<p>Done accpeted querry!";
}

?>

so this is the code i cant find a failure, the problem is he makes the row in the database but its empty.. so is the rows ans cells empty but created.. if i put some data manually in the DB with MS enterprise manager and wanna see it works .. pls help me is anyting false with my code??
thx regards
Patrick B

Posted: Fri Nov 08, 2002 2:50 am
by volka
but your echo-output looks fine?