Skip to main content
Participating Frequently
July 11, 2014
Answered

tips for speed up to show million records from DB

  • July 11, 2014
  • 2 replies
  • 542 views

Please let me know the tips for  speed up application ....

Our application need to show million records from database its taking time to load ...

Thanks in advance

Bibin

    This topic has been closed for replies.
    Correct answer duncancumming

    Saving html in your DB isn't going to speed anything up... you'll still end up having to render 1000000 table rows to the client.

    Ditch Bootstrap pagination, it's purely client side.  Your page size must be huge.  Do it server side so you can request and render just 100 (for example) rows at a time.  Alternatively combine with Bootstrap to make ajax requests for each page in response to user clicks.

    2 replies

    BKBK
    Community Expert
    Community Expert
    July 11, 2014

    A million records, huh? Common database brands can handle that. To improve performance,

    1) Critically question the use-case to find out whether a smaller number of records will do;

    2) Cache reusable static data on the Coldfusion server, so that you wouldn't have to load it every time;

    3) Load just the data columns that are absolutely necessary;

    4) Use indices.

    What is your database type?

    Participating Frequently
    July 11, 2014

    A million records will take a long time to display.  Try paginating them instead.  This then means you also don't need query to get all records at once, you can get X records at a time.

    Bibin-_V-Author
    Participating Frequently
    July 11, 2014

    Already have bootstrap pagination but that apply once all records load

      Can i able to save entire  <tr><td>prj1 </td></tr>  in db colum ?

    a schedule task for save records in a new table

    <cfsave content  var ='test'><tr><td>#prj1#</td><td><img > </td><td>#proj dec# </td></tr></cfsavecontent>

    insert into new_table (colum1)

    value(test);

    so that will save all ( include image and all)  in TR result in 1 colum and disply this

    duncancummingCorrect answer
    Participating Frequently
    July 11, 2014

    Saving html in your DB isn't going to speed anything up... you'll still end up having to render 1000000 table rows to the client.

    Ditch Bootstrap pagination, it's purely client side.  Your page size must be huge.  Do it server side so you can request and render just 100 (for example) rows at a time.  Alternatively combine with Bootstrap to make ajax requests for each page in response to user clicks.