How to access defined connection in my project

I am new to JDeveloper,
I created a "Connection1" through Connection Wizard and store it under the Connections node in the System Navigator. I also tested it, it works fine itself.
According to online helper "All defined connections to external data sources are stored under this node. All defined connections are accessible to any workspace or project."
But how to use this "Connection1" in my Java Program? I just couldn't seem to find any example.
Thanks for help.

The Online Help has some nice tutorials to work with BC4J. There you will learn more about the wizards. JDev is not just for creating Java classes ;-). With BC4J you have a complete framework do access your DB, define your business logic, etc. I used the tutorials in the online help and the JDeveloper Handbook from McGraw-Hill. The new one covers JDev 9.0.3 as well.
Axel

Similar Messages

  • HT4356 how to access ethernet connection on iPad?

    without wirless how could we access ethernet connect?

    Connect your ethernet cable to a Airport Express to get Wi-Fi.
    https://www.apple.com/airportexpress/

  • How to access VPN Connection properties in Win 8.1

    Win 8.1 pro 64 bit
    I setup a VPN connection to my company host server. When I try to connect, I get no EAP protocol installed on the Win 8.1 system. I googled and it said to open VPN properties (like I have done before); however, I cannot find the open VPN properties function.
    I right click on the VPN and it does nothing. It did work in win8. How do I get to VPN properties to add EAP to the VPN connection?
    THX
    John Lenz

    To access to your VPN properties you should navigate to Control Panel > Network and Internet > Network Connections. From there, you will see all of your network connections, including any existing VPN connections. If you right click on the VPN connection
    in question, you will see "properties" listed at the bottom of the list and EAP settings can be modified under the security tab.  Let me know if you have trouble.   

  • How to access  database connection from datatsource in a standalone java ap

    My java standalone application wants connection to database with lookup to datasource name which is configured in the oc4j app server.
    Please guide me with some ideas to acheieve this.

    user510497,
    Following sample program requires access to classes in "oc4j.jar" file.
    Test environment:
    * Server:
    + OC4J stand-alone 10.1.2.0.2
    + Red Hat Enterprise Linux AS release 3
    + Java HotSpot(TM) Client VM (build 1.4.2_08-b03, mixed mode)
    + Oracle Database 10g Release 10.1.0.4.0 - 64bit Production
    * Client
    + Microsoft Windows XP Professional Version 2002 Service Pack 2
    + Java HotSpot(TM) Client VM (build 1.5.0_08-b03, mixed mode, sharing)
    import java.sql.Connection;
    import java.sql.DatabaseMetaData;
    import java.sql.SQLException;
    import java.util.Properties;
    import javax.naming.Context;
    import javax.naming.InitialContext;
    import javax.naming.NamingException;
    import javax.sql.DataSource;
    public class DataSrc2 {
      public static void main(String[] args) {
        Connection conn = null;
        Properties l_props = new Properties();
        l_props.put(Context.INITIAL_CONTEXT_FACTORY,
                    "com.evermind.server.rmi.RMIInitialContextFactory");
        l_props.put(Context.PROVIDER_URL, "ormi://your_OC4J_host/");
        l_props.put(Context.SECURITY_PRINCIPAL, "your_OC4J_user");
        l_props.put(Context.SECURITY_CREDENTIALS, "your_OC4J_password");
        Context l_jndiContext = null;
        try {
          l_jndiContext = new InitialContext(l_props);
          Object l_obj = l_jndiContext.lookup("default-data-source");
          DataSource ds = (DataSource) l_obj;
          conn = ds.getConnection("scott","tiger");
          DatabaseMetaData dbmd = conn.getMetaData();
          System.out.println(dbmd.getDatabaseProductVersion());
        catch (NamingException x_naming) {
          x_naming.printStackTrace();
        catch (SQLException xSql) {
          xSql.printStackTrace();
        finally {
          if (l_jndiContext != null) {
            try {
              l_jndiContext.close();
            catch (NamingException x_naming) {
              System.err.println("Failed to close JNDI context.");
              x_naming.printStackTrace();
          if (conn != null) {
            try {
              conn.close();
            catch (SQLException xSql) {
              System.err.println("Failed to close [database] connection.");
              xSql.printStackTrace();
    }NOTES:
    1. Datasource lookup name is value of "default-data-source" attribute of "orion-application" element in file:
    <OC4J_HOME>/j2ee/home/config/application.xmlGood Luck,
    Avi.

  • Need help on how to access secure connection sites

    Hi,
    i am unabe to connect https site. The same site is being accessed using other N97 mobile. He is getting message that can i connect to secure site yes or no. I amnot getting the same message. Initially i got the messae i seleced no by mistake now i am unable to access that site. This message is about lcertificates. Can some one help me

    By default there is no username and password is admin in lower case...If that does not work then,you need to reset the router for 30 seconds by pressing the reset button on the router and then,you have to reconfigure all the settings again from scratch.

  • How to access local connection factory created within Foreign Server in OSB

    Hi All
    I am facing an issue in my config plan. We have a RIB Foreign server with the following local connection factory:
    jms/RibAqJmsXATopicConnectionFactory
    I am using the below in my configuration plan:
    <cus:envValueAssignments>
    <xt:envValueType>Service URI</xt:envValueType>
    <xt:location xsi:nil="true"/>
    <xt:owner>
    <xt:type>ProxyService</xt:type>
    <xt:path>RLTPReturnToWarehouse/ProxyServices/ConsumeRIBRTWMessages</xt:path>
    </xt:owner>
    <xt:value xsi:type="xs:string" xmlns:xs="http://www.w3.org/2001/XMLSchema">jms://localhost:7001/jms.RibAqJmsXATopicConnectionFactory/jms.etASNInFromRIBToWH1</xt:value>
    </cus:envValueAssignments>
    and i am getting the below error:
    [java]
    [java] Loading customization File ./dev/OSBCustomizationFile.xml
    [java] Customization applied to the created resources only []
    [java] com.bea.wli.config.customization.EnvValueCustomization@553c13
    [java] Unexpected error: com.bea.wli.sb.transports.TransportException
    [java] Problem invoking WLST - Traceback (innermost last):
    [java] File "D:\VFUKScripts\DeploymentScripts\osb\import.py", line 200, in ?
    [java] File "D:\VFUKScripts\DeploymentScripts\osb\import.py", line 122, in importToALSBDomain
    [java] com.bea.wli.sb.transports.TransportException: Failed to lookup connection factory jms.RibAqJmsXATopicConnectionFactory
    what am i missing here?

    [java] com.bea.wli.sb.transports.TransportException: Failed to lookup connection factory jms.RibAqJmsXATopicConnectionFactory
    Looks like the JNDI that you created for the ConnectionFactory is not reflected in the server.
    Login to WLS Console> Summary of Servers > server_name > View JNDI Tree
    Browse to the JNDI tree and see if your JNDI is visible there. If it is not then, please restart the server and recheck.
    Once you are able to find it in the JNDI tree, then execute the customization file.
    If you have modified the existing JNDI properties (that have a small exclamatory symbol) then any changes to those are not reflected till all the servers in the cluster are restarted.
    If it still does not work, then recreate a new Connection with a different name and then retry. It should work then.
    Thanks,
    Patrick

  • I am tryin to access old macbookpro harddisk on macbook air,when i connect it via usb i see the folders,but i dont see any files e.g. photos,movies,docs are not there,its shows that 220gb is used,but no data is visible...can u pls adv how to access data?

    i am tryin to access old macbookpro harddisk on macbook air,when i connect it via usb i see the folders,but i dont see any files e.g. my saved photos,movies,docs are not there,its shows that 220gb is used,but no data is visible...all folder are empty.......can someone pls adv how to access data?

    i am tryin to access old macbookpro harddisk on macbook air,when i connect it via usb i see the folders,but i dont see any files e.g. my saved photos,movies,docs are not there,its shows that 220gb is used,but no data is visible...all folder are empty.......can someone pls adv how to access data?

  • How to get MS Access DB connection in struts frame work?

    Hi All,
    I am trying to get MS Access db connection in struts frame work .
    I am using websphere.I don't know whether i have to set any configuration in the WSAD.
    In struts-Config.xml i am having this mapping
    <data-source
    type="org.apache.commons.dbcp.BasicDataSource"
    key="userDB" >
    <set-property property="driverClassName"
    value="sun.jdbc.odbc.JdbcOdbcDriver" />
    <set-property property="url"
    value="jdbc:odbc:localhost:9080/u:/EmpDetails.mdb" />
    <set-property property="username" value="" />
    <set-property property="password" value="" />
    <set-property property="maxCount"
    value="4" />
    <set-property property=" minCount="
    value="2" />
    </data-source>
    In the action class i am having this code
    dataSource = getDataSource(request, "userDB");
    conn = dataSource.getConnection();
    stat=conn.createStatement();
    result1=stat.executeQuery("select * from emp");
    While trying to execute this code i am getting this error
    java.sql.SQLException: DBCP could not obtain an idle db connection, pool exhausted
    any idea why this error is occuring?
    Thanks in advance
    Janaki.

    Yes i know that but i only wanted to know how i will connect MS Access database with Java desktop Application in NetBeans

  • HT4436 Is there a way to connect my iCloud acct. so that my regular email address is my user name instead of the .me email address? I don't even know how to access my very old .me address.

    Anyone know if you can replace your .me email address for your regular email address? I'm trying to set up my iCloud acct. on my iPhone but the default email adddress is my .me email which I never used and do not know the password for. When I use the Forgot Password link, it sends to my .me email address
    and I never used it and don't know how to access that address. Arg. Anyway to clean slate and permanently eliminate the .me thing?

    I copied the iTunes file from the external drive and it's in both places.  I thought all I would need is the iTunes program (which I downloaded to new computer) and my iTunes library file.  There must be something else that's missing.  My iTunes library looks the same on the new computer as it does when I open it on the external drive.  If I click on an iTunes library song from my new computer, it will only play if I have the external drive plugged in.
    My back-up drive is a mess.  I have multiple copies of music, video, photo, and document files and I don't know how that happened. ={  Obviously, I don't know how to back up stuff properly and there are back-up files extending over a 6- to 8-year period.  I think all I did was just drag and drop the main folders from the back-up drive to the same main folders on the C: drive.  Also (and I'm kind of fuzzy on this) Windows used to automatically save music files in a folder within my document files (which makes no sense to me).  As my Jewish friends would say, "Oy Vey!" 

  • How to define the OSB Configuration Project that an OSB Project uses?

    Hello,
    I'm using the Workshop bundled with "Oracle Service Bus 10gR1" (Oracle Workshop for WebLogic, Version: 10.3, Build id: 1137967).
    Where does one define the OSB Configuration Project that an OSB Project should use?
    I deleted an OSB Configuration Project. Now, all the OSB projects that were associated with it are in error stating "This project is not associated with an Oracle Service Bus Configuration". I created a new OSB configuration project so that I may re-associate the "orphan" projects with it. However, I can't seem to find a way to do that.

    You can create a new osb configuration project and drag the other osb projects on this projects.
    then i will link them to it. (make sure you use the oracle service bus perspective at the top right of the eclipse ide)

  • Multiple connections in one project

    Hi,
    Is there perhaps some kind of a document describing a 'best practice' for using multiple connections in a ADF BC application. One connects to an oracle DB another to a SQLServer.
    I suppose I need to create two different services? Anybody having experience with this?
    Regards,
    Koen Verhulst

    Among other things, the BC4J Configuration defines the name of the JDBC connection to use. To solve your problem, you can create two Configurations one for each database. The JDBC connection value will be the only different element between these two Configurations. To create a BC4J Configuration in JDeveloper, right click on the AppModule node and then click Configurations...,
    Use oracle.jbo.client.Configuration class to create AppModules connected to the database you want.,
    import oracle.jbo.*;
    import oracle.jbo.client.Configuration;
    String am = "demo.DemoModule"; // Fully-qualified application module name
    // Configuration name with JDBC connection to source database
    String cf1 = "DemoModuleSourceDb";
    ApplicationModule amSrc = Configuration.createRootApplicationModule(am,cf1);
    // Configuration name with JDBC connection to dest database
    String cf2 = "DemoModuleDestDb";
    ApplicationModule amDest = Configuration.createRootApplicationModule(am,cf2);
    Note that the AM name can also be different if you want.
    Hope this helps,
    Sathish.
    I want to access several Databases from one BC4J-Project.
    For example I want to write an application, which collects data from one database, does some computation and stores the results in a second database.
    I would prefer to use BC4J-Components for both, the source and the target database, but unfortunately I can select only one connection per BC4J-Project.
    Has anyone got an idea, how I can access more than one database-connection from one BC4J-Project without having to write all the JDBC-Stuff on my own? JDev-Team, can you please give a hint?

  • How to access variables declared in java class file from jsp

    i have a java package which reads values from property file. i have imported the package.classname in jsp file and also i have created an object for the class file like
    classname object=new classname();
    now iam able to access only the methods defined in the class but not the variables. i have defined connection properties in class file.
    in jsp i need to use
    statement=con.createstatement(); but it shows variable not declared.
    con is declared in java class file.
    how to access the variables?
    thanks

    here is the code
    * testbean.java
    * Created on October 31, 2006, 12:14 PM
    package property;
    import java.beans.*;
    import java.io.Serializable;
    public class testbean extends Object implements Serializable {
    public String sampleProperty="test2";
        public String getSampleProperty() {
            return sampleProperty;
    }jsp file
    <%@ page contentType="text/html;charset=windows-1252"%>
    <%@ page import="java.sql.*,java.util.*"%>
    <html>
    <head>
    <title>Schedule Details</title>
    </head>
    <jsp:useBean id="ConProp" class="property.testbean"/>
    <body>
    Messge is : <jsp:getProperty name="msg" property="sampleProperty"/>
    <%
      out.println(ConProp.sampleProperty);
    %>
    </body>
    </html>out.println(ConProp.sampleProperty) prints null value.
    is this the right procedure to access bean variables
    thanks

  • How to determine the connection string to a SQLite database, in C# code

    Hello. I'm trying to figure out how to specify the connection string to a SQLite database, I would like to access using the following code:
    string connectionString = null;
    SqlConnection connection;
    SqlCommand command;
    SqlDataAdapter adapter = new SqlDataAdapter();
    DataSet ds1 = new DataSet();
    string sql = "SELECT DataName, Data, Id, UserId, DateLastUpdated FROM MainTable";
    connectionString = "Data Source=C:\\SQLITEDATABASES\\SQLITEDB1.sqlite;Version=3;";
    connection = new SqlConnection(connectionString);
    try
    connection.Open();
    command = new SqlCommand(sql, connection);
    catch
    The value I assigned to the variable connectionString, in the code above, I obtained somewhere from the Internet. It does not work. I'm using Visual Studio 2013, against the file sqlite-netFx451-setup-bundle-x86-2013-1.0.96.0.exe, which
    I installed, and got from
    here.
    My application's App.config file looks as follows:
    <?xml version="1.0" encoding="utf-8"?>
    <configuration>
    <configSections>
    </configSections>
    <connectionStrings>
    <add name="DC_Password_Saver.Properties.Settings.DC_Password_SaverConnectionString" connectionString="data source=&quot;C:\Users\patmo_000\Documents\Visual Studio 2013\Projects\DC Password Saver\DC Password Saver\DC Password Saver.db&quot;" providerName="System.Data.SQLite.EF6"/>
    </connectionStrings>
    <startup>
    <supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5.1"/>
    </startup>
    </configuration>
    I tried to use the value assigned to connectionString in the XML settings above, replacing single backslash characters with double backslash characters, because the Visual Studio editor flagged them as unrecognizable, and wound up with the
    following.
    SqlDataAdapter adapter = new SqlDataAdapter();
    DataSet ds1 = new DataSet();
    string sql = "SELECT DataName, Data, Id, UserId, DateLastUpdated FROM MainTable";
    connectionString = "data source=&quot;C:\\Users\\patmo_000\\Documents\\Visual Studio 2013\\Projects\\DC Password Saver\\DC Password Saver\\DC Password Saver.db&quot;";
    connection = new SqlConnection(connectionString);
    The above code however does not work either. So again, does anyone know how I can specify in C# code, a connection string to access my SQLite database? Thanks in advance for your reply.

    What does SQLite connection strings has to do with WPF?
    You will find some valid connection strings here:
    https://www.connectionstrings.com/sqlite/
    But you cannot use the SqlConnection class to connect to a SQLite database. You will need to download and add a reference to the System.Data.SQLite library and then use the SQLiteConnection class:
    connection = new System.Data.SQLite.SQLiteConnection(connectionString);
    try
    connection.Open();
    command = new System.Data.SQLite.SQLiteCommand(sql, connection);
    catch
    Please refer to the following article for more information and an example of how to connect and read and write data from an SQLite database using C#:
    http://blog.tigrangasparian.com/2012/02/09/getting-started-with-sqlite-in-c-part-one/.
    There is contains a link where you can download the required assemblies.
    Hope that helps.
    Please remember to mark helpful posts as answer to close your threads and then start a new thread in an approproate forum if you have a new question.

  • How to access Hyper-V Client from Hyper-V Server to the new machines?

    Hi
    We have a small company in that we have 50 machines, i am having windows 2012 r2 server, i installed Hyper-V with that i have created virtual OS(winxp and win7) in the Hyper-V server. My question is how to access them in client Machines, Can Anybody help
    me in this regards?
    Regards
    Meer Akbar Ali

    Hi Meer,
    In addition ,  you need to use external virtual switch for these VMs that are used for RDP connection from clients .
    Please refer to the article below for virtual network configuration :
    http://technet.microsoft.com/en-us/library/cc732470(v=WS.10).aspx#BKMK_ConfigVN
    Best Regards
    Elton Ji
    We
    are trying to better understand customer views on social support experience, so your participation in this
    interview project would be greatly appreciated if you have time.
    Thanks for helping make community forums a great place.

  • How to access XI_AF_MSG table in Composite Application Framework Java Code

    Hi Experts,
    I've no knowledge about PI. In one of my projects, I need access the XI_AF_MSG table of PI through java code in a composite application.
    How do I access this table? I've searched this forum for this query but the replies say that any SQL editor can be used to access XI_AF_MSG table. But my question is; How do I get the login details of the database? In the first place, how do I access the underlying database layer of PI? Is there any JAR file which can be used to make the connection?
    It would be of great help if any expert on this can give me a detailed reply.
    Thanks a lot in advance.
    Best Regards,
    Nitin

    Hi Nitin,
    The AFW runs on the J2EE Engine, so this table is in the Java Schema of the database and thus not visible in the ABAP stack. I guess you can use any tool your database provider offers for looking at table contents (e.g. SQLPlus).
    Regarding how to access the table please contact you basis administrator they will have access to the tables as they have j2ee_admin login ids and pwds.
    Regards
    joel

Maybe you are looking for

  • Adobe Camera Raw - CPU or RAM?

    Hey All! Please read the whole post, but if you want to cut to the chase, my question is: for ACR conversions would I be better off with an (Windows) 8-core system and 6gigs of ram, or a 4-core system and 12 gigs of ram? I am a professional photograp

  • Mail to File: Attachment is not getting picked

    Dears, I have configured a Mail to File Scenario: Where PI will read email and pick the first attachment (.PDF File) and place it on File Server, however some times it is not picking the attachment and not placing it on File server. Case1: In this ca

  • FILE CONTENT CONVERTION HELP...?

    Hi folks,    can anyone help mre giving file content conversion parameters for the below example. case 1 : ID, NAME, AGE               201, ABCDE,25   for the above case we use row.fieldNames, row.fieldSeperator, row.endSeperator. but if the case is

  • Max Hard drive total or per drive?

    I have a ThinkPad Edge E545 with a 1TB HDD.  The max hard drive size is 1TB according to the specs.  I was thinking of upgrading to a SSD.  If I do that, I would like to remove the DVD drive and put my current 1TB HDD in a caddy there.  Is that possi

  • Can't login to ML server network user from a client

    Hi, The computer name on my customer's ML server was changed post OD installation. Now I can't login with network user credentials from a MacBook. I also see the old server/hostname displayed in workgroup manager under "location" (see attached). I've