1. <i id='Joipx'><tr id='Joipx'><dt id='Joipx'><q id='Joipx'><span id='Joipx'><b id='Joipx'><form id='Joipx'><ins id='Joipx'></ins><ul id='Joipx'></ul><sub id='Joipx'></sub></form><legend id='Joipx'></legend><bdo id='Joipx'><pre id='Joipx'><center id='Joipx'></center></pre></bdo></b><th id='Joipx'></th></span></q></dt></tr></i><div id='Joipx'><tfoot id='Joipx'></tfoot><dl id='Joipx'><fieldset id='Joipx'></fieldset></dl></div>

    <small id='Joipx'></small><noframes id='Joipx'>

  2. <tfoot id='Joipx'></tfoot>
      <bdo id='Joipx'></bdo><ul id='Joipx'></ul>

  3. <legend id='Joipx'><style id='Joipx'><dir id='Joipx'><q id='Joipx'></q></dir></style></legend>

      Oracle 10 中的本地临时表(适用于存储过程的范围)

      Local Temporary table in Oracle 10 (for the scope of Stored Procedure)(Oracle 10 中的本地临时表(适用于存储过程的范围))
        <i id='BmOhX'><tr id='BmOhX'><dt id='BmOhX'><q id='BmOhX'><span id='BmOhX'><b id='BmOhX'><form id='BmOhX'><ins id='BmOhX'></ins><ul id='BmOhX'></ul><sub id='BmOhX'></sub></form><legend id='BmOhX'></legend><bdo id='BmOhX'><pre id='BmOhX'><center id='BmOhX'></center></pre></bdo></b><th id='BmOhX'></th></span></q></dt></tr></i><div id='BmOhX'><tfoot id='BmOhX'></tfoot><dl id='BmOhX'><fieldset id='BmOhX'></fieldset></dl></div>

        • <legend id='BmOhX'><style id='BmOhX'><dir id='BmOhX'><q id='BmOhX'></q></dir></style></legend>
          <tfoot id='BmOhX'></tfoot>
        • <small id='BmOhX'></small><noframes id='BmOhX'>

              <bdo id='BmOhX'></bdo><ul id='BmOhX'></ul>
                  <tbody id='BmOhX'></tbody>
                本文介绍了Oracle 10 中的本地临时表(适用于存储过程的范围)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                问题描述

                我是 oracle 的新手.我需要在存储过程中处理大量数据.我正在考虑使用临时表.我正在使用连接池并且应用程序是多线程的.

                I am new to oracle. I need to process large amount of data in stored proc. I am considering using Temporary tables. I am using connection pooling and the application is multi-threaded.

                有没有办法创建临时表,每次调用存储过程都创建不同的表实例,这样多个存储过程调用的数据就不会混淆?

                Is there a way to create temporary tables in a way that different table instances are created for every call to the stored procedure, so that data from multiple stored procedure calls does not mix up?

                推荐答案

                您说您是 Oracle 的新手.我猜你已经习惯了 SQL Server,在那里使用临时表是很常见的.Oracle 的工作方式不同,因此不太常见,因为它不太必要.

                You say you are new to Oracle. I'm guessing you are used to SQL Server, where it is quite common to use temporary tables. Oracle works differently so it is less common, because it is less necessary.

                请记住,使用临时表会带来以下开销:

                Bear in mind that using a temporary table imposes the following overheads:

                1. 读取数据以填充临时表
                2. 将临时表数据写入文件
                3. 在进程启动时从临时表读取数据
                1. read data to populate temporary table
                2. write temporary table data to file
                3. read data from temporary table as your process starts

                大部分活动在帮助您完成工作方面毫无用处.一个更好的主意是看看您是否可以在单个操作中完成所有操作,最好是纯 SQL.

                Most of that activity is useless in terms of helping you get stuff done. A better idea is to see if you can do everything in a single action, preferably pure SQL.

                顺便说一下,您提到的连接池引发了另一个问题.处理大量数据的进程不适合在 OLTP 模式下运行.你真的应该考虑启动一个后台(即异步)进程,可能是一个数据库作业,来运行你的存储过程.如果您想定期运行此作业,则尤其如此,因为我们可以使用 DBMS_SCHEDULER 来自动管理此类事情.

                Incidentally, your mention of connection pooling raises another issue. A process munging large amounts of data is not a good candidate for running in an OLTP mode. You really should consider initiating a background (i.e. asysnchronous) process, probably a database job, to run your stored procedure. This is especially true if you want to run this job on a regular basis, because we can use DBMS_SCHEDULER to automate the management of such things.

                这篇关于Oracle 10 中的本地临时表(适用于存储过程的范围)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

                本站部分内容来源互联网,如果有图片或者内容侵犯了您的权益,请联系我们,我们会在确认后第一时间进行删除!

                相关文档推荐

                ibtmp1是非压缩的innodb临时表的独立表空间,通过innodb_temp_data_file_path参数指定文件的路径,文件名和大小,默认配置为ibtmp1:12M:autoextend,也就是说在文件系统磁盘足够的情况下,这个文件大小是可以无限增长的。 为了避免ibtmp1文件无止境的暴涨导致
                SQL query to group by day(按天分组的 SQL 查询)
                What does SQL clause quot;GROUP BY 1quot; mean?(SQL 子句“GROUP BY 1是什么意思?意思是?)
                MySQL groupwise MAX() returns unexpected results(MySQL groupwise MAX() 返回意外结果)
                MySQL SELECT most frequent by group(MySQL SELECT 按组最频繁)
                Include missing months in Group By query(在 Group By 查询中包含缺失的月份)
                    <tbody id='euxEc'></tbody>
                  <tfoot id='euxEc'></tfoot>
                1. <small id='euxEc'></small><noframes id='euxEc'>

                    <i id='euxEc'><tr id='euxEc'><dt id='euxEc'><q id='euxEc'><span id='euxEc'><b id='euxEc'><form id='euxEc'><ins id='euxEc'></ins><ul id='euxEc'></ul><sub id='euxEc'></sub></form><legend id='euxEc'></legend><bdo id='euxEc'><pre id='euxEc'><center id='euxEc'></center></pre></bdo></b><th id='euxEc'></th></span></q></dt></tr></i><div id='euxEc'><tfoot id='euxEc'></tfoot><dl id='euxEc'><fieldset id='euxEc'></fieldset></dl></div>
                          <bdo id='euxEc'></bdo><ul id='euxEc'></ul>
                          <legend id='euxEc'><style id='euxEc'><dir id='euxEc'><q id='euxEc'></q></dir></style></legend>