[Advanced Query] Temporary Tables - ORACLE server

[Advanced Query] Temporary Tables - ORACLE server

  
Hello everyone,

I'm trying to use temporary tables within an advanced query, but with no success.
Here is one of the ways that I tried:

CREATE GLOBAL TEMPORARY TABLE
    TEMP1
ON COMMIT PRESERVE ROWS
AS
    SELECT
        to_date(SYSDATE) COL
    FROM
        DUAL;

SELECT
    *
FROM
    TEMP1;

DROP TABLE TEMP1;


As an Output Structure, I'm using a Record with an attribute of type Text.

Does anyone ever worked with temporary tables in Outsystems over an Oracle database?
  • Service Studio : 5.0.2.51
  • OS : Windows XP Professional SP3
  • DB : Oracle Database 11g Enterprise Edition, 11.2.0.3.0, 64bit Production

Thanks in advance for your effort,
--
R. Saraiva
Hello Ricardo,

Try 
WITH    TEMP1
AS(SELECT to_date(SYSDATE) COL FROM DUAL)
SELECT * FROM TEMP1
Hi there Diogo,

your solution works pretty fine!


Thank you so much,
--
R. Saraiva