3 Replies Latest reply on Oct 13, 2007 4:52 AM by maxandersen

    Problem about specifying a jndi source for eclipse hibernate

    haoniukun

      Dear all,
      I've just used create a project with eclipse with hibernate support.
      After adding a console configuration, I fail to run hibernate code generation with the following error:

      [FATAL] DatasourceConnectionProvider - Could not find datasource: java:/comp/env/jdbc/xxxx <javax.naming.NoInitialContextException: Need to specify class name in environment or system property
      , or as an applet parameter, or in an application resource file: java.naming.factory.initial>javax.naming.NoInitialContextException: Need to specify class name in environment or system property
      , or as an applet parameter, or in an application resource file: java.naming.factory.initial
      

      I'm sure that my jndi name is correct since the program works fine with tomcat.
      I just want hibernate plugin generate hbm file for me.
      So how can I specify an initial context for console configuration?

      Any help would be appreciated and thanks in advance.