i'm using javadb(netbeans) for a project and I am a total beginner.
I have a small app which searches an address database and brings back a data grid of results.
The users tpyes in all, or part of a street name into a jtextfield, hits a search button and the records are then filtered in a data grid.
I am writing simple sql queries which are working fine but I am struggling to indicate the where clause must be the jtextfield text. For example, what I need to do is the following:
SELECT * FROM tbl_addresses WHERE Street_Name = jTextfield.getstring()
but obviously that doesn't work.
Can anybody help?? Please??
I have a small app which searches an address database and brings back a data grid of results.
The users tpyes in all, or part of a street name into a jtextfield, hits a search button and the records are then filtered in a data grid.
I am writing simple sql queries which are working fine but I am struggling to indicate the where clause must be the jtextfield text. For example, what I need to do is the following:
SELECT * FROM tbl_addresses WHERE Street_Name = jTextfield.getstring()
but obviously that doesn't work.
Can anybody help?? Please??