Error in creating JDBC datasource

I would like to create a new JDBC datasource using WLST script.
There are 2 problems with it:
1. Running the script an error message will be displayed:
Creating JDBCSystemResource with name DBonHelium5
JDBCSystemResource with name 'DBonHelium5' has been created successfully.
Problem invoking WLST - Traceback (innermost last):
File "/opt/wls9/jdbc_data_source_creation.py", line 30, in ?
AttributeError: addJndiName
I don’t understand why it is wrong and how could I fix the bug...
2. After running the script I looked at the current state on the console.
The datasource has been created but the target isn’t set.
Could you help me what’s wrong?
Thanks in advice!
Zsigmond
The script:
connect("xxx","xxx")
edit()
startEdit()
# Change these names as necessary
dsname="DBonHelium5"
cd("Servers/AdminServer")
#target=getMBean("Servers/AdminServer")
target=cmo
cd("../..")
# start creation
print 'Creating JDBCSystemResource with name '+dsname
jdbcSR = create(dsname,"JDBCSystemResource")
theJDBCResource = jdbcSR.getJDBCResource()
theJDBCResource.setName("DBonHelium5")
connectionPoolParams = theJDBCResource.getJDBCConnectionPoolParams()
connectionPoolParams.setConnectionReserveTimeoutSeconds(25)
connectionPoolParams.setMaxCapacity(100)
connectionPoolParams.setTestTableName("SYSTABLES")
dsParams = theJDBCResource.getJDBCDataSourceParams()
<b>dsParams.addJndiName("DBonHelium5")</b>
driverParams = theJDBCResource.getJDBCDriverParams()
driverParams.setUrl("jdbc:bea:oracle://helium.lsy.bud.dlh.de:1521")
driverParams.setDriverName("weblogic.jdbcx.oracle.OracleDataSource")
driverParams.setPassword("LSY")
driverProperties = driverParams.getProperties()
proper = driverProperties.createProperty("user")
proper.setValue("LSY")
proper1 = driverProperties.createProperty("DatabaseName")
proper1.setValue("dbc:bea:oracle://helium.lsy.bud.dlh.de:1521")
<b>jdbcSR.addTarget(target)</b>
try:
save()
activate(block="true")
print "script returns SUCCESS"
except:
print "Error while trying to save and/or activate!!!"
dumpStack()
disconnect()
exit()

Hi Manfed,
I've got exactly the same problem mit j2sdkee 1.3.1. Have yor resolved the problem in the meantime?
If so, please post the solution. Thanks.
Helmut

