facebook

Error-Loading suitable driver

  1. MyEclipse IDE
  2.  > 
  3. Off Topic
Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #291786 Reply

    muddu_shafi
    Member

    Hi,

    I have a Maven Eclipse project unable to connect to the Progress database.
    Project Descrption:-

    I have database properties written in a file in the C: directory as database.properties.

    I habe added progress.jar file and jdbc.jar to the project build path. It seems there is procli.dll file which is also essential. But I dont know how to load it, the IDE displays error saying unable to locate the procli file.

    Can anyone explain me where to load the jar file and run my program?

    A snapshot of database properties.

    qad.proxy.db.driver=com.progress.sql.jdbc.JdbcProgressDriver
    qad.proxy.db.url=jdbc:JdbcProgress:T:qad1.atcc.org:16600:prodproxy
    qad.proxy.db.user=xxxxxx
    qad.proxy.db.password=xxxxx
    
    
    private Connection connectToDatabase(String name) throws ErpProxyDaoException, SQLException{
            String driver = null;
            String url = null;
            String userName = null;
            String password = null;
            
        try{
        Properties inProps = new Properties();
        if (in == null) {
        throw new IOException("C:\\database.properties" + " unable to read");
        } else {
            inProps.load(in);
            driver = inProps.getProperty("qad." + name + ".db.driver");
            url = inProps.getProperty("qad." + name + ".db.url");
            userName = inProps.getProperty("qad." + name + ".db.user");
        password = inProps.getProperty("qad." + name + ".db.password");
        ErpProxyMockDao.logger.info("url = " + url + " username = " + userName + " for db " + name);
        }
        logger.info("before loading the driver: " + driver);
        logger.info("the database I'm connecting to is : " + url);
        Class.forName(driver);
        logger.info("after loading the driver: " + driver);
          Connection connection = DriverManager.getConnection(url, userName, password);
        ErpProxyMockDao.logger.fine("Got connection ..." + connection);
        return connection;
        } catch (ClassNotFoundException e) {
        throw new ErpProxyDaoException("Error loading driver ", e);
        } catch (IOException e) {
        throw new ErpProxyDaoException("C:\\database.properties" + " unable to read");
        }
        }
    #291797 Reply

    Loyal Water
    Member

    Moving to Off Topic >> Software Development.

Viewing 2 posts - 1 through 2 (of 2 total)
Reply To: Error-Loading suitable driver

You must be logged in to post in the forum log in