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

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

                  相关文档推荐

                  What does SQL clause quot;GROUP BY 1quot; mean?(SQL 子句“GROUP BY 1是什么意思?意思是?)
                  Why Mysql#39;s Group By and Oracle#39;s Group by behaviours are different(为什么 Mysql 的 Group By 和 Oracle 的 Group by 行为不同)
                  How to select the first row for each group in MySQL?(如何在MySQL中为每个组选择第一行?)
                  MySQL - Fetching lowest value(MySQL - 获取最低值)
                  Add and link mysql libraries in a cmakelist.txt(在 cmakelist.txt 中添加和链接 mysql 库)
                  What is a good database design (schema) for a attendance database?(考勤数据库的良好数据库设计(架构)是什么?)
                    <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>