Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Mailing Lists -> Oracle-L -> RE: Select from dual return 3 rows !

RE: Select from dual return 3 rows !

From: Rudy Zung <Rudy.Zung_at_efi.com>
Date: Tue, 8 Nov 2005 16:14:23 -0500
Message-ID: <87F7A09D4DAF4C46A1EC7BFBF85047F3CFF1DA@pghexmb02.efi.internal>

 

Wow! I made DUAL work like a FIFO queue! Oracle's definitely done some fancy dancing on DUAL in the recent versions (per Jared's comments that single-row-only DUAL going back to 817.)  

Logged in as SYS; select from DUAL, got 'X'. Insert into DUAL values ('A'); select from DUAL, got 'X'. Insert into DUAL values ('B'); select from DUAL, got 'X'.

Delete from DUAL; select from DUAL, got 'A'. (this is kind of creepy for me.)
Delete from DUAL; select from DUAL, got 'B'.
Delete from DUAL; select from DUAL, got nothing.
Fearing developers banging down the non-existent door of my cubicle if this transaction got committed: rollback.
Select from DUAL, got back original 'X'.  

This was on 10.1.0.2.  

...Rudy    

	-----Original Message-----
	From: Jared Still [mailto:jkstill_at_gmail.com] 
	Sent: Tuesday, November 08, 2005 3:46 PM
	To: Rudy Zung
	Cc: frank4oraclel_at_yahoo.dk; ORACLE-L;
frank.hansen_at_kriminalforsorgen.dk
	Subject: Re: Select from dual return 3 rows !
	
	
	On 11/8/05, Rudy Zung <Rudy.Zung_at_efi.com> wrote: 
	

		DUAL, when you really come down to it, is really just a table
into which Oracle defaults with just a single record. However, because it is just a simple table, additional records can be inserted into it, as you have just discovered.                  

        That is version dependent.         

	At least as far back as 8.1.7.4, there can
	be only one row in sys.dual.
	
	Try it.
	
	
	-- 
	Jared Still
	Certifiable Oracle DBA and Part Time Perl Evangelist
	


--
http://www.freelists.org/webpage/oracle-l
Received on Tue Nov 08 2005 - 15:17:30 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US