Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Selecting every other code.... why wont THIS work?
If I do the following:
SELECT testtime, MOD(rownum,2) FROM testdata
I get the following output:
0.0 1 0.1 0 0.2 1 0.3 0 0.4 1
and so on. So by my reckoning, in order to select only every OTHER row in this table I should be able to do:
SELECT testtime FROM testdata WHERE MOD(rownum,2) = 1
But it returns no records! I've obviously missed something here?!?
Cheers,
elziko Received on Mon Feb 03 2003 - 04:26:32 CST
![]() |
![]() |