Home » RDBMS Server » Performance Tuning » Difference between two query
Difference between two query [message #204309] Mon, 20 November 2006 02:00 Go to next message
juliee_jitu
Messages: 8
Registered: July 2006
Junior Member
Hi,
Please tell me
Is there any thing difference between this two queries ?
as the result is coming same for both the query.

where can i use this query ??

SELECT   nme, dptname
    FROM emp LEFT JOIN dept ON emp.dpt_id = dept.dpt_id
ORDER BY nme DESC



SELECT   nme, dptname
    FROM emp, dept
   WHERE emp.dpt_id = dept.dpt_id(+)
ORDER BY nme DESC


The result -->

nme, dptname
=========================
bungle, sales
Rod, hr
NoDept,
Jane, hr
George, hr
Freddy, sales



[Updated on: Mon, 20 November 2006 02:04]

Report message to a moderator

Re: Difference between two query [message #204315 is a reply to message #204309] Mon, 20 November 2006 02:25 Go to previous messageGo to next message
Mohammad Taj
Messages: 2412
Registered: September 2006
Location: Dubai, UAE
Senior Member

hi Juliee,

Left Outer Join is ANSI standard sql.
and

*********************

(+) join is SQL*PLUS propertary.


http://awads.net/wp/tag/join



http://download-west.oracle.com/docs/cd/B19306_01/server.102/b14200/queries006.htm#i2054012

hope this helps.
Taj.

Re: Difference between two query [message #204467 is a reply to message #204309] Mon, 20 November 2006 22:22 Go to previous message
moparthy99
Messages: 13
Registered: July 2006
Junior Member
only diff is one ANSI sql and oracle
Previous Topic: Regarding parse_calls in v$sqlarea
Next Topic: GATHER_SCHEMA_STATS - monitoring progress?
Goto Forum:
  


Current Time: Sat Dec 14 17:05:40 CST 2024