Page 1 of 1

I can't get the stuff out right!

Posted: Thu Apr 08, 2004 1:36 pm
by magicrobotmonkey
Why does this:

Code: Select all

<?php $query1 = "SELECT carrier.Name, report.Act_Year
            FROM carrier, report
            WHERE carrier.NAIC = report.NAIC AND report.Sel_Year = 2004 AND report.Sel_Quarter = 1
            ORDER  BY report.Act_Year";
  $result1 = mysql_query($query1) or die ("Query failed: ". mysql_error());
  $carriers = mysql_fetch_array($result1);

var_dump($carriers);

?>
out put this:

array(4) { [0]=> string(28) " Stratford Insurance Company" ["Name"]=> string(28) " Stratford Insurance Company" [1]=> string(14) "20040406161410" ["Act_Year"]=> string(14) "20040406161410" }

Firstly, I know there are only three items in the DBase which will return when I run the same query from phpMyAdmin

Posted: Thu Apr 08, 2004 1:42 pm
by magicrobotmonkey
Woops i just figured it out - heh, never mind!