Similar Messages

  • Creating JDBC datasource in Weblogic 10

    I have a requirement to create JDBC datasource at runtime if necessary. Weblogic provides JMX services for creating datasource however this required credential of Admin Server (node manager).
    As my application is deployed in one of the managed node and as per the security policies admin credential will not be available..
    so how can I create a datasource at runtime on fly applicable only for my node.. this should not require admin credentials?
    Edited by: user5798282 on Apr 28, 2010 12:50 PM

    Thanks for your reply. However both seems to be way of creating datasource in weblogic 8 . The first one is deprecated in Weblogic 10, the 2nd one requires weblogic admin username and password

  • Weblogic : Creating JDBC Datasources

    Dear All,
    I'm newbie in weblogic . Please anyone guide me to create JDBC datasources for POSTGRESQL in steps.I've googled a lot for this. but i couldn't make it out. I'm using weblogic latest release 11g.Thanks in advance.

    Steps to configure a datasource can be found here: http://download.oracle.com/docs/cd/E21764_01/apirefs.1111/e13952/taskhelp/jdbc/jdbc_datasources/CreateDataSources.html
    As your Database Type, you can select postgresql from the drop down list.
    You also have to add the jar file that contains the postgresql drivers to the classpath.
    You add this to the <middleware-home>/user_projects/domains/<domain-name>/lib directory (after this you have to restart your server)

  • Error while trying to use Ant and creating Jdbc Datasource

    I was following the documentation to auto-create my datasource in my weblogic server. I get an error while it is trying to link the datasource to the server. Does anybody have any ideas,it is almost like the query to get the server isn't working.
    Here is my ant task:
    <target name="setupJdbcDatasource">
         <wlconfig url="t3://localhost:7001" username="weblogic" password="weblogic">
         <query domain="MyDomain" type="Server" name="AdminServer" property="adminserver"/>
         <create type="JDBCConnectionPool" name="TestDatasource" property="DatasourceTest">
              <set attribute="CapacityIncrement" value="1"/>
              <set attribute="DriverName" value="weblogic.jdbcx.oracle.OracleDataSource"/>
              <set attribute="InitialCapacity" value="1"/>
              <set attribute="MaxCapacity" value="10"/>
              <set attribute="Password" value="cmuser"/>
              <set attribute="Properties" value="user=cmuser SID=ORCH serverName=10.13.5.144 portNumber=1521"/>
              <set attribute="RefreshMinutes" value="0"/>
              <set attribute="ShrinkPeriodMinutes" value="15"/>
              <set attribute="ShrinkingEnabled" value="true"/>
              <set attribute="TestConnectionsOnRelease" value="false"/>
              <set attribute="TestConnectionsOnReserve" value="false"/>
              <set attribute="URL" value="jdbc:bea:oracle://10.13.5.144:1521"/>
              <set attribute="Targets" value="${adminserver}"/>
         </create>
         </wlconfig>
    </target>
    My Domain is MyDomain, and server is AdminServer. The error I get is:
    [wlconfig] weblogic.management.DistributedManagementException : Distributed Management [1 exceptions]
    BUILD FAILED
    X:\ibutt_PCView\src\CM\build.xml:285: Error invoking MBean
    command: javax.management.MBeanException
    And in my server log:
    jdbcDataSourceBean=[MBeanServerInvocationHandler]com.bea:Name=CP-ConfigManagemen
    tTest,Type=weblogic.j2ee.descriptor.wl.JDBCDataSourceBean,Parent=[MyDomain]/JDBC
    SystemResources[CP-ConfigManagementTest],Path=JDBCResource
    <May 21, 2006 3:50:57 PM EDT> <Warning> <JDBC> <BEA-001129> <Received exception
    while creating connection for pool "ConfigManagementTest": [BEA][Oracle JDBC Dri
    ver]Missing connection information: no serverName specified.>
    <May 21, 2006 3:50:58 PM EDT> <Error> <Deployer> <BEA-149265> <Failure occured i
    n the execution of deployment request with ID '1148241051441' for task 'weblogic
    .deploy.configChangeTask.2'. Error is: 'weblogic.application.ModuleException: '
    weblogic.application.ModuleException:

    Hi. This seems like an XML parsing problem.
    Could you please try changing the driver
    properties from:
    <set attribute="Properties" value="user=cmuser SID=ORCH serverName=10.13.5.144 portNumber=1521"/>
    to:
    <set attribute="Properties" value="user=cmuser SID=ORCH"/>
    The server and port are already in the URL
    thanks,
    Joe

  • IO Error while creating the Datasource in WLS Console

    Hello,
    We are using Jdeveloper 11.1.1.1.7, I am trying to create a Data Source using WLS Console, I am getting below error
      - I tried creating DB connection using SQL developer with same DB Connection info, it works fine.
      - I verified the Port by logging into corresponding UNIX box where weblogic server is running, I did telnet, and able to connect.
    any ideas are appreciate.
    Connection test failed.
    IO Error: The Network Adapter could not establish the connection<br/>oracle.jdbc.driver.T4CConnection.logon(T4CConnection.java:489)<br/>oracle.jdbc.driver.PhysicalConnection.<init>(PhysicalConnection.java:678)<br/>oracle.jdbc.driver.T4CConnection.<init>(T4CConnection.java:234)<br/>oracle.jdbc.driver.T4CDriverExtension.getConnection(T4CDriverExtension.java:34)<br/>oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:567)<br/>oracle.jdbc.pool.OracleDataSource.getPhysicalConnection(OracleDataSource.java:404)<br/>oracle.jdbc.xa.client.OracleXADataSource.getPooledConnection(OracleXADataSource.java:674)<br/>oracle.jdbc.xa.client.OracleXADataSource.getXAConnection(OracleXADataSource.java:267)<br/>oracle.jdbc.xa.client.OracleXADataSource.getXAConnection(OracleXADataSource.java:134)<br/>weblogic.jdbc.common.internal.DataSourceUtil.testConnection(DataSourceUtil.java:314)<br/>com.bea.console.utils.jdbc.JDBCUtils.testConnection(JDBCUtils.java:734)<br/>com.bea.console.actions.jdbc.datasources.createjdbcdatasource.CreateJDBCDataSource.testConnectionConfiguration(CreateJDBCDataSource.java:474)<br/>sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)<br/>sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)<br/>sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)<br/>java.lang.reflect.Method.invoke(Method.java:606)<br/>org.apache.beehive.netui.pageflow.FlowController.invokeActionMethod(FlowController.java:870)<br/>org.apache.beehive.netui.pageflow.FlowController.getActionMethodForward(FlowController.java:809)<br/>org.apache.beehive.netui.pageflow.FlowController.internalExecute(FlowController.java:478)<br/>org.apache.beehive.netui.pageflow.PageFlowController.internalExecute(PageFlowController.java:306)<br/>..

    The Network Adapter could not establish the connection exception is caused by one or more of the following configuration errors:
    The database host name, port number, or database instance name is wrong.
    The database TNSListener has not been started. The TNSListener may be started with the lsnrctlutility.
    C:>lsnrctl start
    1. What is the connection url?
    2. Is Oracle database running?

  • Error in creating a DataSource inVisual Administrator

    Hi Friends,
    My requirement is to connect to an external oracle database, for which I am trying to create a DATA SOURCE in Visual Administrator.
    the approach I followed is as given in many threads,
    In JDBC Connector service in Visual Admin:
    1. Created a driver using ojdbc.jar
    2. Created a datasource using the above driver,
    but after filling all the values, when I save it, I get following error(some part is displayed here):
    java.rmi.RemoteException: com.sap.engine.services.dbpool.exceptions.BaseRemoteException: Error during start of application "sap.com/DS_ConnectOracle". [id = StartupError]
         at com.sap.engine.services.dbpool.deploy.DataSourceManagerImpl.startApplication(DataSourceManagerImpl.java:608)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    Also this application name comes from where?
    why it is not able to start the application?
    Just to inform I am successfully able to connect to database using webdynpro application where I have coded the lines to connect to Oracle database.
    But DataSource thng is not working.
    Regards
    Deepak

    just to inform the issue is resolved, I got to know the cause.
    actually I was giving the DataSource Name & DataSource Alias Name as same,
    while they must be different.

  • Weird Error When Creating A Datasource

    Hi, I am getting the following error when trying to create a
    datasource in the CF administrator.
    Unable to update the NT registry.
    Variable DRIVERPATH is undefined.
    And when I navigate to my application through the web browser
    I get the following error:
    Error Executing Database Query.
    [Macromedia][SequeLink JDBC Driver][ODBC Socket]internal
    error: Data source name not found and no default driver specified
    Now, I have lots of experience of doing this before, but that
    was on my desktop machine which runs Vista Home Premium. This new
    laptop of mine also runs Vista Home Premium, but I think it is the
    64 bit version - could this have anything to do with it?
    I am using the Developers installation of Coldfusion 8 and
    trying to hook the exact same application and mdb database file
    that worked and used on my desktop machine - same files, same
    process as before.
    I can't figure out what is going wrong or how I can resolve
    the problem. Has anyone else encountered this before? If so, any
    advice would be great.
    Many thanks,
    Michael.

    Using CF 9 64-bit on a Windows Server 2008 and I still get the
    Unable to update the NT registry.
    Variable DRIVERPATH is undefined.
    message.
    Any thoughts on this?

  • Error while creating a datasource for XMLfile in DataFederator

    Hi,
    I am trying to create a datasource in Data federator for XML file, when I tried to click on Generate Elements and Attributes button
    Data Federator gives me error "Java.lang.reflect.InnovationTargetException".
    Thanx In Advance.
    Yogesh
    Edited by: mahayog74 on Dec 2, 2011 11:09 AM

    It looks like more of an issue with connecting to essbase, usually "java.lang.UnsatisfiedLinkError: no HspEssbaseEnv in java.library.path" means planning has not been installed or deployed correctly, what OS is it running on?
    Cheers
    John
    http://john-goodwin.blogspot.com/

  • Getting Error while creating Genric Datasource

    Hi,
    I was try to create genric extracter where i was getting error
    While creating view genric extracter where i am getting error "Entry A ZV_ZFRT  does not exist in DD02L - check your entry".
    My requirement is need to create extracter which is getting populated from three modules like SD,MM,FI/CO.From these three module i am using several tables and some of the tables don't have relation btween these tables as like foreign key and refrence key.
    Which extracter i need to create as given scenario?
    Does view will fullfill with my requirement or any other extracter.
    Please some one can help me in this scenario.
    Answer would be great appreciate.

    Hi,
    Rather than writing a program write a function module. Create a structure and include all the necessary fields in the structure. Then in the function module write the logic to extract the values for those fields. While creating the datasource specify the function module and structure name.
    Refer this link:
    /people/siegfried.szameitat/blog/2005/09/29/generic-extraction-via-function-module
    Hope this helps.
    PB

  • Invalid Extract Structure error while creating "Generic DataSource" on a view...

    Dear All,
    I have created a view on following tables MARA, AFKO and MSEG. The Table/Join condition is as follow:
    AFKO--AUFNR  = MSEG--AUFNR
    AFKO--PLNBEZ = MARA--MATNR
    I have included all the fields from MSEG and other all fields from MARA and AFKO. The view is created successfully and contents/records are also being fetched/displayed from this view.
    See screen shot as well:
    But when I go to RSO2 to create a "Generic DataSource" on this view. I get a series of warning messages and then error message "Invalid Extract Structure" and therefore I'm unable to create my DataSource on this view. See below screen shots of warning and error messages.
    Other warning messages are as follow:
    Field GAMNG with reference field MEINS: Reference table MARA is replaced by ZOXPRD0150
    Field PLSVB with reference field PLNME: Reference table PLKO is replaced by ZOXPRD0150
    Field PLSVN with reference field PLNME: Reference table PLKO is replaced by ZOXPRD0150
    Field LODIV with reference field MEINS: Reference table MARA is replaced by ZOXPRD0150
    Following is the screen shot of error message:
    1. How can I get rid of this error message and be able to create my "Generic DataSource" on top of this "View"?
    2. What should I do to resolve the above warning and error messages?
    I will appreciate your reply.
    Many thanks!
    Tariq Ashraf

    Hi Vipul,
    as you can find in CKIS table, the reference feild for value feild "WERTN" is missing.
    As per the table the reference feild is HWAER. This should have been used in place of FWAER.
    Try mentioning this in your view and this should work.
    Also I am a little enthusiastic to know, what are you trying to get from the datasource.
    If you are trying to get the cost estimate of multi level BOM, not (just one child level), then this approach may not work.
    There is a BAPI that gives such itemization split. Just FYI, in case you are looking for multi level explosion.
    "BAPI_COSTESTIMATE_ITEMIZATION".
    Hope this helps.
    Naveen.A

  • Error while creating Generic Datasource

    Hi,
    I try to create generic datasource using function module in RSO2, it is giving the following errors and the datasource is not creating.
    "Units field WAERK for field TOT_REV of DataSource ZIPO_TRANSCATION is hidden Message no. R8147"
    "Units field WAERK for field EXP_REV of DataSource ZIPO_TRANSCATION is hidden Message no. R8147"
    TOT_REV and EXP_REV fileds datatype is CURR.
    Fuction Module is working fine. Please give me any inputs, it is very urgent.
    Best Regards,
    SGK.

    hi,
    let WAERS field be present in your structure defn
    In the Currency/Quantity fields tab of your extract structure give the refernce of the same structure and same field
    Regards,
    Sampat

  • Creating JDBC Datasource without Console

    I am new to WebLogic. Currently, getting up to speed with WebLogic server 10.3. I can create a JDBC pool from the console. Is there a way to create the JDBC pool without using the console? Also, is there a way that we can create the JDBC resource during the deployment of the application via WAR file?
    Thanks in advance.

    please see: Re: Creating JDBC Resource without Console

  • Getting following error while creating a datasource connection with oracle database.

    I have 32 bit oracle server installed in remote server.
    and 64 bit sql server 2008 r2 report server installed, and 64 bit oracle client installed on my report server  while create a new datasource
    in the report server i am getting this error
    Error 
    Attempt to load Oracle client libraries threw BadImageFormatException. This problem will occur when running in 64 bit mode with the 32 bit Oracle
    client components installed
    How can i fix this and let me know the reason

    This link will help you out.
    http://social.msdn.microsoft.com/Forums/en-US/sqlreportingservices/thread/0a38fa00-31de-49de-b68f-4c5a4565e5b1?prof=required
    Milan Das

  • Error while creating a datasource in planning 9.3.1 on oracle 11.2 database

    I am unable to create datasource in planning 9.3.1 on oracle 11.2 database. I have configure sharedservices and registered planning with shared servers. I am unable to create data source after application deployment and instance creation.
    I am getting the following error,
    Launching Hyperion Configuration Utility Program
    HYPERION_HOME: C:\Hyperion
    In HspDBPropertiesLocationPanel constructor
    In HspDBPropertiesLocationPanel queryEnter
    Resource Bundle is java.util.PropertyResourceBundle@322394
    Product Name in file is PLANNING
    Availability Date is 20051231
    Creating rebind thread to RMI
    Resource Bundle is java.util.PropertyResourceBundle@322394
    Product Name in file is PLANNING
    Availability Date is 20051231
    $$$$$$$$$$$$$ dname is
    Resource Bundle is java.util.PropertyResourceBundle@322394
    Product Name in file is PLANNING
    Availability Date is 20051231
    Exception in thread "AWT-EventQueue-0" java.lang.UnsatisfiedLinkError: no HspEss
    baseEnv in java.library.path
    at java.lang.ClassLoader.loadLibrary(Unknown Source)
    at java.lang.Runtime.loadLibrary0(Unknown Source)
    at java.lang.System.loadLibrary(Unknown Source)
    at com.hyperion.planning.olap.HspEssbaseEnv.<clinit>(Unknown Source)
    at com.hyperion.planning.olap.HspEssbaseJniOlap.<clinit>(Unknown Source)
    at com.hyperion.planning.HspJSHomeImpl.TestEssConnection(Unknown Source)
    at com.hyperion.planning.HspDSEssbasePanelManager.TestEssConnection(HspD
    SEssbasePanelManager.java:156)
    at com.hyperion.planning.HspDSEssbasePanelManager.queryExit(HspDSEssbase
    PanelManager.java:132)
    at com.hyperion.cis.config.wizard.ProductCustomInputPanel.queryExit(Prod
    uctCustomInputPanel.java:114)
    at com.installshield.wizard.awt.AWTWizardUI.doNext(Unknown Source)
    at com.installshield.wizard.awt.AWTWizardUI.actionPerformed(Unknown Sour
    ce)
    at com.installshield.wizard.swing.SwingWizardUI.actionPerformed(Unknown
    Source)
    at com.installshield.wizard.swing.SwingWizardUI$SwingNavigationControlle
    r.notifyListeners(Unknown Source)
    at com.installshield.wizard.swing.SwingWizardUI$SwingNavigationControlle
    r.actionPerformed(Unknown Source)
    at javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
    at javax.swing.AbstractButton$Handler.actionPerformed(Unknown Source)
    at javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)
    at javax.swing.DefaultButtonModel.setPressed(Unknown Source)
    at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(Unknown Sour
    ce)
    at java.awt.Component.processMouseEvent(Unknown Source)
    at javax.swing.JComponent.processMouseEvent(Unknown Source)
    at java.awt.Component.processEvent(Unknown Source)
    at java.awt.Container.processEvent(Unknown Source)
    at java.awt.Component.dispatchEventImpl(Unknown Source)
    at java.awt.Container.dispatchEventImpl(Unknown Source)
    at java.awt.Component.dispatchEvent(Unknown Source)
    at java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
    at java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
    at java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
    at java.awt.Container.dispatchEventImpl(Unknown Source)
    at java.awt.Window.dispatchEventImpl(Unknown Source)
    at java.awt.Component.dispatchEvent(Unknown Source)
    at java.awt.EventQueue.dispatchEvent(Unknown Source)
    at java.awt.EventDispatchThread.pumpOneEventForHierarchy(Unknown Source)
    at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
    at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
    at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
    at java.awt.EventDispatchThread.run(Unknown Source)
    But, My essbase server is up and running. I am able to connect it through EAS.

    It looks like more of an issue with connecting to essbase, usually "java.lang.UnsatisfiedLinkError: no HspEssbaseEnv in java.library.path" means planning has not been installed or deployed correctly, what OS is it running on?
    Cheers
    John
    http://john-goodwin.blogspot.com/

  • Error while creating JDBC connection pool for MSSQL database

    Hi,
    From my windows m/c, I am trying to configure a connection pool to connect to
    an MSSQL database on another m/c. While setting the targets, i get the error :-
    <Mar 11, 2004 6:17:52 PM GMT+08:00> <Error> <JDBC> <Cannot startup connection
    pool "gcdb_connpool" Cannot load driver class: com.microsoft.jdbc.sqlserver.SQLServerDriver>
    I have added the path of the jars for the driver in the classpath.
    Any help would be appreciated.
    Thanks.

    Hi. Read the weblogic startup script, and follow how it creates
    a classpath argument for the server. You must get the driver jars
    into that classpath.
    Joe
    Neha wrote:
    Hi,
    From my windows m/c, I am trying to configure a connection pool to connect to
    an MSSQL database on another m/c. While setting the targets, i get the error :-
    <Mar 11, 2004 6:17:52 PM GMT+08:00> <Error> <JDBC> <Cannot startup connection
    pool "gcdb_connpool" Cannot load driver class: com.microsoft.jdbc.sqlserver.SQLServerDriver>
    I have added the path of the jars for the driver in the classpath.
    Any help would be appreciated.
    Thanks.

Maybe you are looking for

  • PDF Properties: How to Set Using Smartforms

    Hi. Is it possible to Set the properties of PDF forms from SMARTFORMS? When you open PDF, File --> Properties --> Security --> Filling of Fields: Not Allowed. How do i set it to Not Allowed? Is this something that can be handled by SMARTFORMS? We are

  • Macbook pro adapter

    i have a macbook pro 2009 model and i want to connect it to a external monitor, what cables would i need. i think its a vga output adapter on the monitor.

  • Picture won't display in web browser

    Hi Everyone, I have a website that I have created and I place a graphic in .jpg and also .png format inside of a div tag on the left side of my page template. When I go to view the web page everything else on the page will display except for this gra

  • Retouch tool adjustments not saving

    Had this problem in previous version of Aperture (after it worked it just stopped working!). Changes I make using the repair tool to Repair or Clone are not showing.  When I make a repair, there is a long delay with "Loading" showing and when that op

  • Epson R1900 Printer Installed with Airport but not printing

    I just installed my new Epson R1900 Printer and it says that it is online and recognized but when I send something to print it comes up in the queue and then disappears and doesn't print. The printer isn't idle or anything like that though, it still