Quantcast
Viewing latest article 24
Browse Latest Browse All 207

oracle working with CTE with condition

DEFINE fromtable1= true;WITH firstQuery AS (  SELECT columns FROM table),secondQuery AS (  SELECT columns FROM second_table)  IF @fromtable1= true  BEGIN      SELECT *      FROM   firstQuery   ENDELSE  BEGIN      SELECT *      FROM   secondQuery   END

In oracle I tried above but I get error is there a way to make a query like this


Viewing latest article 24
Browse Latest Browse All 207

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>