Quantcast
Channel: Java Programming Forum - Learn Java Programming - Hibernate
Viewing all articles
Browse latest Browse all 76

How to let hibernate know where to look for configuration file

$
0
0
I just export my java project to executable jar. I have somehow made my project work to access value from DB (hibernate.cfg.xml), config.properties, and log4j.properties & editable for future...

I want to put hibernate.cf.xml, config.properties and log4j.properties in the outside of jar and place them somewhere in other directory (/mon/properties)...

when I run my jar
Code:

java -cp coreservice.jar:/mon/properties id.co.bni.coreservice.controller.CoreServiceController
but, I got this error
Code:

Could not find or load main class
any help will be pleasure :)

Viewing all articles
Browse latest Browse all 76

Latest Images

Trending Articles



Latest Images