• Does your Oracle database run on a multi-processor machine?

    If not, trying to overlap your queries will not result in a performance gain, rather, you would most likely substantially slow the overall throughput.

  • Are the interface libraries to your database certified for multi-threaded use?

    That is, are the libraries supplied by Oracle that DBI will call to interface to the DBM certified for multi-threaded use?

    Many such DBM interface libraries internally use the process id of the caller to key intermediate storage. If multiple threads from the same process start calling with different, overlapping queries, the internal storage can become corrupted.

    Neither of these are limitation of Perl, just facts of life you will have to verify.


    If, having verified that your RDBMS and interface libraries are capable of supporting multi-threaded calling code, and that your DB server is such that it is able to overlap multiple concurrent queries and produce a performace increase, then you will have to verify that the DBD driver that you connect through with DBI is capable of multi-threaded use.

    Finally, DBI itself is not certified as thread-safe, so if you get problems, you'll have noone to turn to for help.

    Overall, it seems to me that listening to those offering "known-to-work" alternatives, rather than being less than gracious of their attempts to help, might save you a lot of heartache.


    Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
    Lingua non convalesco, consenesco et abolesco. -- Rule 1 has a caveat! -- Who broke the cabal?
    "Science is about questioning the status quo. Questioning authority".
    The "good enough" maybe good enough for the now, and perfection maybe unobtainable, but that should not preclude us from striving for perfection, when time, circumstance or desire allow.

    In reply to Re: Multithreading and DBI by BrowserUk
    in thread Multithreading and DBI by knsridhar

    Title:
    Use:  <p> text here (a paragraph) </p>
    and:  <code> code here </code>
    to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.