I have a form where the user can enter multiple months and my SQL query returns the data for those months.
For example, if the user enters January the SQL should be:
SELECT * FROM table WHERE month = 'January'
If the user enters March, August, October the SQL should be:
SELECT * FROM table WHERE (month = 'March' OR month = 'August' OR month = 'October')
How would I go about making the WHERE conditions dynamic like that because the user can enter however many months we wants? Its like an ad-hoc query. Thanks!