ORACLE SQL // IF ELSE? -


i got small problem in sql code :

left join            (select *               pilotage_usines_valeurs              c_indicateur not null) v               on     v.id_usine = d.id_usine                  , v.annee = 2015                  , v.mois = d.mois                  , v.c_indicateur = pi1.c_indicateur 

sometime pi1.c_indicateur null. how can test , write line if pi1.c_indicateur not null don't write if pi1.c_indicateur null ?

if understand intentions correctly suggest add not null condition on clause:

left join (select *              pilotage_usines_valeurs              c_indicateur not null) v   on v.id_usine = d.id_usine      , v.annee = 2015      , v.mois = d.mois      , v.c_indicateur = pi1.c_indicateur      , pi1.c_indicateur not null 

share , enjoy.


Comments

Popular posts from this blog

c++ - Difference between pre and post decrement in recursive function argument -

php - Nothing but 'run(); ' when browsing to my local project, how do I fix this? -

php - How can I echo out this array? -