How to get odd number in sql?
SELECT * FROM table_name WHERE mod(column_name,2) = 0; This syntax will find rows where our target column has odd values: SELECT * FROM table_name WHERE mod(column_name,2) <> 0; SQL Server does not have a MOD function.
SELECT * FROM table_name WHERE mod(column_name,2) = 0; This syntax will find rows where our target column has odd values: SELECT * FROM table_name WHERE mod(column_name,2) <> 0; SQL Server does not have a MOD function.