Allen Pitts
asked on
Extracting data for test table
Hello experts,
Creating test table using query copied herewith below
to extract data from the CCM_LOCATION a
table which huge, over 2 million rows. So ROWNUM is used
to throttle the result to make it manageable.
SELECT *
FROM CCM.CCM_LOCATION
WHERE
EMPLOYER_ID not in
(
726452, 310511, 203546, 783241, 906595, 248732,
883208, 683802, 721057, 263611, 838024, 762232,
397853, 301519, 277577, 783928, 731437, 280614,
208566)
and
LOCATION_NAME not like 'Compass Grp%'
and
and rownum < 5000
order by location_name;
This works.
But then a look at the data deeper into the table
is desired and the rownum clause is changed to
and rownum between 5000 and 7000
This returns no records.
So tried
and rownum > 5000
This also returns no records.
Does ROWNUM only work with the less than operator?
Thanks
Allen in Dallas
Creating test table using query copied herewith below
to extract data from the CCM_LOCATION a
table which huge, over 2 million rows. So ROWNUM is used
to throttle the result to make it manageable.
SELECT *
FROM CCM.CCM_LOCATION
WHERE
EMPLOYER_ID not in
(
726452, 310511, 203546, 783241, 906595, 248732,
883208, 683802, 721057, 263611, 838024, 762232,
397853, 301519, 277577, 783928, 731437, 280614,
208566)
and
LOCATION_NAME not like 'Compass Grp%'
and
and rownum < 5000
order by location_name;
This works.
But then a look at the data deeper into the table
is desired and the rownum clause is changed to
and rownum between 5000 and 7000
This returns no records.
So tried
and rownum > 5000
This also returns no records.
Does ROWNUM only work with the less than operator?
Thanks
Allen in Dallas
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER