Link to home
Start Free TrialLog in
Avatar of Coast Line
Coast LineFlag for Canada

asked on

bringing Data in Chunks Coldfusion

Hi, I am making one ajax call as:

$.ajax({ type:"POST", url:"welcome.cfm", data: data, success: function (html) { $('#message').html(html); } }); return false;

So now i want that i should return 100 records first time it calls that Page, now i want to apply the Paging to that also. So when i cick the next record or any number in paging say 5, it should display that data and make an ajax call to get that data, this way i think it will be better to handle millions of records!

Also i cannot use cfgrid, jquery preferred. if i can get the data as JSON and parse on client ide, i think that can make performance faster!

Guide


Avatar of Gurvinder Pal Singh
Gurvinder Pal Singh
Flag of India image

if you are using mysql, then why don't you use limit and offset to get only that many number of rows from database
Avatar of Coast Line

ASKER

i am not using mysql

sorry
then which one?
oracle
well if i get a sample for this that will be good
I would think you need to pass the page number to the ajax call, otherwise how will the query know which page of 100 records to return?   It may be even better to pass both page number and page size (in case you want to allow the user to vary their page size in the future)
yes that will be, but how. that is confusion
ASKER CERTIFIED SOLUTION
Avatar of Gurvinder Pal Singh
Gurvinder Pal Singh
Flag of India image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
nope used the between operator and worked like a charm Thanks
thanks for showing a way