D
dave h
Hi,
Can anyone tell me why this sql returns an error of "too few parameters.
Expected 1"
mySQL = "SELECT rd.reservedetailID, rd.inventoryID, inv.copynumber,
lfr.loanDetailID"
mySQL = mySQL & " FROM reservedetail_215 as rd, libraryInventory_33 as
inv "
mySQL = mySQL & " WHERE rd.inventoryID = inv.inventoryID "
mySQL = mySQL & " AND rd.reservedetailID = 42 "
mySQL = mySQL & " AND lfr.loandetailID IN (SELECT loandetailID FROM
loanForReserve_37 as lfr"
mySQL = mySQL & " WHERE lfr.reservedetailID = rd.reservedetailID)"
There are 3 tables involved. Matching the libraryInventory table to the
reserveDetail table for ID 42 is no problem. My goal is to effect an outer
join with the subquery. If a loanForReserve row does exist for ID 42, then
I need the loanDetailID field, otherwise I need that field to be blank or
zero. Right now I'm simply stuck with this syntax error.
Can anyone tell me why this sql returns an error of "too few parameters.
Expected 1"
mySQL = "SELECT rd.reservedetailID, rd.inventoryID, inv.copynumber,
lfr.loanDetailID"
mySQL = mySQL & " FROM reservedetail_215 as rd, libraryInventory_33 as
inv "
mySQL = mySQL & " WHERE rd.inventoryID = inv.inventoryID "
mySQL = mySQL & " AND rd.reservedetailID = 42 "
mySQL = mySQL & " AND lfr.loandetailID IN (SELECT loandetailID FROM
loanForReserve_37 as lfr"
mySQL = mySQL & " WHERE lfr.reservedetailID = rd.reservedetailID)"
There are 3 tables involved. Matching the libraryInventory table to the
reserveDetail table for ID 42 is no problem. My goal is to effect an outer
join with the subquery. If a loanForReserve row does exist for ID 42, then
I need the loanDetailID field, otherwise I need that field to be blank or
zero. Right now I'm simply stuck with this syntax error.