This week's book giveaway is in the Design forum.
We're giving away four copies of Design for the Mind and have Victor S. Yocco on-line!
See this thread for details.
Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

how to use new Data(dbName) to open db.db in jar?

 
Vince Zhang
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In local mode, if I put db.db in jar(/suncertify/db/db.db), then call new Data(String dbName) to create an instance of Data, what dbName should I input?
Thanks
 
Matt Ghiold
Ranch Hand
Posts: 213
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You can't open a file inside of a jar file.
You need to have your db file live outside of your jar file.
*hint* I believe sun allows a command line parameter of the db file location
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic