SQL Developer (MOSC)

MOSC Banner

Two lovs, select all if none chosen from first lov

in SQL Developer (MOSC) 3 commentsAnswered ✓

Hi all,

I need assistance writing query for 2nd lov.

I would like all the project numbers to show if no company is chosen in first lov.

T_COMPANY_TBL --table 1

COMPANY

--------table 1 (primary)-----------

COMPANY A

COMPANY B

COMPANY C

NONE

-------------table 2 dependent on table 1----------------------------

T_PROJECT_TBL --table 2

COMPANY      PROJECT_NUMBER

COMPANY A         020120

COMPANY A         020121

COMPANY A         020122

COMPANY B         020223   

COMPANY B         020224

COMPANY C         020325



I CREATE 2 LOVS

LOV1 [SELECT * FROM T_COMPANY_TBL

DISPLAYS ALL OF T_COMPANY_TBL


LOV2 [select PROJECT_NUMBER from T_PROJECT_TBL where COMPANY = NVL( :T_COMPANY_TBL, COMPANY, null)

I would like if USER selects NONE from LOV1, ALL THE PROJECT NUMBERS SHOW from 2ND LOV, how do I write it? Right now it returns nothing)

Tagged:

Howdy, Stranger!

Log In

To view full details, sign in to My Oracle Support Community.

Register

Don't have a My Oracle Support Community account? Click here to get started.

Category Leaderboard

Top contributors this month

New to My Oracle Support Community? Visit our Welcome Center

MOSC Help Center