Topic
4 replies Latest Post - ‏2013-08-26T22:13:40Z by markevans
giocot
giocot
65 Posts
ACCEPTED ANSWER

Pinned topic EGL0505E Impossible connect to jdbc/srv03

‏2013-08-21T21:52:03Z |

Hi

i have a RUI handler project that in the preview view run correctly and shows data from databse; now i have tryed to deploy and run the same project in Tomcat server but don't works and i receive the following error:

" EGL0505E:EGL0505E  Impossible  connect to jdbc/srv03: Name jdbc is not bound in this Context
EGL0002I error is occurred in qcustcdt during the elaboration of the function getAllQCustCd
t."

which could be the problem ?

thanks in advance

  • giocot
    giocot
    65 Posts
    ACCEPTED ANSWER

    Re: EGL0505E Impossible connect to jdbc/srv03

    ‏2013-08-21T22:23:55Z  in response to giocot

    Hi

    console in debug mode i see also "Cannot load JDBC driver class 'com.ibm.as400.access.AS400JDBCDriver'"

    message complete:

    EGL0505E:EGL0505E Impossible  connect to jdbc/srv03: Cannot load JDBC driver class 'com.ibm.as400.access.AS400JDBCDriver'
    EGL0002I error is occurred in qcustcdt during the elaboration of the function getAllQCustCdt."

     

     

    • markevans
      markevans
      2611 Posts
      ACCEPTED ANSWER

      Re: EGL0505E Impossible connect to jdbc/srv03

      ‏2013-08-21T22:49:12Z  in response to giocot

      Hi,

      The problem is that preview uses info in the EGL Debug build descriptor and looks for classes in the project Java Build Path.

      Once deployed, the datasource has to be defined to Tomcat (in context.xml) and the jt400.jar has to be placed in the lib folder of the Tomcat installation.

      I believe if you select the web project and open its properties, there is an option called EGL Runtime Data Source.  If you use the existing connection to the database (assuming you have one defined), then I think it add the proper information to the context.xml.

      See this link for a tutorial that goes through the steps for a derby database, but the concepts are the same.

      the context.xml is in the Tomcat install->Conf folder.

  • giocot
    giocot
    65 Posts
    ACCEPTED ANSWER

    Re: EGL0505E Impossible connect to jdbc/srv03

    ‏2013-08-22T09:10:08Z  in response to giocot

    Hi mark

    now it's working ....  (wow !!!)

    here what i have done:

    1- placed jt400.jar in Tomcat lib Folder

    2- pasted in Tomcat/conf context.xml  file the <Resource  /> record from myProject/Metainf context.xml file 

    Question:

    in the myProject/Metainf context.xml file there is User name and  password !!!!!!   in clear.  I think is not very correct !!! is there a way to avoid this ?

    Thanks again

     

     

     

     

    • markevans
      markevans
      2611 Posts
      ACCEPTED ANSWER

      Re: EGL0505E Impossible connect to jdbc/srv03

      ‏2013-08-26T22:13:40Z  in response to giocot

      Hi,

      I think the only way to avoid the setting of the password here is to use the egl function named sqllib.connect( ).  You can specify the jndi name, userid, and password on this. 

      It will have to be issued each time you enter a service that needs access.