BOTEN
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ') AND v.verhnr=rvt.verhnr AND bt.slaappl >= 0 AND bt.slaappl <= 99 ORDER BY ' at line 2SELECT DISTINCT typenaam, rvt.regionr as thisreg, bt.boottnr as thisBootId, slaappl, slaappl_ex, rvt.verhnr as thisVerhnr, v.maatschappij_id as thisMaId, ankers as thisAnkers FROM boottype bt, regioverhuurdertype rvt, verhuurder v WHERE rvt.boottnr= bt.boottnr AND rvt.regionr IN (1400) AND rvt.verhnr IN () AND v.verhnr=rvt.verhnr AND bt.slaappl >= 0 AND bt.slaappl <= 99 ORDER BY RAND()