shirophedra Posted June 25, 2020 Share Posted June 25, 2020 Help! I always have this erro message whenever i want to view my report ftom java gui "net.sf.jasperreports.engine.jrexception error executing sql statement for null". I can preview the report without any problem, just whenever i try to click a button form the java gui, the same error message always pop up. Is there any problem with my SQL? Where is the null? I'm really frustrated because of this.SELECT brgkeluar_kmf.`tanggal` AS brgkeluar_kmf_tanggal, brgkeluar_kmf.`kode` AS brgkeluar_kmf_kode, brgkeluar_kmf.`nama` AS brgkeluar_kmf_nama, brgkeluar_kmf.`satuan` AS brgkeluar_kmf_satuan, brgkeluar_kmf.`kategori` AS brgkeluar_kmf_kategori, brgkeluar_kmf.`departemen` AS brgkeluar_kmf_departemen, brgkeluar_kmf.`blok` AS brgkeluar_kmf_blok, brgkeluar_kmf.`estate` AS brgkeluar_kmf_estate, brgkeluar_kmf.`jumlah` AS brgkeluar_kmf_jumlah, brgkeluar_kmf.`harga` AS brgkeluar_kmf_hargaFROM `brgkeluar_kmf` brgkeluar_kmfWHERE tanggal BETWEEN $P{nomorAwal} AND $P{nomorAkhir}[/code] Link to comment Share on other sites More sharing options...
jgust Posted June 25, 2020 Share Posted June 25, 2020 This stackoverflow answer says the issue is with the different datatype between the parameter and the database:https://stackoverflow.com/questions/14950970/jasper-reports-error-executing-sql-statement-for Link to comment Share on other sites More sharing options...
shirophedra Posted June 25, 2020 Author Share Posted June 25, 2020 I set the datatype to varchar and the parameter is text. I think they should have the same datatype. And the error is the same. net.sf.jasperreports.engine.jrexception error executing sql statement for null. I dont know what is the null mean here. Link to comment Share on other sites More sharing options...
jgust Posted June 25, 2020 Share Posted June 25, 2020 The only other thing that looks odd to me is the accented quote characters around each field. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now