I have the two select queries below :
SELECT column_1 FROM table_name WHERE **column_2= 'X'** AND scope= 'scope';
SELECT column_1 FROM table_name WHERE **column_2= 'Y'** AND scope='scope';
I want to pass each of the above queries to a predefined SQL method:
So far only the following syntax has worked, but in this case it is just passing the same value to both parameters:
select function_name(table_name.column_1, table_name.column_1) FROM table_name
WHERE column_2= 'X' AND scope='scope';
I would like to do something like this but it is not working:
select function_name(SELECT column_1 FROM table_name WHERE **column_2= 'X'** AND
scope= 'scope', SELECT column_1 FROM table_name WHERE **column_2= 'Y'** AND
scope='scope');