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

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

        <legend id='qhJKH'><style id='qhJKH'><dir id='qhJKH'><q id='qhJKH'></q></dir></style></legend>
        <tfoot id='qhJKH'></tfoot>
      1. oracle存储过程中如何创建和使用临时表?

        How to create and use temporary table in oracle stored procedure?(oracle存储过程中如何创建和使用临时表?)
              <tbody id='9NBiN'></tbody>
          1. <tfoot id='9NBiN'></tfoot>
              <bdo id='9NBiN'></bdo><ul id='9NBiN'></ul>
            • <small id='9NBiN'></small><noframes id='9NBiN'>

              <legend id='9NBiN'><style id='9NBiN'><dir id='9NBiN'><q id='9NBiN'></q></dir></style></legend>

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

                  本文介绍了oracle存储过程中如何创建和使用临时表?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                  问题描述

                  我想在存储过程中创建临时表并以相同的方式访问它,但出现ORA-00942:表或视图不存在的错误.以下是我尝试过的程序,

                  I want to create temporary table in stored procedure and access it in the same but I got error that ORA-00942:Table or view does not exists. Following is the procedure that i tried,

                  Create procedure myproc
                    IS
                    stmt varchar2(1000);
                    BEGIN
                    stmt:='CREATE GLOBAL TEMPORARY table temp(list if columns) ON COMMIT DELETE ROWS';
                  
                    execute immediate stmt;
                  
                    insert into temp values('list of column values');
                  
                   END;  
                  

                  这是我以前创建临时表的方式,但出现错误,还有其他方法可以执行此任务吗?

                  This is the way I used to create temporary table but I got error, is there any other way to perform this task?

                  推荐答案

                  只需先创建它(一次,在您的程序之外),然后在您的程序中使用它.您不想(尝试)在每次调用过程时都创建它.

                  Just create it first (once, outside of your procedure), and then use it in your procedure. You don't want to (try to) create it on every call of the procedure.

                  create global temporary table tmp(x clob)
                  on commit delete rows;
                  
                  create or replace procedure...
                  -- use tmp here
                  end;
                  

                  这篇关于oracle存储过程中如何创建和使用临时表?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

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

                  相关文档推荐

                  Oracle PL/SQL - Raise User-Defined Exception With Custom SQLERRM(Oracle PL/SQL - 使用自定义 SQLERRM 引发用户定义的异常)
                  Oracle: is there a tool to trace queries, like Profiler for sql server?(Oracle:是否有跟踪查询的工具,例如用于 sql server 的 Profiler?)
                  SELECT INTO using Oracle(使用 Oracle SELECT INTO)
                  How to handle Day Light Saving in Oracle database(如何在 Oracle 数据库中处理夏令时)
                  PL/SQL - Use quot;Listquot; Variable in Where In Clause(PL/SQL - 使用“列表Where In 子句中的变量)
                  Oracle: Import CSV file(Oracle:导入 CSV 文件)
                    <tbody id='3L1ja'></tbody>
                  • <bdo id='3L1ja'></bdo><ul id='3L1ja'></ul>

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

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