Hi everyone,
I have 100 record in table. and I want to show data in ListView only 20 record.
but every 20mn I want to change to other 20 record else. How to do it?
If all know about it please tell me.
Thank Advance.
From: Mala
Show data
2 Answers
Know the answer? Post it. Somebody with the same question will find it here.

Suthish NairRank #92 · 22.8K reputationPosted Jun 3, 2011, 1:52 AM EDT
if object_id('tempdb..#t1') is not null
DROP TABLE #t1;
with cte as (
select 10 id
union
select 20
union
select 30
union
select 40
union
select 50
union
select 60
union
select 70
union
select 80
union
select 90
union
select 100
)
select ROW_NUMBER() over (order by id) as rn, id into #t1 from cte
--select * from #t1 where rn between 1 and 5 (for your case 1 and 20)
select * from #t1 where rn between 6 and 10 (for your case 21 and 40)
You need to store the next between value and later send to db and fetch the record.
The values must be dynamic, do not hard code..
Manath Pathana86 reputationPosted Jun 5, 2011, 6:28 PM EDT
please show me with simple data?
coz i need to use it with .net language.