hi.
I can't figure out why other properties are found but this one is not.

the key:  strCreateAdminTable
Exception in thread "main" java.util.MissingResourceException: Can't find resource for bundle java.util.PropertyResourceBundle, key  strCreateAdminTable
        at java.util.ResourceBundle.getObject(ResourceBundle.java:384)
        at java.util.ResourceBundle.getString(ResourceBundle.java:344)
        at model.ModelUtils.getResource(ModelUtils.java:48)
        at model.dao.DerbyDAO.createTables(DerbyDAO.java:185)

can I build a table with this one? or is it just not finding the value of the key?

strCreateAdminTable=DROP TABLE IF EXISTS admin \
CREATE TABLE admin \
( \
admin_uid CHAR(11),\
admin_password CHAR(11),\
admin_lname CHAR(20),\
admin_mname CHAR(20),\
admin_fname CHAR(20),\
admin_gender CHAR(1),\
admin_age INT(2),\
admin_start_date DATE,\
admin_end_date DATE,\
admin_address CHAR(20),\
admin_state CHAR(2),\
admin_zip INT(5),\
admin_area_code INT(3),\
admin_phone INT(11),\
admin_pay_rate INT(4),\
PRIMARY KEY(admin_uid)\
)\
INSERT INTO admin (admin_uid,admin_fname,admin_password) VALUES ('ag','Garth','a') \
INSERT INTO admin (admin_uid,admin_fname,admin_password) VALUES ('aw','Wayne','a')

OUCHH! Why put queries in properties file? If you need the ability to change queries without changing code, consider keeping your queries inside an XML file and read them back or better yet, use a framework which actually does this and in a much better way i.e. iBatis.

OUCHH! Why put queries in properties file? If you need the ability to change queries without changing code, consider keeping your queries inside an XML file and read them back or better yet, use a framework which actually does this and in a much better way i.e. iBatis.

I plan on using xml but that is later because I have to learn how to do that asap.
thanks
-Steve

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.