D

What is a DUAL table in SQL?

3 viewed last edited 1 month ago
Anonymous
0

I understand its a 1x1 table but i don't see where it is used and what it stands for. Could you please explain it?

Vivekanand Vellanki
0

Take a look at https://en.wikipedia.org/wiki/DUAL_table.


Looks like it is not required - in fact, Teradata does not use it.


This seems to have been introduced as a convenience since SQL queries need to specify a table. Having a dummy table helps run queries like:

select 1+1 from dual;


The link has a more detailed explanation for why Oracle introduced the DUAL table