Time : 09:12:06 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 's Enterpries' and ADD1='5,'' at line 1 Raw SQL : select PARTYID from partydetail,contact where PARTYID=PARTY and CITY=1324 and NAME='Neelam's Enterpries' and ADD1='5,' Time : 08:56:54 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 's Enterprises' and ADD1='5, B.N. Road,'' at line 1 Raw SQL : select PARTYID from partydetail,contact where PARTYID=PARTY and CITY=1324 and NAME='Neelam's Enterprises' and ADD1='5, B.N. Road,' Time : 08:53:56 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 's Enterpries' and ADD1='5,'' at line 1 Raw SQL : select PARTYID from partydetail,contact where PARTYID=PARTY and CITY=1324 and NAME='Neelam's Enterpries' and ADD1='5,' Time : 08:44:59 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 '{info.ACCOUNTVOUCHERTYPEID}} and mt.MASTERTRANSACTIONID={{info.MASTERTRANSACTION' at line 4 Raw SQL : select mt.REFERENCENO,mt.NARRATIONS,mt.AUTOVOUCHERNO,al.NAME,al.ISITPARTY,t.MASTERDRCR,t.TRANSACTIONID,mt.TRANSACTIONDATE,t.subamount,t.INSTRUMENTDATE,t.REFERENCENO as instno,t.NARRATIONS as transnarration from mastertransaction mt inner join transaction t on mt.MASTERTRANSACTIONID=t.MASTERTRANSACTIONID inner join accountledger al on al.ACCOUNTLEDGERID=t.ACCOUNTLEDGERID where ACCOUNTVOUCHERTYPEID={{info.ACCOUNTVOUCHERTYPEID}} and mt.MASTERTRANSACTIONID={{info.MASTERTRANSACTIONID}}