Time : 15:21:49 SQLSTATE[42S22]: Column not found: 1054 Unknown column 'p.PARTYID' in 'field list' Raw SQL : select MAGZINEEDITIONS,ADVERTISEMENTBOOKINGID,ORDERNO,PARTY,NAME,cityname,PAGENO,DUMMYPAGENO,TARRIF,PAGESIZE,ISPAGEFIX,REMARKS,SUBORDERSID,POSITION from advertisementbooking,suborders,(select p.PARTYID,p.NAME,csc.NAME as cityname from partydetail inner join contact co on co.PARTY=p.PARTYID inner join countrystatecity csc on csc.COUNTRYSTATECITYID=co.city) as aspartydetail where advertisementbooking.ADVERTISEMENTBOOKINGID=suborders.ADVERTISEBOOKINGID and advertisementbooking.PARTY=aspartydetail.PARTYID and (ISCANCEL=0 || ISCANCEL IS NULL) Time : 15:21:16 SQLSTATE[42000]: Syntax error or access violation: 1064 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 'koi contact co on co.PARTY=p.PARTYID inner join countrystatecity csc on csc.COUN' at line 1 Raw SQL : select MAGZINEEDITIONS,ADVERTISEMENTBOOKINGID,ORDERNO,PARTY,NAME,cityname,PAGENO,DUMMYPAGENO,TARRIF,PAGESIZE,ISPAGEFIX,REMARKS,SUBORDERSID,POSITION from advertisementbooking,suborders,(select p.PARTYID,p.NAME,csc.NAME as cityname from partydetail inner koi contact co on co.PARTY=p.PARTYID inner join countrystatecity csc on csc.COUNTRYSTATECITYID=co.city) as aspartydetail where advertisementbooking.ADVERTISEMENTBOOKINGID=suborders.ADVERTISEBOOKINGID and advertisementbooking.PARTY=aspartydetail.PARTYID and (ISCANCEL=0 || ISCANCEL IS NULL) Time : 13:04:16 SQLSTATE[42000]: Syntax error or access violation: 1064 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 '' at line 1 Raw SQL : select ipaddress from p_customers where customerid= Time : 04:31:46 SQLSTATE[42000]: Syntax error or access violation: 1064 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 '' at line 1 Raw SQL : select ipaddress from p_customers where customerid=