ORDER BY problem
Hey Ray
Have got this recordset
<?php
$WADAvehicle_inspections = new WA_MySQLi_RS("WADAvehicle_inspections",$DBConnection,20);
$WADAvehicle_inspections->setQuery("SELECT * FROM vehicle_inspections ORDER BY VehiclesDate DESC");
$WADAvehicle_inspections->execute();
?>
<?php } else { ?>
<?php
$WADAvehicle_inspections = new WA_MySQLi_RS("WADAvehicle_inspections",$DBConnection,1);
$WADAvehicle_inspections->setQuery("SELECT * FROM vehicle_inspections WHERE VehiclesInspector = ? ORDER BY VehiclesDate DESC");
$WADAvehicle_inspections->bindParam("s", "".($_SESSION['UserLastName']) ."", "-1"); //colname
$WADAvehicle_inspections->execute();
?>
<?php } ?>
and this in a repeat block
<div class="coffee-span-2 resultsWrapper leftColumn"> <?php if(WA_Auth_RulePasses("Administrator")){ ?><a class="link-text resultsLinks dates timesheet" href="vehicleinspections_update.php?VehiclesID=<?php echo($WADAvehicle_inspections->getColumnVal('VehiclesID')); ?>
<?php echo(isset($_GET["pageNum_WADAvehicle_inspections"])?"&pageNum_WADAvehicle_inspections=".intval($_GET["pageNum_WADAvehicle_inspections"]):""); ?>"><?php echo(($WADAvehicle_inspections->getColumnVal('VehiclesDate'))?date('d M y',strtotime($WADAvehicle_inspections->getColumnVal('VehiclesDate'))):''); ?></a>
<?php } else { ?>
<?php echo(($WADAvehicle_inspections->getColumnVal('VehiclesDate'))?date('d M y',strtotime($WADAvehicle_inspections->getColumnVal('VehiclesDate'))):''); ?>
<?php } ?> </div>
it should be filtering/ordering by the date but as you can see by this screenshot its not http://prntscr.com/13g113t
Many thnaks
Jamie