If or switch?

I m executing a chunk of queries, and if that query is executed then i want something else to be excuted. i am confused here to use if or switch. i never did anything like that.

IF is best suited for a ‘binary’ choice - one thing OR another. You can extend the IF to include more but the logic (and the code) becomes very confused and convoluted.
SWITCH (otherwise known as CASE) is ideal when you need to evaluate a single variable and choose from among multiple values.

Based on your brief post, it seems IF would be best.