Orinda and OracleConnection

For using the Orinda classes and methods I need an OracleConnection.
For example:
http://www.orindasoft.com/public/JDeveloper%20Addintwo.php4
row 92:
// Create a connection93
theConnection = (OracleConnection
DriverManager.getConnection(
"jdbc:oracle:thin:@" +
theIpAddress +
":" + thePort +
":" + theSid,
theUser,
thePassword);
row 114:
complexExampleAddBookings addBookings = new complexExampleAddBookings(theConnection, theLog);
I'm able only to get the DBTransaction:
AppModuleImpl am = (AppModuleImpl)
panelBinding.getApplicationModule();
oracle.jbo.server.DBTransaction dbTx =
(oracle.jbo.server.DBTransaction)
am.getTransaction();
How about getting the connection handler???
Thanks
R

For using the Orinda classes and methods I need an
OracleConnection.
I'm able only to get the DBTransaction:
AppModuleImpl am = (AppModuleImpl)
panelBinding.getApplicationModule();
icationModule();
oracle.jbo.server.DBTransaction dbTx =
(oracle.jbo.server.DBTransaction)
am.getTransaction();
How about getting the connection handler???
When we wrote OrindaBuild we went out of our way to have a few dependencies on external resources as possible. As a result our stuff uses Connection objects. Over the next couple of weeks we will look at the best way to make our classes access an oracle.jbo.server.DBTransaction as well as a Connection. In the mean time you can use this workaround:
Connection conn = getDBTransaction()
     .createCallableStatement("select 1 from dual",1)
     .getConnection();David Rolfe
Orinda Software
Dublin, Ireland
www.orindasoft.com

Similar Messages

  • Error when opening Oracle DB

    Hi all,
    I am trying to access my oracle DB from an ASP.NET page. I am using Oracle Client 10.1.0.2.0 and Oracle ODBC drivers 10.1.0.3.0 according to Universal Installer. The code is in C# and uses System.Data.OracleClient to declare a OracleConnection object. Password, user name and all that are set correct. But when I try to open the DB I get:
    System.Data.OracleClient requires Oracle client software version 8.1.7 or greater.
    I have Oracle Client 10.1.0.2.0 which is be greater that 8.1.7. isn't it? So what is going on? I am new to .NET, C# and Oracle, so I could realy use some help.
    Thanks in advance
    URW

    Hello,
    I'm trying to connect to an oracle DB and i'm getting exactly the same error.
    i use System.Data.OracleClient and OracleConnection to connect.
    The code throughs the exception at "connection.Open()".
    This is not an asp.net application.
    Any help will be higly appreciated.
    Thanks
    /Kadji

  • Is Oracle JDBC driver thread safe

    Is the Oracle JDBC driver thread safe?

    Seems that this is not totally true.
    We have a Problem with Oracle JDBC driver 9.2.0.5.0 (thin)
    Using an IBM JDK 1.4
    Szenario:
    Thread 1 access to a CLOB via
    ResulSet.getCharacterStream(int)
    Thread 2 normal access via some select and
    ResulSet.getString(int)
    (Both using the same connection)
    The following threads appear to be in a circular deadlock.
    Further information can be found by looking in the Overall Thread Analysis
    section of this tool.
    Multi-threaded deadlock 1:
    "Servlet.Engine.Transports : 6" of (sys:0x39778800) (TID:0x104590D0)
    Holding Resource: oracle.jdbc.ttc7.TTC7Protocol@1ADEB358/1ADEB360
    Thread Waiting: "ProcessNotificationTask" (sys:0x3C51FC18) (TID:0x103B4C40)
    "ProcessNotificationTask" of (sys:0x3C51FC18) (TID:0x103B4C40)
    Holding Resource: oracle.jdbc.driver.OracleConnection@1AE45160/1AE45168
    Thread Waiting: "Servlet.Engine.Transports : 6" (sys:0x39778800) (TID:0x104590D0)
    4XESTACKTRACE at oracle.jdbc.driver.OracleStatement.doExecuteQuery(OracleStatement.java:2667)
    4XESTACKTRACE at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:2840)
    4XESTACKTRACE at oracle.jdbc.driver.OraclePreparedStatement.executeUpdate(OraclePreparedStatement.java:608)
    4XESTACKTRACE at oracle.jdbc.driver.OraclePreparedStatement.executeQuery(OraclePreparedStatement.java:536)
    4XESTACKTRACE at com.top_logic.knowledge.service.db.DBKnowledgeBase.getObjectsByAttribute(Unknown Source)
    4XESTACKTRACE at oracle.jdbc.ttc7.TTC7Protocol.getLobChunkSize(TTC7Protocol.java:3050)
    4XESTACKTRACE at oracle.sql.LobDBAccessImpl.getChunkSize(LobDBAccessImpl.java:687)
    4XESTACKTRACE at oracle.sql.CLOB.getChunkSize(CLOB.java:692)
    4XESTACKTRACE at oracle.sql.CLOB.getBufferSize(CLOB.java:717)
    4XESTACKTRACE at oracle.sql.CLOB.getCharacterStream(CLOB.java:345)
    4XESTACKTRACE at oracle.sql.CLOB.characterStreamValue(CLOB.java:1377)
    4XESTACKTRACE at oracle.jdbc.driver.OracleStatement.getCharacterStreamValue(OracleStatement.java:5817)
    4XESTACKTRACE at oracle.jdbc.driver.OracleResultSetImpl.getCharacterStream(OracleResultSetImpl.java:1230)
    It seems that the access to the CLOB needs another,
    internal SELECT to the Database and this way
    TTC7Protocol and OracleConnection lock out each other.
    This only happens on a true multiprocessor machine.
    We tried to reprodcue it on a Single Processor
    and some HyperThreading Machine but had no real sucess.
    Now where can I sumbit this as a Bug ?

  • Tomcat: Advanced usage of OracleDataSource

    Basic configuration of OracleDataSource in Tomcat (5.5) works fine. But how do I configure sophisticated connection attributes like oracle.jdbc.ReadTimeout ??
    actual definition (context.xml):
    <Resource
    name="jdbc/myds"
    auth="Container"
    scope="Shareable"
    type="oracle.jdbc.pool.OracleDataSource"
    driverclassname="oracle.jdbc.driver.OracleDriver"
    factory="oracle.jdbc.pool.OracleDataSourceFactory"
    url="jdbc:oracle:thin:@172.20.109.174:1521:mydb"
    user="myuser"
    password="mypwd"
    connectionCachingEnabled="true"
    connectionCacheName="MyCache"
    connectionCacheProperties="{MaxLimit=10, MinLimit=0, InitialLimit=0, ValidateConnection=true, ConnectionWaitTimeout=60}"
    />
    Thanks,
    Michael

    Thanks for your reply.
    Assignment to "connectionProperties" doesn't work.
    At least ((OracleDataSource)datasource).getConnectionProperties() is empty and
    ((OracleConnection)datasource.getConnection()).getProperties() does not contain oracle.net.ReadTimeout.
    But in the end you are right. All I want to do is to catch a timeout in case of listener isn't available. In case of firewall issues JDBC requests are hanging too long. SQLPlus comes back within reasonable time.
    Regards,
    Michael

  • Error when updating oracle db

    I've been trying to figure out this error I get sometimes when I update my oracle database.  I haven't been able to track down exact steps to make it happen but when it does happen, it seems to break any query call to the database that looks at the record I was attempting to update (at least that's what I'm thinking).  The message I get is below.  Has anyone else experienced this?
    Error Executing Database Query.
    [Macromedia][SequeLink JDBC Driver]Network problem, session aborted due to internal error in remote procedure call, connection closed.
    Thanks!

    Hello,
    I'm trying to connect to an oracle DB and i'm getting exactly the same error.
    i use System.Data.OracleClient and OracleConnection to connect.
    The code throughs the exception at "connection.Open()".
    This is not an asp.net application.
    Any help will be higly appreciated.
    Thanks
    /Kadji

  • How to return custJava Object from Java Stored Function/Procedure to Java Application

    I WILL PAY $100 FOR SOLUTION.
    Oracle JDBC documentation gives step by step on how to return Oracle Type Object to Java Application. No question here.
    But is it possible to create Java Stored Function [getMyClass() ] which returns CUSTOM Java based object [MyClass] to Java application like:
    //java stored function
    class Foo
    public static MyClass getMyClass()
    return new MyClass();
    //java class I want to return to Java
    class MyClass
    public String getGreetings(String name)
    return "Hello " + name;
    I tried to do it using intermittent Oracle
    Type Object and OracleConnection map to make binding between Java->Oracle->Java. I could
    not get throgh meaningless run time ORA Errors. Any kind of help would be greatly
    appreciated. If you know the answer please
    post it or e-mail [email protected]
    null

    You don't say which version of the database you are on. There's an interesting looking article on OTN on handling CLOBs in JDBC in 10g. It may well be useful for earlier versions too (but no guarantees).
    Cheers, APC

  • Creation of new OracleConnection VERY SLOW in VS2008

    Hi all,
    I've only found one other post regarding this issue with the latest version of the oracle data provider (2.111.6.20) on the Oracle Developer Tools for VS Forum (at: Re: Need help troubleshooting extremely slow ODT speeds in VS 2005. Figured I'd post it here to see if anyone else is experiencing problems.
    I've got VS2008 with the latest release of ODAC/Developer tools for VS installed and when I try to just create a connection object (i.e. OracleConnection con = new OracleConnection()), it is taking upwards of 45 seconds to create. Obviously this is unsuitable. Is this a known bug? If so, do I need to revert back to older version of OracleDataAccess assembly as stated in the aforementioned post?
    I'm really looking for a solution with this version however, as I'm trying to work with some UDTs in Oracle and converting to custom types in .NET and from what I've read, this latest version is the only one that can do so. (correct me if I'm wrong).
    Any information is appreciated!

    Hi Greg. Indeed, it is the constructor, which seemed very strange to me. But, here's my latest developments... Guess I failed to mention what platforms I was running on, which I'm pretty sure probably had something to do with it. I had a development environment on both a Vista 64-bit, and a Windows Server 2008 (both VMWare virtual machines). Each had two oracle clients installed, both 11g (instant) and 10gR2 (full), as I needed the 10g client for Quest Code tester (entirely different issue!). Anyway, I'm fairly certain that neither of those platforms are officially supported, so most likely my fault.
    I didn't run your test, but I had something similar set up as follows:
    using System;
    using Oracle.DataAccess.Client;
    using System.Diagnostics;
    namespace oratest
    class Program
    static void Main(string[] args)
    Stopwatch sw = new Stopwatch();
    sw.Start();
    OracleConnection con = new OracleConnection();
    sw.Stop();
    TimeSpan ts = sw.Elapsed;
    Console.WriteLine(ts.Seconds.ToString());
    The results printed ranged from 20-45 seconds!!!
    So, I went ahead and created exactly the same setup on a Vista 32-bit virtual machine. Ran the same test and voila, 0 seconds. If your interested, I ran with the ts.Milliseconds.ToString() in the last line and it resulted in 611 milliseconds. So, I've moved my current project development environment to the new Vista 32-bit virtual machine and it seems to be working fine.
    Just as a side bar however, I've also been doing quite a bit of development on a real (non-virtual) 64-bit Vista machine, and the new ODP has been working just fine. But, I have only the 11g client installed on that machine. Could it be confusion between the multiple versions? Platform issues? Both? Don't know myself, but am content enough to work in my new environment.
    Cheers,
    Aaron

  • Connection Pooling and JSP Custom Tag Library - is code (inside) the best way/correc?

    Hi, can anyone advise as to whether my tag library code (based
    on Apache Jakarta Project) will actually achieve connection
    pooling functionality across my entire JSP based application? I
    am slightly concerned that my OracleConnectionCacheImpl object
    may exist multiple times, hence rendering my conection pooling
    attempt useless.
    package com.solved.tag.dbtags.connection;
    import java.io.IOException;
    import java.sql.Connection;
    import java.sql.SQLException;
    import javax.servlet.jsp.tagext.TagSupport;
    import javax.servlet.jsp.JspTagException;
    import javax.sql.DataSource;
    import javax.naming.InitialContext;
    import javax.naming.NamingException;
    import oracle.jdbc.pool.OracleConnectionCacheImpl;
    * <p>JSP tag connection, used to get a
    * java.sql.Connection object.</p>
    * <p>JSP Tag Lib Descriptor
    * <pre>
    * &lt;name>connection&lt;/name>
    &lt;tagclass>com.solved.tag.dbtags.connection.ConnectionTag&lt;/t
    agclass>
    * &lt;bodycontent>JSP&lt;/bodycontent>
    &lt;teiclass>com.solved.tag.dbtags.connection.ConnectionTEI&lt;/t
    eiclass>
    * &lt;info>Opens a connection based on a jndiName.&lt;/info>
    * &lt;attribute>
    * &lt;name>id&lt;/name>
    * &lt;required>true&lt;/required>
    * &lt;rtexprvalue>false&lt;/rtexprvalue>
    * &lt;/attribute>
    * </pre>
    * @author Matt Shannon
    public class ConnectionTag extends TagSupport {
    static private OracleConnectionCacheImpl cache = null;
    public int doStartTag() throws JspTagException {
    try {
    Connection conn = null;
    if (cache == null) {
    try {
    InitialContext ic = new InitialContext();
    DataSource ds = (DataSource) ic.lookup
    ("jdbc/pool/OracleCache");
    cache = (OracleConnectionCacheImpl)ds;
    catch (NamingException ne) {
    throw new JspTagException(ne.toString());
    conn = cache.getConnection();
    pageContext.setAttribute(getId(),conn);
    catch (SQLException e) {
    throw new JspTagException(e.toString());
    return EVAL_BODY_INCLUDE;
    package com.solved.tag.dbtags.connection;
    import java.sql.Connection;
    import java.sql.SQLException;
    import javax.servlet.jsp.tagext.TagSupport;
    * <p>JSP tag closeconnection, used to close the
    * specified java.sql.Connection.<p>
    * <p>JSP Tag Lib Descriptor
    * <pre>
    * &lt;name>closeConnection&lt;/name>
    &lt;tagclass>com.solved.tag.dbtags.connection.CloseConnectionTag&
    lt;/tagclass>
    * &lt;bodycontent>empty&lt;/bodycontent>
    * &lt;info>Close the specified connection. The "conn"
    attribute is the name of a
    * connection object in the page context.&lt;/info>
    * &lt;attribute>
    * &lt;name>conn&lt;/name>
    * &lt;required>true&lt;/required>
    * &lt;rtexprvalue>false&lt;/rtexprvalue>
    * &lt;/attribute>
    * </pre>
    * @author Matt Shannon
    * @see ConnectionTag
    public class CloseConnectionTag extends TagSupport {
    private String _connId = null;
    * The "conn" attribute is the name of a
    * page context object containing a
    * java.sql.Connection.
    * @param connectionId
    * attribute name of the java.sql.Connection to
    close.
    * @see ConnectionTag
    public void setConn(String connectionId) {
    _connId = connectionId;
    public int doStartTag() {
    try {
    Connection conn = (Connection)pageContext.getAttribute
    (_connId);
    conn.close();
    } catch (SQLException e) {
    // failing to close a connection is not fatal
    e.printStackTrace();
    return EVAL_BODY_INCLUDE;
    public void release() {
    _connId = null;
    package com.solved.tag.dbtags.connection;
    import javax.servlet.jsp.tagext.TagData;
    import javax.servlet.jsp.tagext.TagExtraInfo;
    import javax.servlet.jsp.tagext.VariableInfo;
    * TagExtraInfo for the connection tag. This
    * TagExtraInfo specifies that the ConnectionTag
    * assigns a java.sql.Connection object to the
    * "id" attribute at the end tag.
    * @author Matt Shannon
    * @see ConnectionTag
    public class ConnectionTEI extends TagExtraInfo {
    public final VariableInfo[] getVariableInfo(TagData data)
    return new VariableInfo[]
    new VariableInfo(
    data.getAttributeString("id"),
    "java.sql.Connection",
    true,
    VariableInfo.AT_END
    data-sources.xml:
    <?xml version="1.0"?>
    <!DOCTYPE data-sources PUBLIC "Orion data-
    sources" "http://xmlns.oracle.com/ias/dtds/data-sources.dtd">
    <data-sources>
    <data-source
    class="oracle.jdbc.pool.OracleConnectionCacheImpl"
    name="jdbc/pool/OracleCache"
    location="jdbc/pool/OracleCache"
    url="jdbc:oracle:thin:@oracle1:1521:pdev"
    >
    <property name="maxLimit" value="15" />
    <property name="cacheScheme" value="2" />
    <property name="user" value="console" />
    <property name="password" value="console" />
    <description>
    This DataSource is using an Oracle-native DataSource Class so as
    to allow Oracle Specific extensions.
    A getConnection() call on this DataSource will return
    oracle.jdbc.driver.OracleConnection.
    The connection returned is a logical connection.
    The caching scheme in place is Fixed Wait. Refer below to
    possible values.
    Dynamic 1
    Fixed Wait 2
    Fixed Return Null 3
    </description>
    </data-source>
    </data-sources>
    many thanks,
    Matt.

    Hi. Show me your pool definition.
    Joe
    Ramamurthy wrote:
    I am using the jsp custom tag library from BEA called sqltags.tld which came with Weblogic 5.1. Currently I am using Weblogic6.1 sp2 on Solaris.
    I have created a Connection Pool for Sybase database using the driver com.sybase.jdbc.SybDriver.
    When I created jsp page to connect to the connection pool using sqltags custom tag library, I am getting the error
    "javax.servlet.jsp.JspException: Failed to write body content
    at weblogic.taglib.sql.ConnectionTag.doAfterBody(ConnectionTag.java:43)
    at jsp_servlet.__hubwcdata._jspService(__sampletest.java:1014)"
    After this message, whenever I try to access the same jsp page I am getting the message
    "javax.servlet.jsp.JspException: Failed to load JDBC driver: weblogic.jdbc.pool.D
    river
    at weblogic.taglib.sql.ConnectionTag.doStartTag(ConnectionTag.java:34)
    at jsp_servlet.__hubwcdata._jspService(__sampletest.java:205)".
    Can you please help me the reason why this problem is happening and how to fix this ?
    This problem doexn't happen consistently. This occurs once in a while.
    I tried to increase Login delay Seconds parameter in the Connection Pool to 15 sec. It didn't help me much.
    Thanks for your help !!!
    Ram

  • PL/SQL TABLE AS OUT ON PROCEDURE CALL AND JDBCTHIN(NEED HELP

    How can I pass pl/sql record in and out
    and pl/sql tables in out thru a pl/sql procedure using jdbc with
    the zip file of 816classes12.zip...
    I have tried everything I know...
    I know the procedure is working, others are using it with in
    Oracle...
    I need to use the information it generates.
    here is what I have so far...
    try
    Class.forName ("oracle.jdbc.driver.OracleDriver");
    DriverManager.registerDriver (new
    oracle.jdbc.driver.OracleDriver());
    oracle.jdbc.driver.OracleConnection conn =
    (oracle.jdbc.driver.OracleConnection)
    DriverManager.getConnection ("jdbc:oracle:thin:@--","NA","NA");
    // SQL92 SyntaxCallableStatement
    oracle.jdbc.driver.OracleCallableStatement cstmt =
    (oracle.jdbc.driver.OracleCallableStatement)conn.prepareCall
    ("{call cbmd_proposal_PKG.DefaultTerms (?,?,?,?)}" ) ;
    cstmt.setString(1,"5118");
    cstmt.setString(2,"3");
    cstmt.registerOutParameter
    (2,oracle.jdbc.driver.OracleTypes.NUMBER);
    cstmt.registerOutParameter
    (1,oracle.jdbc.driver.OracleTypes.ARRAY,"");
    cstmt.execute();
    catch(Exception e)
    System.err.println(e.toString());
    e.printStackTrace();
    null

    The "X" in the second registerOutParameter is the type name which
    you have created in oracle DB.
    eg. if you have created a nested table
    create Type integer_table is table of number(10);
    then "X" = "INTEGER_TABLE" and it has to be in caps
    and other thing to keep in mind is that it only works with nested
    table or varray and not with pl/sql table.
    Al Pivonka (guest) wrote:
    : How can I pass pl/sql record in and out
    : and pl/sql tables in out thru a pl/sql procedure using jdbc
    with
    : the zip file of 816classes12.zip...
    : I have tried everything I know...
    : I know the procedure is working, others are using it with in
    : Oracle...
    : I need to use the information it generates.
    : here is what I have so far...
    : try
    : Class.forName ("oracle.jdbc.driver.OracleDriver");
    : DriverManager.registerDriver (new
    : oracle.jdbc.driver.OracleDriver());
    : oracle.jdbc.driver.OracleConnection conn =
    : (oracle.jdbc.driver.OracleConnection
    : DriverManager.getConnection
    ("jdbc:oracle:thin:@--","NA","NA");
    : // SQL92 SyntaxCallableStatement
    : oracle.jdbc.driver.OracleCallableStatement cstmt =
    : (oracle.jdbc.driver.OracleCallableStatement)conn.prepareCall
    : ("{call cbmd_proposal_PKG.DefaultTerms (?,?,?,?)}" ) ;
    : cstmt.setString(1,"5118");
    : cstmt.setString(2,"3");
    : cstmt.registerOutParameter
    : (2,oracle.jdbc.driver.OracleTypes.NUMBER);
    : cstmt.registerOutParameter
    (1,oracle.jdbc.driver.OracleTypes.ARRAY,"X");
    : cstmt.execute();
    : catch(Exception e)
    : System.err.println(e.toString());
    : e.printStackTrace();
    : The "X" in the second registerOutParameter is still unknown to
    : me.
    : The JavaDoc for the
    OracleCallableStatement.registerOutParameter
    : is not clear.
    : Can any One help simplify this...
    : Thanks
    null

  • How do I set miminum # of connections for pool with Oracle and Tomcat?

    Hi,
    I can't seem to find any attribute to initialize the number of connections for my connection pool. Here is my current context.xml file under my /App1 directory:
    <Context path="/App1" docBase="App1"
    debug="5" reloadable="true" crossContext="true">
    <Resource name="App1ConnectionPool" auth="Container"
    type="oracle.jdbc.pool.OracleDataSource"
    driverClassName="oracle.jdbc.driver.OracleDriver"
    factory="oracle.jdbc.pool.OracleDataSourceFactory"
    url="jdbc:oracle:thin:@127.0.0.1:1521:oddjob"
    user="app1" password="app1" />
    </Context>
    I've been googling and reading forums, but haven't found a way to establish the minimum number of connections. I've tried all sorts of parameters like InitialLimit, MinLimit, MinActive, etc, with no success.
    Here is some sample code that I am testing:
    package web;
    import oracle.jdbc.pool.OracleDataSource;
    import oracle.jdbc.OracleConnection;
    import javax.naming.*;
    import java.sql.SQLException;
    import java.sql.ResultSet;
    import java.sql.Statement;
    import java.util.Properties;
    public class ConnectionPool {
    String message = "Not Connected";
    public void init() {
    OracleConnection conn = null;
    ResultSet rst = null;
    Statement stmt = null;
    try {
    Context initContext = new InitialContext();
    Context envContext = (Context) initContext.lookup("java:/comp/env");
    OracleDataSource ds = (OracleDataSource) envContext.lookup("App1ConnectionPool");
    message = "Here.";
         String user = ds.getUser();
    if (envContext == null)
    throw new Exception("Error: No Context");
    if (ds == null)
    throw new Exception("Error: No DataSource");
    if (ds != null) {
    message = "Trying to connect...";
    conn = (OracleConnection) ds.getConnection();
    Properties prop = new Properties();
    prop.put("PROXY_USER_NAME", "adavey/xxx");
    if (conn != null) {
    message = "Got Connection " + conn.toString() + ", ";
              conn.openProxySession(OracleConnection.PROXYTYPE_USER_NAME,prop);
    stmt = conn.createStatement();
    rst = stmt.executeQuery("SELECT username, server from v$session where username is not null");
    while (rst.next()) {
    message = "DS User: " + user + "; DB User: " + rst.getString(1) + "; Server: " + rst.getString(2);
    rst.close();
    rst = null;
    stmt.close();
    stmt = null;
    conn.close(); // Return to connection pool
    conn = null; // Make sure we don't close it twice
    } catch (Exception e) {
    e.printStackTrace();
    } finally {
    // Always make sure result sets and statements are closed,
    // and the connection is returned to the pool
    if (rst != null) {
    try {
    rst.close();
    } catch (SQLException e) {
    rst = null;
    if (stmt != null) {
    try {
    stmt.close();
    } catch (SQLException e) {
    stmt = null;
    if (conn != null) {
    try {
    conn.close();
    } catch (SQLException e) {
    conn = null;
    public String getMessage() {
    return message;
    I'm using a utility to repeatedly call a JSP page that uses this class and displays the message variable. This utility allows me to specify the number of concurrent web requests and an overall number of requests to try. While that is running, I look at V$SESSION in Oracle and occassionaly, I will see a brief entry for app1 or adavey depending on the timing of my query and how far along the code has processed in this example. So it seems that I am only using one connection at a time and not a true connection pool.
    Is it possible that I need to use the oci driver instead of the thin driver? I've looked at the javadoc for oci and the OCIConnectionPool has a setPoolConfig method to set initial, min and max connections. However, it appears that this can only be set via Java code and not as a parameter in my context.xml resource file. If I have to set it each time I get a database connection, it seems like it sort of defeats the purpose of having Tomcat maintain the connection pool for me and that I need to implement my own connection pool. I'm a newbie to this technology so I really don't want to go this route.
    Any advice on setting up a proper connection pool that works with Tomcat and Oracle proxy sessions would be greatly appreciated.
    Thanks,
    Alan

    Well I did some more experiments and I am able to at least create a connection pool within my example code:
    package web;
    import oracle.jdbc.pool.OracleDataSource;
    import oracle.jdbc.OracleConnection;
    import javax.naming.*;
    import java.sql.SQLException;
    import java.sql.ResultSet;
    import java.sql.Statement;
    import java.util.Properties;
    public class ConnectionPool {
    String message = "Not Connected";
    public void init() {
    OracleConnection conn = null;
    ResultSet rst = null;
    Statement stmt = null;
    try {
    Context initContext = new InitialContext();
    Context envContext = (Context) initContext.lookup("java:/comp/env");
    OracleDataSource ds = (OracleDataSource) envContext.lookup("App1ConnectionPool");
    message = "Here.";
         String user = ds.getUser();
    if (envContext == null)
    throw new Exception("Error: No Context");
    if (ds == null)
    throw new Exception("Error: No DataSource");
    if (ds != null) {
    message = "Trying to connect...";
    boolean cache_enabled = ds.getConnectionCachingEnabled();
    if (!cache_enabled){
    ds.setConnectionCachingEnabled(true);
    Properties cacheProps = new Properties();
    cacheProps.put("InitialLimit","5");
         cacheProps.put("MinLimit","5");
    cacheProps.put("MaxLimit","10");
    ds.setConnectionCacheProperties(cacheProps);
              conn = (OracleConnection) ds.getConnection();
    Properties prop = new Properties();
    prop.put("PROXY_USER_NAME", "adavey/xyz");
    if (conn != null) {
    message = "Got Connection " + conn.toString() + ", ";
              conn.openProxySession(OracleConnection.PROXYTYPE_USER_NAME,prop);
    stmt = conn.createStatement();
    //rst = stmt.executeQuery("SELECT 'Success obtaining connection' FROM DUAL");
    rst = stmt.executeQuery("SELECT user, SYS_CONTEXT ('USERENV', 'SESSION_USER') from dual");
    while (rst.next()) {
    message = "DS User: " + user + "; DB User: " + rst.getString(1) + "; sys_context: " + rst.getString(2);
    message += "; Was cache enabled?: " + cache_enabled;
    rst.close();
    rst = null;
    stmt.close();
    stmt = null;
    conn.close(OracleConnection.PROXY_SESSION); // Return to connection pool
    conn = null; // Make sure we don't close it twice
    } catch (Exception e) {
    e.printStackTrace();
    } finally {
    // Always make sure result sets and statements are closed,
    // and the connection is returned to the pool
    if (rst != null) {
    try {
    rst.close();
    } catch (SQLException e) {
    rst = null;
    if (stmt != null) {
    try {
    stmt.close();
    } catch (SQLException e) {
    stmt = null;
    if (conn != null) {
    try {
    conn.close();
    } catch (SQLException e) {
    conn = null;
    public String getMessage() {
    return message;
    In my context.xml file, I tried to specify the same Connection Cache Properties as attributes, but no luck:
    <Context path="/App1" docBase="App1"
    debug="5" reloadable="true" crossContext="true">
    <Resource name="App1ConnectionPool" auth="Container"
    type="oracle.jdbc.pool.OracleDataSource"
    driverClassName="oracle.jdbc.OracleDriver"
    factory="oracle.jdbc.pool.OracleDataSourceFactory"
    url="jdbc:oracle:thin:@127.0.0.1:1521:oddjob"
    user="app1" password="app1"
    ConnectionCachingEnabled="1" MinLimit="5" MaxLimit="20"/>
    </Context>
    These attributes seemed to have no effect:
    ConnectionCachingEnabled="1" ; also tried "true"
    MinLimit="5"
    MaxLimit="20"
    So basically if I could find some way to get these attributes set within the context.xml file instead of my code, I would be a happy developer :-)
    Oh well, it's almost Miller time here on the east coast. Maybe a few beers will help me find the solution I'm looking for.

  • Problem with store ResultSet and show result in table

    Hi, I'm kind of new in ADF, I need to store ResultSet and show result in table-component. I have two problems:
    1) I get my ResultSet by calling callStoredProcedure(...) and this returns actually ref_cursor as ResultSet.
    When I try to println() contains of this result set in this method - it works OK (commented part),
    but when I want to println() somewhere else (eg. in retrieveRefCursor() method) it doesn't work.
    The problem is that the scrollability of the ResultSet is lost - it becomes a TYPE_FORWARD_ONLY ResultSet.
    Is there any way to store data from ref_cursor for a long time?
    2) My second problem is "store any result set and show this data in table". I have tried use method storeNewResultSet() but
    without result (table contains only "No rows yet" and everything seems to be OK - no exception, no warning, no error...).
    I have tried to call this method with ResultSet from select on dbs (without resultSet as ref_cursor ) - no result with createRowFromResultSet(),
    storeNewResultSet(), setUserDataForCollection()...
    I've tried a lot of ways to do this, but it doesn't work. I really don't know how to make it so it can work.
    Thanks for your help.
    ADF BC, JDev 11.1.1.0
    This is my code from ViewObjectImpl
    package tp.model ;
    import com.sun.jmx.mbeanserver.MetaData ;
    import java.sql.CallableStatement ;
    import java.sql.Connection ;
    import java.sql.PreparedStatement ;
    import java.sql.ResultSet ;
    import java.sql.ResultSetMetaData ;
    import java.sql.SQLException ;
    import java.sql.Statement ;
    import java.sql.Types ;
    import oracle.jbo.JboException ;
    import oracle.jbo.server.SQLBuilder ;
    import oracle.jbo.server.ViewObjectImpl ;
    import oracle.jbo.server.ViewRowImpl ;
    import oracle.jbo.server.ViewRowSetImpl ;
    import oracle.jdbc.OracleCallableStatement ;
    import oracle.jdbc.OracleConnection ;
    import oracle.jdbc.OracleTypes ;
    public class Profiles1ViewImpl extends ViewObjectImpl {
        private static final String SQL_STM = "begin Pkg_profile.get_profile_list(?,?,?,?);end;" ;
        public Profiles1ViewImpl () {
        /* 0. */
        protected void create () {
            getViewDef ().setQuery ( null ) ;
            getViewDef ().setSelectClause ( null ) ;
            setQuery ( null ) ;
        public Connection getCurrentConnection () throws SQLException {
            // Note that we never execute this statement, so no commit really happens
            Connection conn = null ;
            PreparedStatement st = getDBTransaction ().createPreparedStatement ( "commit" , 1 ) ;
            conn = st.getConnection () ;
            st.close () ;
            return conn ;
        /* 1. */
        protected void executeQueryForCollection ( Object qc , Object[] params , int numUserParams ) {
            storeNewResultSet ( qc , retrieveRefCursor ( qc , params ) ) ;
            // callStoredProcedure ( qc , SQL_STM ) ;
            super.executeQueryForCollection ( qc , params , numUserParams ) ;
        /* 2. */
        private ResultSet retrieveRefCursor ( Object qc , Object[] params ) {
            ResultSet rs = null ;
            rs = callStoredProcedure ( qc , SQL_STM ) ;
            return rs ;
        /* 3. */
        public ResultSet callStoredProcedure ( Object qc , String stmt ) {
            CallableStatement st = null ;
            ResultSet refCurResultSet = null ;
            try {
                st = getDBTransaction ().createCallableStatement ( stmt , 0 ) ; // call 
                st.setObject ( 1 , 571 ) ; //set id of my record to 571
                st.registerOutParameter ( 2 , OracleTypes.CURSOR ) ; // my ref_cursor
                st.registerOutParameter ( 3 , Types.NUMERIC ) ;
                st.registerOutParameter ( 4 , Types.VARCHAR ) ;
                st.execute () ; //executeUpdate
                System.out.println ( "Numeric " + st.getObject ( 3 ) ) ;
                System.out.println ( "Varchar " + st.getObject ( 4 ) ) ;
                refCurResultSet = ( ResultSet ) st.getObject ( 2 ) ; //set Cursoru to ResultSet
                //   setUserDataForCollection(qc, refCurResultSet); //don't work
                //   createRowFromResultSet ( qc , refCurResultSet ) ; //don't work
                /* this works but only one-time call - so my resultSet(cursor) really have a data
                while ( refCurResultSet.next () ) {
                    String nameProfile = refCurResultSet.getString ( 2 ) ;
                    System.out.println ( "Name profile: " + nameProfile ) ;
                return refCurResultSet ;
            } catch ( SQLException e ) {
                System.out.println ( "sql ex " + e ) ;
                throw new JboException ( e ) ;
            } finally {
                if ( st != null ) {
                    try {
                        st.close () ; // 7. Close the statement
                    } catch ( SQLException e ) {
                        System.out.println ( "sql exx2 " + e ) ;
        /* 4. Store a new result set in the query-collection-private user-data context */
        private void storeNewResultSet ( Object qc , ResultSet rs ) {
            ResultSet existingRs = getResultSet ( qc ) ;
            // If this query collection is getting reused, close out any previous rowset
            if ( existingRs != null ) {
                try {
                   existingRs.close () ;
                } catch ( SQLException s ) {
                    System.out.println ( "sql err " + s ) ;
            setUserDataForCollection ( qc , rs ) ; //should store my result set
            hasNextForCollection ( qc ) ; // Prime the pump with the first row.
        /*  5. Retrieve the result set wrapper from the query-collection user-data      */
        private ResultSet getResultSet ( Object qc ) {
            return ( ResultSet ) getUserDataForCollection ( qc ) ;
        // createRowFromResultSet - overridden for custom java data source support - also doesn't work
       protected ViewRowImpl createRowFromResultSet ( Object qc , ResultSet resultSet ) {
            ViewRowImpl value = super.createRowFromResultSet ( qc , resultSet ) ;
            return value ;
    }

    Hi I have the same problem like you ...
    My SQL Definition:
    CREATE OR REPLACE TYPE RMSPRD.NB_TAB_STOREDATA is table of NB_STOREDATA_REC
    CREATE OR REPLACE TYPE RMSPRD.NB_STOREDATA_REC AS OBJECT (
       v_title            VARCHAR2(100),
       v_store            VARCHAR2(50),
       v_sales            NUMBER(20,4),
       v_cost             NUMBER(20,4),
       v_units            NUMBER(12,4),
       v_margin           NUMBER(6,2),
       v_ly_sales         NUMBER(20,4),
       v_ly_cost          NUMBER(20,4),
       v_ly_units         NUMBER(12,4),
       v_ly_margin        NUMBER(6,2),
       v_sales_variance   NUMBER(6,2)
    CREATE OR REPLACE PACKAGE RMSPRD.NB_SALES_DATA
    AS
    v_sales_format_tab   nb_tab_storedata;
    FUNCTION sales_data_by_format_gen (
          key_value         IN       VARCHAR2,
          l_to_date         IN       DATE DEFAULT SYSDATE-1,
          l_from_date       IN       DATE DEFAULT TRUNC (SYSDATE, 'YYYY')
          RETURN nb_tab_storedata;
    I have a PLSQL function .. that will return table ..
    when i use this in sql developer it is working fine....
    select * from table (NB_SALES_DATA.sales_data_by_format_gen('TSC',
                                        '05-Aug-2012',
                                        '01-Aug-2012') )
    it returning table format record.
    I am not able to call from VO object. ...
    Hope you can help me .. please tell me step by step process...
    protected Object callStoredFunction(int sqlReturnType, String stmt,
    Object[] bindVars) {
    System.out.println("--> 1");
    CallableStatement st = null;
    try {
    st = getDBTransaction().createCallableStatement("begin ? := " +"NB_SALES_DATA.sales_data_by_format_gen('TSC','05-Aug-2012','01-Aug-2012') ; end;", 0);
    System.out.println("--> 2");
    st.executeUpdate();
    System.out.println("--> 3");
    return st.getObject(1);
    catch (SQLException e) {
    e.printStackTrace();
    throw new JboException(e);

  • Use of ODP and casual application freeze-up

    Hello,
    I'm writing a small application which connects to MS SQL 2000 and Oracle 10.2.0.1.0 and transports data between them.
    When it comes to biggest table which is called CLANKY, there is 11892 records with clob columns and fulltext index over it.
    But during the transfer often happen that application stops on OracleCommand.ExecuteNonQuery() and will not continue again. There is no specification of situation when it happen. It can happen on command which inserts, or on command launching stored procedure which retrieves ID of last inserted record through a trigger code which is storing it in variable. Sometimes it doesn't happen during transfer of CLANKY table, but most often there. Sometimes the application ends properly.
    I've tried lot of things to make sure I'm doing everything right, but nothing help. I was closing and disposing all OracleCommands but it make it (subjectively) worse. I don't think that I'm doing something so complicated.
    In memory I'm holding only Dictionary<int,int> of remapped ids.
    Here is the code for transfering CLANKY table.
    private bool transferTableClanky(SqlConnection sqlSource, OracleConnection oracleTarget, Dictionary<int, int> autoriMap, Dictionary<int, int> jiniAutoriMap, Dictionary<int, int> zdrojeMap, Dictionary<int, int> clankyMap)
    oracleTarget.Close();
    oracleTarget.Open();
    SqlCommand command = new SqlCommand
    ("SELECT id_clanku, nazev, popisek, clanek, datum_vlozeni, datum_zmeny, je_odkaz, odkaz, id_autora, "
    + "zobrazit_jineho_autora, id_jineho_autora, zobrazit_zdroj, id_zdroje, obr_nahled, obr_nahled_text, "
    + "ts FROM clanky;"
    , sqlSource);
    SqlDataReader reader = command.ExecuteReader();
    log("Start:" + DateTime.Now.ToString());
    int count = 0;
    while (reader.Read())
    count++;
    int id_clanku = reader.GetInt32(0);
    string nazev = reader.GetString(1);
    string popisek = "";
    if (!reader.IsDBNull(2))
    popisek = reader.GetString(2);
    string clanek = "";
    if (!reader.IsDBNull(3))
    clanek = reader.GetString(3);
    DateTime datum_vlozeni = reader.GetDateTime(4);
    DateTime datum_zmeny = reader.GetDateTime(5);
    bool je_odkaz = reader.GetBoolean(6);
    string odkaz = reader.GetString(7);
    int id_autora = -1;
    if (!reader.IsDBNull(8))
    id_autora = reader.GetInt32(8);
    id_autora = autoriMap[id_autora];
    bool zobrazit_jineho_autora = reader.GetBoolean(9);
    int id_jineho_autora = -1;
    if (!reader.IsDBNull(10))
    id_jineho_autora = reader.GetInt32(10);
    id_jineho_autora = jiniAutoriMap[id_jineho_autora];
    bool zobrazit_zdroj = reader.GetBoolean(11);
    int id_zdroje = -1;
    if (!reader.IsDBNull(12))
    id_zdroje = reader.GetInt32(12);
    id_zdroje = zdrojeMap[id_zdroje];
    string obr_nahled = reader.GetString(13);
    string obr_nahled_text = reader.GetString(14);
    int ts = -1;
    if (!reader.IsDBNull(15))
    ts = reader.GetBoolean(15) ? 1 : 0;
    OracleCommand oraCmd = new OracleCommand(
    "INSERT INTO clanky(nazev, popisek, clanek, datum_vlozeni, datum_zmeny, je_odkaz, odkaz, id_autora, "
    + "zobrazit_jineho_autora, id_jineho_autora, zobrazit_zdroj, id_zdroje, obr_nahled, obr_nahled_text, "
    + "ts) "
    + "VALUES (:nazev, :popisek, :clanek, :datum_vlozeni, :datum_zmeny, :je_odkaz, :odkaz, :id_autora, "
    + ":zobrazit_jineho_autora, :id_jineho_autora, :zobrazit_zdroj, :id_zdroje, :obr_nahled, :obr_nahled_text, "
    + ":ts)", oracleTarget);
    oraCmd.Parameters.Add("nazev", OracleDbType.Varchar2, nazev, ParameterDirection.Input);
    oraCmd.Parameters.Add("popisek", OracleDbType.Varchar2, popisek, ParameterDirection.Input);
    OracleClob oraClob = new OracleClob(oracleTarget);
    char[] clanekArr = clanek.ToCharArray();
    oraClob.Write(clanekArr, 0, clanekArr.Length);
    oraCmd.Parameters.Add("clanek", OracleDbType.Clob, oraClob, ParameterDirection.Input);
    oraCmd.Parameters.Add("datum_vlozeni", OracleDbType.Date, new OracleDate(datum_vlozeni), ParameterDirection.Input);
    oraCmd.Parameters.Add("datum_zmeny", OracleDbType.Date, new OracleDate(datum_zmeny), ParameterDirection.Input);
    oraCmd.Parameters.Add("je_odkaz", OracleDbType.Decimal, new OracleDecimal(je_odkaz ? 1 : 0), ParameterDirection.Input);
    oraCmd.Parameters.Add("odkaz", OracleDbType.Varchar2, odkaz, ParameterDirection.Input);
    if (id_autora == -1)
    oraCmd.Parameters.Add("id_autora", OracleDbType.Decimal, null, ParameterDirection.Input);
    else
    oraCmd.Parameters.Add("id_autora", OracleDbType.Decimal, new OracleDecimal(id_autora), ParameterDirection.Input);
    oraCmd.Parameters.Add("zobrazit_jineho_autora", OracleDbType.Decimal, new OracleDecimal(zobrazit_jineho_autora ? 1 : 0), ParameterDirection.Input);
    if (id_jineho_autora == -1)
    oraCmd.Parameters.Add("id_jineho_autora", OracleDbType.Decimal, null, ParameterDirection.Input);
    else
    oraCmd.Parameters.Add("id_jineho_autora", OracleDbType.Decimal, new OracleDecimal(id_jineho_autora), ParameterDirection.Input);
    oraCmd.Parameters.Add("zobrazit_zdroj", OracleDbType.Decimal, new OracleDecimal(zobrazit_zdroj ? 1 : 0), ParameterDirection.Input);
    if (id_zdroje == -1)
    oraCmd.Parameters.Add("id_zdroje", OracleDbType.Decimal, null, ParameterDirection.Input);
    else
    oraCmd.Parameters.Add("id_zdroje", OracleDbType.Decimal, new OracleDecimal(id_zdroje), ParameterDirection.Input);
    oraCmd.Parameters.Add("obr_nahled", OracleDbType.Varchar2, obr_nahled, ParameterDirection.Input);
    oraCmd.Parameters.Add("obr_nahled_text", OracleDbType.Varchar2, obr_nahled_text, ParameterDirection.Input);
    if (ts == -1)
    oraCmd.Parameters.Add("ts", OracleDbType.Decimal, null, ParameterDirection.Input);
    else
    oraCmd.Parameters.Add("ts", OracleDbType.Decimal, new OracleDecimal(ts), ParameterDirection.Input);
    oraCmd.ExecuteNonQuery();
    clankyMap[id_clanku] = getIdentity(oracleTarget);
    this.tickCallback();
    oraCmd.Dispose();
    reader.Close();
    log("End with " + count + " of records:" + DateTime.Now.ToString());
    return true;
    }

    I think it's caused by Oracle.DataAccess connectors. I've used a System.Data.OracleClient connector by Microsoft and it works well. And the code is doing the same INSERT and stored procedure call.
    What exactly do you mean with tracing the session? Dou you think it's locked-up on the database side? :o

  • New OracleConnection hangs in VS 2005 debug mode

    Client 10.2.3, ODT 10.2.0.21 for Vista, VS2005sp1, Vista Sp1
    Everything has been working great until I tried to debug a service for the first time since last week. Now no matter what I do, a call to create a new OracleConnection locks up the VS debugger and my only recourse is to stop the debugger - pausing fails.
    If I run the same compiled project outside of vshost (Ctrl-F5) it works perfectly. I have reinstalled the Oracle client without success. Also, I can run another project that connects to the database with debugging successfully. To limit the intrusion of early code causing an issue, I tried to create a connection at the start of Main() and that hangs.
    Has anyone seen this occur or have ideas on what I can try to recover my debugging capability.
    Thanks!!!

    Further notes: If I enable unmanaged code debugging for the startup project (console app), it works. I notice that the next managed dll to be loaded after its normal hang spot is System.EnterpriseServices. I wonder if that is the cause or the oracle non-managed dll loading...

  • Cannot connect to Oracle thru OracleConnection

    Hi,
    I'm new somewhat new to this forum, so fwiw, I have searched through this forum trying to find a similar solution to this problem, but to no avail, so I figured I would post it. If this is a FAQ, then my apologies and point me there!
    I recently did some housekeeping on my pc and uninstalled OracleXe (using a doc i found on the web) and then reinstalled Oracle XE.
    According to the registry HKEY_LOCAL_MACHINE\SOFTWARE\ORACLE\KEY_XE\ODP.NET\Version, I'm using the OracleDataAccess.dll 10.2.100 to connect.
    my version of XE, again looking at the registry here, HKEY_LOCAL_MACHINE\SOFTWARE\ORACLE\KEY_XE\Version is 10.2.0.1.0
    I have a project which has been running for sometime and it no longer works, I decided to create a simple console sample to see if the problem could be isolated. Here's a snippet of it for ref, only thing left out is curly braces, main and namespaces.
    // i have this in tnsnames.ora and set this up with database web page
    strin connStr = "Data Source=HR;User Id=hr;Password=hr;";
    OracleConnection ocn = new OracleConnection( connStr );
    try {
    ocn.Open();
    catch ( OracleException oex ){
    Console.WriteLine("error was: {0}", oex.Message );
    When i run this code an exception is thrown when Open is called, but the exceptions message is blank!
    I've tried a few things to figure this out. I checked if I could connect using sqlplus > hr/hr@HR and that works fine. Thinking it might be GAC related, I took a sneak peek at the GAC and I do see a 10.2.100 dll in there as well as the various resource dlls for that version. In addtion there is a Policy 9.2 Oracle.DataAccess 10.2.100 too.
    I turned on tracing, set values in the odp.net registry entry (under Oracle\KEY_XE
    I set tracelevel to 1 and traceoption to 0. The file it emits contains entries and exits and some warn entries..
    Any ideas as to what might be wrong ?
    thanks for any help you can provide,
    Sincerely,
    J

    update: Solved!
    Thanks for the help.
    I guess in the end, it was that a reboot was required because
    when I came in today and gave it a run through, it was doing considerably better.
    Ming, thank you,
    it turned out that this was not the problem.
    thanks,
    sincerely,
    J__

  • Performance problems with combobox and datasource

    We have a perfomance problem, when we are connecting a datatable object or something like this to a datasource property of a combobox. Below you find the source code. The SQL-Statement reads about 40000 rows and the result (all 40000) should be listed in the combobox. There is duration about 30 second before this process has finished. Any suggestions?
    Dim ds As New DataSet
    strSQL = "Select * from am.city"
    conn = New Oracle.DataAccess.Client.OracleConnection(Configuration.ConfigurationSettings.AppSettings("conORA"))
    comm = New Oracle.DataAccess.Client.OracleCommand(strSQL)
    da = New Oracle.DataAccess.Client.OracleDataAdapter(strSQL, conn)
    conn.Open()
    da.Fill(ds)
    conn.Close()
    Dim dt As New DataTable
    dt = ds.Tables(0)
    ComboBox1.DataSource = dt
    ComboBox1.ValueMember = dv.Table.Columns("id").ColumnName
    ComboBox1.DisplayMember = dv.Table.Columns("city").ColumnName

    But how long does it take to fill the DataTable?
    I can fill a 40000 row datatable in under 4 seconds.
    DataBinding a combo box to that many rows is pretty expensive, and not normally recommended.
    David
    Dim strConnection As String = "Data Source=oracle;User ID=scott;Password=tiger;"
    Dim conn As OracleConnection = New OracleConnection(strConnection)
    conn.Open()
    Dim cmd As New OracleCommand("select * from (select * from all_objects union all select * from all_objects) where rownum <= 40000", conn)
    Dim ds As New DataSet()
    Dim da As New OracleDataAdapter(cmd)
    Dim begin As Date = Now
    da.Fill(ds)
    Console.WriteLine(ds.Tables(0).Rows.Count & " rows loaded in " & Now.Subtract(begin).TotalSeconds & " seconds")
    outputs
    40000 rows loaded in 3.734375 seconds

Maybe you are looking for

  • Files NOT deleted from hard drive

    iTunes will not send files to my recycle bin, only from remove them from my library. I have 2 computers with 7.0.2.16 running. One will ask me if I want to move files to my recycle bin, which it will then do. The other won't ask and won't delete them

  • Using PDF files with Flash

    With Flash Professional 8, can I import or attach a standard PDF file to a flash document so that it can be downloaded off the web?

  • Order that podcasts download is not consistent.

    I have noticed that when I click "get all" on the first podcast subscribed to, the podcast episodes download from top to bottom (most-recent to least-recent). But for any other podcast subscribed to (from the second in the list to the last in the lis

  • Tracking Video Clip to JPG BG Image

    I am creating an animation scene with a JPG background image (replicating a website) in which the camera moves throughout the webpage (or jpeg).  I also have smaller video clips over the jpg that play and stop and I would like to track these to the j

  • How do i edit  need to fix some errors

    how do i edit my file in adobe need to fix some errors