Question:

How can you select all the even number records from a table? All the odd number records?

Answer:

To select all the even number records from a table:

Select * from table where id % 2 = 0 

To select all the odd number records from a table:

Select * from table where id % 2 != 0

Keywords:

© 2017 QuizBucket.org