Home » SQL & PL/SQL » SQL & PL/SQL » How to Join two Table
How to Join two Table [message #14637] Thu, 02 September 2004 12:32 Go to next message
Kumar
Messages: 115
Registered: December 1998
Senior Member
Hi

I have two table

NAMES
=======
FN        | LN
------------------
SAM     &#124  JOSE
TIM       | SMITH
RAJ       | PATEL

Table name is NAMES, two column name is FN & LN both are string type

CONDITIONS
===========
CONDITION
---------------
FN= "SAM"
LM="PATEL"

Table nameis CONDITIONS, one column name is CONDITION - Type string.
            CONDITION column have condition used to filter data.

I am looking for output like Select * from NAMES where ( FN="SAM or
LN="PATEL")

My output would be ..

NAMES
========
FN        | LN
------------------
SAM     &#124  JOSE
RAJ       | PATEL

How to generate where condition using single SELECT Statement

Thanks
Re: How to Join two Table [message #14639 is a reply to message #14637] Thu, 02 September 2004 12:47 Go to previous messageGo to next message
Todd Barry
Messages: 4819
Registered: August 2001
Senior Member
You will have to use dynamic SQL and PL/SQL. You cannot do this in a static SQL statement.
rd. how to join two table [message #16293 is a reply to message #14637] Sun, 21 November 2004 21:38 Go to previous message
jeetendra anare
Messages: 1
Registered: November 2004
Junior Member
I have two table

i want to join but all the data is not in 2 nd table

but i want to show the message in query which is not in 2 nd table.

suppose found in 2nd table i will display a data
if not then i want to give message that data is not there.
Previous Topic: ORA-04021: timeout occurred while waiting to lock object
Next Topic: Reg: the exception handling
Goto Forum:
  


Current Time: Thu May 02 12:32:03 CDT 2024