Access to the jdbc connection list

Hi, I'm devolping a plugin for the Sap Developer Studio, It's a wizard that generate the EJB code from a database table. Any body knows how to access to the list of JDBC resources (defined in Visual Administrator) vía java code?, is there any way to make a new entry by code?
Thanks

Check out the author page for Venkatesh, there are few blogs written by him on retriving app server resources list / modifying them. May be you will get hint regarding how to go about your req.
/people/venkatesh.ramachandran/blog

Similar Messages

  • (nQSError:10018) Access for the requested connection is refused

    Hi Techies,
    Good Afternoon!!!
    Recently I faced a problem when I tried to view the data of my table in PHYSICAL LAYER
    (nQSError:10018) Access for the requested connection is refused
    (nQSError: 43037) Invalid Catalog, SupplierSales, specified.
    I did check my config file, every thing is proper. Even in NQSERVER log file it is showing that Finished Loading with out error.
    Same with the case of Answers. When I tried to login with administrator, it is throwing the same error as in RPD.
    I am unable to figure out the problem.

    Check you System DSN , ODBC > System DSN > AnalyticsWeb
    Make sure you have NOT enabled the "Change default repository to" or "Change default catalog to" as SupplierSales in either.
    Hope this helps.
    Thanks,
    -VS

  • LDAP : Access for the requested connection is refused.

    Hi
    After successfully connected to ldap server through OBI rpd , I imported the users and created init. blocs and variables.
    But when logging into dashborad/Answers i am getting the following error :
    Error Codes: OPR4ONWY:U9IM8TAC
    State: 08004. Code: 10018. [NQODBC] [SQL_STATE: 08004] [nQSError: 10018] Access for the requested connection is refused. [nQSError: 13024] Successful completion of init block 'oidAuthentication' is required. (08004).
    Pls. help.

    RPD users got preference over LDAP users i.e if you have a user with same name in RPD and LDAP, then RPD authentication will take place and not the LDAP authentication.
    Now if you are importing all the users from LDAP to RPD, then LDAP authentication will not take place and creating INIT block for the same will through an error when trying to login to Presentation services (if Required for Authentiaction is checked).
    Workaround
    You can create groups in your LDAP and assign all your users to these groups.
    Import groups to RPD and do group level authorization.
    Do not import users to RPD and create INIT block for LDAP authentication.
    Refer Oracle® Business Intelligence Server Administration Guide- 15# Security in Oracle BI for more details.

  • Advanced Queue - using the JDBC connection

    Advanced Queue using the JDBC connection gives us AN ERROR WHEN SENDING 32K QUEUES
    Is it true that RAW datatypes using the Java AQ API do indeed have a limit of 32K in 8.1.6.
    The workaround is to use the Java AQ API with Object payloads (BLOBs) to get around the problem.
    Has anyone used any other solution ?
    Thanks
    null

    There's a JDBC forum that's probably more germane to this question-- I'd suggest reposting it there.
    Justin Cave
    ODBC Development

  • Lot of cursors hanging even the jdbc connection are closed

    We use tomcat and thin oracle driver for out application. But we found lot of cursors hanging even the jdbc connection are closed.
    We use a connection pool to manage the connections.

    after properly closing the connections ,try to set all the Connection objects and ResulSet objects to null (force to null) , most likely these inactive sessions will dissapear.
    might be a java garbage collection issue?
    anyhow. I managed to get most of these inactive sessions to disappear. although I am using a Servlet. some of them are still not closed
    Regards

  • Deployed application can't see the JDBC connection

    Hi
    I made an ADF application using oracle JDeveloper 11g and it ran successfully from the JDeveloper
    I deployed it to Weblogic 10.3 and it successfully deployed
    But when i Opened the deployed application's URL the page's lay out is only what i c (only the template) with the following error:
    =================================================
    Error while opening JDBC connection.
    ORA-01005: null password given; logon denied
    Unexpected exception caught: java.lang.NullPointerException, msg=null
    =================================================
    SO, how could I make my application c the JDBC ?
    by the way when i created the DB connection in the JDeveloper i checked(deploy password)

    Hi Eddy
    I got the same problemas you posted.now i changed the configurations of AMlocal.i changed from JDBC URL to JDBC datasource.
    i saved the changes. i created a new EAR and deployed to external WLS 10.3 from Jdev11.1.1
    when i am testing tha app from external WLS,i am getting the following error
    JNDI failure.unable to lookup DataSource at context
    java:comp/env/jdbc/Connection1DS
    while trying to lookup'jdbc.Connectiobb1DS' didn't find
    subcontext 'jdbc'.Resolved"
    Unexpected exception caught:
    java.lang.NullpointerException,msg=null
    Can you tell me where the problem is?

  • Tomcat - Automatically Setting up the JDBC connection on deployment

    I got sick of setting up the JDBC source in Tomcat after deploying, this is how I overcame it.
    1. Create a directory:
    {project}/src/web/META-INF
    2. Create a file there
    {project}/src/web/META-INF/context.xml
    Heres is the contents of context.xml
    <?xml version='1.0' encoding='utf-8'?>
    <Context docBase="/root/jakarta-tomcat/webapps/toll" path="/toll" workDir="work/Catalina/localhost/toll">
      <Resource auth="Container" description="Rave generated DataSource Reference" name="jdbc/transact" type="javax.sql.DataSource"/>
      <ResourceParams name="jdbc/transact">
        <parameter>
          <name>maxWait</name>
          <value>5000</value>
        </parameter>
        <parameter>
          <name>maxActive</name>
          <value>200</value>
        </parameter>
        <parameter>
          <name>password</name>
          <value>dummypass</value>
        </parameter>
        <parameter>
          <name>url</name>
          <value>jdbc:mysql://localhost:3306/transact?autoReconnect=true</value>
        </parameter>
        <parameter>
          <name>driverClassName</name>
          <value>com.mysql.jdbc.Driver</value>
        </parameter>
        <parameter>
          <name>maxIdle</name>
          <value>50</value>
        </parameter>
        <parameter>
          <name>username</name>
          <value>dummyuser</value>
        </parameter>
      </ResourceParams>
    </Context>Hope this helps someone.
    Regards
    Jonathan

    Also add this in there for Tomcat .. we are using Tomcat 5 so check for other versions.
       <parameter>
          <name>removeAbandoned</name>
          <value>true</value>
        </parameter>
        <parameter>
          <name>removeAbandonedTimeout</name>
          <value>1200</value>
        </parameter>It turns on Tomcats connection recovery, so if your application has a connection leak and doesn't shut them all down. Tomcat will shut down unused connections, it uses the timeout value to determine which are unused. (1200 secs - 20 mins)
    Regards
    Jonathan

  • How to increase the JDBC connections peroformacnce

    Hi Iam new to Weblogic admin
    We are using weblogic 10. in solaries + oracle database env
    We are facing the slowness issue for internet application users, after submitting the user name and password, user will not get any response from the application except blank page,
    I have observed that there are somany; more than 200 Waiting For Connection Total. This will increase in peak time.
    wii this is the cause for the issue or if any other.
    Please suggest us to resolve the issue.
    Edited by: user11103866 on May 8, 2009 2:12 AM

    more than 200 Waiting For Connection Total.<<This is from a JDBC pool? If so, then you have more users than your pool can handle.
    How many initial / maximum connections does this particular pool allow, and how many servers are within your cluster?
    What is your applicaiton's session timeout value?
    Ask your DBA how many connections the database currently allows.
    You can also configure the shrink period of the pool if your user sessions are short, or if your users are not logging out ( which results in their session holding a connection until the session times out ).
    Are you seeing Leaked Connections ( you can configure the console to report these )?

  • We loose the jdbc connection

    Our connection pool looses connection to oracle(ORA-03114) in a random manner.
    We use jdk1.2, jdbc 8.1.6 drivers & oracle 8.0.5 db on solaris 2.6.
    This problem started when we switched from jdk1.1.7, jdbc 8.0.5.2.
    We also seem to have problems reading from a date column, rs.getString("DATECOLUMNNAME") has for some reason seized to work.
    The application is pretty db exhausting, we use a lot of long raw fields for storing images etc.
    The connection pool is a free version from Bitmechnic.

    You probably want to ask this question in the SQLJ/JDBC forum, or with Bitmechnic. ODBC is a similair protocol to JDBC, but they're completely separate products.
    Justin Cave
    ODBC Development

  • How can I appoint a kind of charset to the jdbc connection.

    The database charset is US7ASII,and I want to get it as charset GB2312.What should I do?
    As I know in other JDBC,we can set property of 'charset' when we use getConnection,but it seem not with oracle jdbc.Is there an other way?

    Is there anyone know it?

  • Toplink JPA: jdbc connection access required

    I have a strong reason why direct access to the connections used by Toplink JPA is required: for each connection I need to execute
    - a "set role" to grant permissions,
    - "set lock mode" to prevent hangups,
    - "set isolation" to get the correct transaction type,
    - possibly a "set explain on" to get query costs info,
    - and a "set constraints all deferred" to have constraints checked at commit time, not earlier.
    Can the Toplink pooling mechanism be replaced?

    You can use either an external data source from your container or an JDBC data source for that matter but you cannot replace the internal connection pool. Although one option may be to use a wrapped connection pool of your own I would first recommend looking at the SessionEventListener callbacks. Implementing this interface and registering it using a SessionCustomizer (persistence unit property) would allow you to be notified and get access to the JDBC connection when acquired and released from either pooling mechanism.
    Here is an example:
    public class JDBCConnectionListener extends SessionEventAdapter implements SessionCustomizer {
         * This method is used when this class is configured as the session customizer
         * in the persistence unit properties.
        public void customize(Session session) {
            session.getEventManager().addListener(this);
         * This event is raised after a connection is acquired from a connection pool.
        public void postAcquireConnection(SessionEvent event) {
            DatabaseAccessor da = (DatabaseAccessor)event.getResult();
            Connection con = da.getConnection();
            PreparedStatement statement;
            try {
                event.getSession().log(SessionLog.FINE, SessionLog.SQL, "POST-ACQUIRE> SELECT SYSDATE FROM DUAL");
                statement = con.prepareStatement("SELECT SYSDATE FROM DUAL");
                ResultSet rs = statement.executeQuery();
                rs.close();
            } catch (SQLException e) {
                // TODO
         * This event is raised before a connection is released into a connection pool.
        public void preReleaseConnection(SessionEvent event) {
    }Doug

  • What are the DMS metrics related to Open/Total JDBC Connections?

    Hi,
    We need to monitor that state of the JDBC Connection Pool (Available conns, Max conns, etc.) by reading DMS, however we are struggling to find which is the right DMS metric associated to it?
    We tried the table modplsql_DatabaseConnectionPool however it seems to be never loaded.
    Thanks in advance!
    CR

    Frances,
    For example, use "min-connections" to specify how
    many connections to pre-populate in the pool.Since when does "min-connections" pre-populate the pool?
    According to my observations, there are no database connections established when OC4J starts up. Connections are only created when necessary. As a matter of fact, I still haven't seen anything in the behaviour of OC4J to indicate that it doesn't totally ignore the "min-connections" attribute.
    [I have, on the other hand, seen that "max-connections" is taken into account by OC4J.]
    Good Luck,
    Avi.

  • Create a view in the database based off a jdbc connection

    I have some data in a DB2 database that I would like to union with a table in an Oracle Database in the Oracle Database.
    Can I create a jdbc connection in the Oracle database that points to the DB2 database and then create a view based off of the jdbc connection?
    I've never done anything like this , but if this a no brainer please just post a link or something that points me in the right direction thanks...
    I've searched...

    Mark,
    I was going to suggest the same thing as Jan did when she answered this question that you also posted to the Union DB2 and Oracle data in a view and display in a form using jdbc? forum.
    Good Luck,
    Avi.

  • JDBC Connectivity - broken pipe received when SQL server resets the connect

    Hi,
    We have downloaded MICROSOFT SQL SERVER 2000 DRIVER for UNIX boxes
    when i try to connect using JDBC , with all parameters
    user id, driver, password etc
    at the sniffer(TCPIP) level when the jdbc connection is attempted
    i see a
    1) SYN packet to the SQL server from unix box
    2) ACK SYN from the SQL server to unix box
    3) ACK from unix box to server
    4) no activity for about a minute
    5) a RST( reset ) from SQL server to unix box.
    at this point i get the following
    stack trace
    java.sql.SQLException: [Microsoft][SQLServer 2000 Driver for JDBC]Broken pipe or
    no reader on socket
    at com.microsoft.jdbc.base.BaseExceptions.createException(Unknown Source
    at com.microsoft.jdbc.base.BaseExceptions.getException(Unknown Source)
    at com.microsoft.jdbc.base.BaseExceptions.getException(Unknown Source)
    at com.microsoft.jdbc.sqlserver.tds.TDSLoginRequest.submitRequest(Unknow
    n Source)
    at com.microsoft.jdbc.sqlserver.SQLServerImplConnection.open(Unknown Sou
    rce)
    at com.microsoft.jdbc.base.BaseConnection.getNewImplConnection(Unknown S
    ource)
    at com.microsoft.jdbc.base.BaseConnection.open(Unknown Source)
    at com.microsoft.jdbc.base.BaseDriver.connect(Unknown Source)
    at java.sql.DriverManager.getConnection(DriverManager.java, Compiled Cod
    e)
    at java.sql.DriverManager.getConnection(DriverManager.java, Compiled Cod
    e)
    at wu.database.WUDBAccess.getGiftGramConnection(WUDBAccess.java, Compile
    d Code)
    at wu.util.GiftMailClient.ConnectToDB(GiftMailClient.java, Compiled Code
    at wu.util.GiftMailClient.ProcessEmail(GiftMailClient.java, Compile
    the sniffer trace
    Frame source = (Network)
    Length = 66
    Time received = 09/24/2002 21:19:42.543
    Frame Relay
    Header = 1041
    0001 00.. 0100 .... = DLCI 68
    .... ..0. .... 000. = (Command)
    EtherType = 0800 IP
    Internet Protocol (IP)
    Source address = unix_server
    Destination address = SQL_server
    Type of service = 00
    Length = 60
    Identification = 58024
    Flags = 0000 (May fragment, Last fragment)
    Time to live = 28
    Protocol = 6 TCP
    Transmission Control Protocol (TCP)
    Source Port = 2175
    Destination Port = 8072
    Sequence = 2690569244
    Acknowledgement = 0
    Flags = 02 (SYN)
    Window size = 8192
    ============================= Frame Number 7 =============================
    Frame source = (User)
    Length = 66
    Time received = 09/24/2002 21:19:42.544
    Frame Relay
    Header = 1041
    0001 00.. 0100 .... = DLCI 68
    .... ..0. .... 000. = (Command)
    EtherType = 0800 IP
    Internet Protocol (IP)
    Source address = SQL_server
    Destination address = unix_server
    Type of service = 00
    Length = 60
    Identification = 47302
    Flags = 4000 (Don't fragment, Last fragment)
    Time to live = 126
    Protocol = 6 TCP
    Transmission Control Protocol (TCP)
    Source Port = 8072
    Destination Port = 2175
    Sequence = 60776554
    Acknowledgement = 2690569245
    Flags = 12 (ACK, SYN)
    Window size = 17520
    ============================= Frame Number 8 =============================
    Frame source = (Network)
    Length = 58
    Time received = 09/24/2002 21:19:42.607
    Frame Relay
    Header = 1041
    0001 00.. 0100 .... = DLCI 68
    .... ..0. .... 000. = (Command)
    EtherType = 0800 IP
    Internet Protocol (IP)
    Source address = unix_server
    Destination address = SQL_server
    Type of service = 00
    Length = 52
    Identification = 58025
    Flags = 0000 (May fragment, Last fragment)
    Time to live = 28
    Protocol = 6 TCP
    Transmission Control Protocol (TCP)
    Source Port = 2175
    Destination Port = 8072
    Sequence = 2690569245
    Acknowledgement = 60776555
    Flags = 10 (ACK)
    Window size = 8192
    ****************************************************8
    ============================= Frame Number 9 =============================
    Frame source = (User)
    Length = 52
    Time received = 09/24/2002 21:21:35.137
    Frame Relay
    Header = 1041
    0001 00.. 0100 .... = DLCI 68
    .... ..0. .... 000. = (Command)
    EtherType = 0800 IP
    Internet Protocol (IP)
    Source address = SQL_server
    Destination address = unix_server
    Type of service = 00
    Length = 40
    Identification = 47451
    Flags = 4000 (Don't fragment, Last fragment)
    Time to live = 126
    Protocol = 6 TCP
    Transmission Control Protocol (TCP)
    Source Port = 8072
    Destination Port = 2175
    Sequence = 60776555
    Acknowledgement = 623322721
    Flags = 04 (RST)
    Window size = 0
    Data (ASCII)
    0000 = 00 00 00 00 00 00 ......
    any help is welcome
    Regards,
    Sunil

    Well then, it beats me. I don't see what the problem could be in this case. :o(
    Get another driver and see what happens. I would recommend jTDS, because I'm one of the developers and I can help you debug it. It only supports basic things (such as forward-only result sets, prepared statements and callable statements) but it should be enough to see if you can connect to SQL Server. The address is http://jtds.sourceforge.net
    Alin.

  • Jdbc connection in EJB using wsad 5.0

    Hi,
    I want to develop a small application using Ejbs by using oracle 9i as D/b, wsad 5.0 as app server . The problem is i am not able to connect to oracle database in WSAD. What i am doing is i have installed Oracle 9i in my system and has given the Global database name as "samp" while installation . I open my SQL plus with username scott and password tiger and i am able to do all my sql queries successfully.
    Now coming to WSAD,
    while creating a JDBC connection using Oracle 9i driver,
    i ve opened in Data perspective and in that go to DB Servers -> Right click -> New Connection
    There a window is opened for Database Connection.
    We need to fill the fields there.
    I have given samp as Global d/b name while installing Oracle 9i .
    In the window , the feilds are
    Connection Name : conn
    Database Name : samp
    user id : scott
    password : tiger
    D/b vendor type: Oracle 9i
    Jdbc Driver : Oracle Thin Driver
    Host : 127.0.0.1
    port No: 1521
    class location : c:\oracle\ora90\jdbc\lib\classes12.zip
    connection url : jdbc:oracle:thin:@127.0.0.1:1521:samp
    the class location and connection url are automatically coming.
    and please check whether all fields are correct or not
    Is this the correct way.
    Next in code if i want to connect to database should i use connection establish commands again or i can directly use create statement or prepare statement.
    Please reply.
    Thanks

    Create New Server and configure it properly
    It will work
    procedure is as follows:
    Pls visit the following link:
    http://www.webagesolutions.com/knowledgebase/waskb/waskb001/index.html
    Adding a Oracle9i DataSource from WSAD5
    Bibhas Bhattacharya, Web Age Solutions Inc.
    Before you begin, make sure that you have Oracle installed and a database is created. In this document we will use a database called MALL.
    Create a WAS V5 Server
    If you don't already have a WebSphere V5 server created, do so following these steps. Switch to the Server perspective. Right click in the Server Configuration view and select New->Server and Server Configuration.
    Name the server WASV5. Make sure that the Server type is set to WebSphere version 5.0->Test Environment. Click on Finish.
    Add the Database User
    In WSAD5, the default user ID and password to be used by a DataSource are first entered as a JAAS authentication entry.
    In the Server Configuration view, double click on WASV5 to open the configuration editor. Click on the Security tab. Next to the JAAS Authentication Entries list click on Add and add the user.
    Add the JDBC Driver
    Still in the server configuration GUI click on the DataSource tab. You can add the DataSource at the server level or at the node level. We will add it at the server level. Make sure that the Server Settings is expanded. Next to the JDBC providers list click on Add.
    Select the following options:
    Database type: Oracle
    JDBC provider type: Oracle JDBC Thin Driver or the XA version of it if you need two phase commit transaction.
    Click on Next.
    Set the name to Oracle Thin Driver.
    Notice that the location of the driver's class is automatically set to ${ORACLE_JDBC_DRIVER_PATH}/classes12.zip. Here, ORACLE_JDBC_DRIVER_PATH is a node level variable. We need to make sure that the variable is pointing to the correct directory where Oracle's JDBC driver is installed. In our case, we had installed Oracle in c:\oracle. This had installed the JDBC driver class in C:/oracle/ora81/jdbc/lib/classes12.zip.
    In the server configuration GUI click on the Variables tab. Under the Node settings select ORACLE_JDBC_DRIVER_PATH from the Defined variables list. Click on Edit and set the value to C:/oracle/ora81/jdbc/lib.
    Add the DataSource
    Click on the DataSource tab again. Select the Oracle Thin Driver you had created in the previous step. Click on Add next to the Data source defined in the JDBC provider selected above list.
    Select the following options:
    Select the type of JDBC Driver: Oracle JDBC Thin Driver.
    Select the data source type: Unless you will be testing your application with WAS V4, select Version 5.0. You can not use a V4 DataSource from a J2EE 1.3 EJB module running in WebSphere V5.
    Click on Next.
    Enter these key attributes in this screen:
    Name: My Oracle DataSource
    JNDI Name: jdbc/MyDataSource
    DataSource helper class name: com.ibm.websphere.rsadapter.OracleDataStoreHelper. Should be selected by default. The helper class is needed if you wish to access IBM extensions to JDBC. For more details search in WSAD help for "WSDataSource interface".
    Component-managed authentication alias: Set this if you wish to lookup the DataSource using its global JNDI name or using the java:comp/env/ name space and have set the authentication type of the resource reference to Application. Select the JAAS entry you had created. That is, Database user.
    Container-managed authentication alias: Set this if you intend to lookup the DataSource using the java:comp/env/ name space and have set the authentication type of the resource reference to Container. Select the JAAS entry you had created. That is, Database user.
    Use this data source in container managed persistence (CMP): Check on if you intend to use the DataSource from CMP EJBs.
    Click on Next.
    You need to set these properties:
    databaseName: MALL in our case.
    URL: jdbc:oracle:thin:@noble.webagesolutions.com:1521:MALL. In my case the server host name is noble.webagesolutions.com. The listener port number is 1521 (usually the default in most Oracle installations).
    Click on Finish.
    You have finished adding the DataSource. Save the server settings by clicking Control+S. Close the server configuration GUI.
    Testing the DataSource
    There is no out of the box way to test the DataSource. You can create a simple Servlet and add the following code:
    public void doGet(HttpServletRequest req, HttpServletResponse resp)
    javax.sql.DataSource ds = null;
    java.sql.Connection con = null;
    java.io.PrintWriter out = resp.getWriter();
    resp.setContentType("text/html");
    try {
    out.println("Looking up DataSource<br>");
    javax.naming.InitialContext ctx = new javax.naming.InitialContext();
    ds = (javax.sql.DataSource) ctx.lookup("jdbc/MyDataSource");
    out.println("Getting connection<br>");
    con = ds.getConnection();
    con.close();
    } catch (Exception e) {
    e.printStackTrace(out);
    out.println("Done<br>");
    Feedback
    Your e-mail:
    Rate this article:
    Very useful Somewhat useful Not bad Needs many corrections
    Comments:

Maybe you are looking for

  • Open and print multiple files from the Finder all at once.

    I'm trying to research how to do this. In OS9 you used to be able to hi-lite multiple files (Word files for example) and just hit Command+P. This would automatically open all of the files AND print them. I can't seem to do this in my OS X. Or can I?

  • Does Export Version reduces image quality?

    Hi, I got smaller file size when I "export version" at "original size". My master was jpeg of 5.1MB and I exported in jpeg format, I got 3.6MB. If I "export master", I do get 5.1MB. What does Aperture do to the jpeg image that reduces the file size?

  • Mac book pro with Retinal Screen

    Has anyone had a panel go dead with no warning on a 15 month old laptop?

  • WHY ANY UNIT_DECREMENT  OR UNIT_INCREMENT ?

    Hi, I know this is a theme already discussed in this forum but i couldn't find any valide answer. Does anyone know why JScrollBar keeps giving TRACK (via AdjustmentEvent.getAdjustmentType()) instead of the other values? I've written this code to real

  • Multiple Oracle Homes & php

    Hi I currently have ora8i, ora9i , 10XE & Zend Core for PHP installed on my machine. When I have just installed Zend, the PHP side works and can find the XE - no problem. When I have 'work' to do and need a different 'oracle_home' setup, I use the 'h