I have the following table on my SQL Server 2012:
ID Name Status Address Phone
1 Tom I U D
2 Joe D U D
3 Pam D I U
4 Ken U U U
How do I select the rows with 'I' in one of the columns? for example, I expect the query to return 1st and 3rd row from the table.
I know the query below works however I need a query that does not specify the column names as I need to deal with a table with more than 20 columns.
SELECT * FROM table WHERE (Status = 'I' or Address = 'I' or Phone = 'I')