Does anyone has code examples of how to create query based on the cell value and then connect to the Oracle database from VBA and then return the result set.

I cannot use the parameter query right from Excel worksheet because my query is a UNION query which seems to be not supported such that I can pass parameters from a cell.

Can anyone help.

Thanks,