I have a web page that i made that uses a mysql(4.0) server which is at another location. Everything was working fine, but I have to use a database on one of the servers here at work. (3.23).
The database name, password, and username are the exactly the same as they were on the other server, (so, theoretically i should be able to just change the hostname in the script and all should be well).... its not...
here is the relevent piece of code from the script.
Code:
### GET THE MASTERRECORD FROM THE INPUT DATA
$www{'licnum'} = 0 if !$www{'licnum'};
$sql = qq{
select FIRSTNAM,LASTNAME,(CURDATE()+1-1) as Today, MASTREC
from CLIENT where LICENSEN = "$www{'licnum'}" and BIRTH = "$dob"; };
print "<!--\n##############\n$sql\n############## -->";
$sth=$dbh->query($sql);
print "<!-- after query -->";
%data=$sth->fetchhash();
print "<!-- after fetch -->";
if (!%data) {...
keep in mind that the ONLY thing i changed in the script was the hostname..
The page works fine when connecting to the 4.0 server.
When connecting to the 3.23 server it dosn't display the whole web page.
I added the comments above to see where the problem occurs. when looking at the html source for the output of the script, it gets to "after query" and then stops, which leads me to believe that the fetchhash part failed?
in lost here.
note: if i connect to the 3.23 mysql server from a command line and run the sql query it works perfectly.