Here is the SQL Statment I am trying to execute. This statement runs fine in Access.
SELECT load.date, load.waybillnum, route.start, route.end, load.hrlyhauls, load.correctedvolume, load.addwork, route.riser, load.comments, driver.fname, driver.lname, load.wage, load.driverindex, (select unit from equipment where load.truckkey = equipment.equipkey) AS TruckUnit, (select unit from equipment where load.Trailer1Key = equipment.equipkey) AS TrailerUnit1, (select unit from equipment where load.Trailer2Key = equipment.equipkey) AS TrailerUnit2, route.rate, (route.rate*load.correctedvolume) AS RatedTotal, load.hourlyrate, (load.hourlyrate*load.addwork*load.hrlyhauls) as HourlyTotal, (HourlyTotal + RatedTotal) as HaulTotal FROM Route INNER JOIN (Driver INNER JOIN Load ON Driver.DriverKey=Load.DriverIndex) ON Route.RouteKey=Load.RouteIndex ORDER by load.date
Any ideas?
SELECT load.date, load.waybillnum, route.start, route.end, load.hrlyhauls, load.correctedvolume, load.addwork, route.riser, load.comments, driver.fname, driver.lname, load.wage, load.driverindex, (select unit from equipment where load.truckkey = equipment.equipkey) AS TruckUnit, (select unit from equipment where load.Trailer1Key = equipment.equipkey) AS TrailerUnit1, (select unit from equipment where load.Trailer2Key = equipment.equipkey) AS TrailerUnit2, route.rate, (route.rate*load.correctedvolume) AS RatedTotal, load.hourlyrate, (load.hourlyrate*load.addwork*load.hrlyhauls) as HourlyTotal, (HourlyTotal + RatedTotal) as HaulTotal FROM Route INNER JOIN (Driver INNER JOIN Load ON Driver.DriverKey=Load.DriverIndex) ON Route.RouteKey=Load.RouteIndex ORDER by load.date
Any ideas?