We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

insert many rows performance

Hello! 
I have a data stream in real time, which I have to display in the table. I use the insert in collection data view model, but display all hopelessly behind in realtime. The data to be displayed all at a time, you can not miss (a stream of market transactions). Please help!

10 Replies

GL Ganeshkumar Lingappan Syncfusion Team April 20, 2015 12:54 PM UTC

Hi Oleg,

Thank you for contacting Syncfusion support,

We have analyzed your query and we have prepared a sample for SfDataGrid with 25 Columns based on your requirement. In this Sample, we have inserted 10000 records in a Button click and here all the records getting loaded at a considerable time. we have attached the test sample, please revert us by modifying the attached sample based on your application along with the replication procedure that would be helpful for us to proceed further and resolve the issue

Please Refer the Sample in the Below mentioned Location.
Sample Link : http://www.syncfusion.com/downloads/support/forum/118884/CS-2079283653.zip
Please let us know if you require any further assistance.

Regards,
Ganesh.


OL Oleg April 20, 2015 05:26 PM UTC

Thank you for your example, I implemented it in my code, but the delay big. A lot of data, they should all display in turn. New print = insrert[0] in table. I think to do differently - to fix the size of the grid and in the mode stack data drive through it. But it is impossible, the grid is automatically extended, and it slows down the speed. I need to get a table had a constant number of rows and update all information shifted, and the first line contains new information. Help, how to implement it.

for (int i = 1; i<grid.rows.count; i++)
grid.rows[i] = grid.rows[i-1]

grid.rows[0] = new_print



OL Oleg April 20, 2015 08:16 PM UTC

i find Data Virtualization , but I can not test, please help with the example


 public class FastViewModel:NotificationObject
    {        
        GridVirtualizingCollectionView data;
        List<Tick> prints;
        public FastViewModel()
        {
            prints = new List<Tick>();
            data = new GridVirtualizingCollectionView(prints);

            Add(); Add(); Add(); it works
        }

        public GridVirtualizingCollectionView Stocks
        {
            get { return data; }
        }

        public void  Add() it does not work from an instance of an object, in what could be the reason?
        {
            Tick mm = new Tick();
            mm.Time = DateTime.Now.Ticks.ToString();
            prints.Insert(0, mm);
        }

    }

Attachment: CS20150420_57d0d3c8.zip


GL Ganeshkumar Lingappan Syncfusion Team April 21, 2015 02:08 PM UTC

Hi Oleg,

We are sorry about the inconvenience caused.

We have analyzed your query and you are using List. List is not implemented from INotifyCollectionChanged interface. So add, remove operations in the itemsource is not reflected in Grid. We have used ObservableCollection instead of List to make this work. Please find the modified sample from below location,

Sample Link : http://www.syncfusion.com/downloads/support/forum/118884/CS-1567587559.zip

Please let us know if you require further assistance

Regards,

Ganesh



OL Oleg April 21, 2015 03:10 PM UTC

This technology can not cope with the influx of data, each tick which requires the addition of a single line. What are the options for acceleration, for example, to create a static table and update directly on the key of line?
Tell me how to assign a line key and gain access to the line for this key?


GL Ganeshkumar Lingappan Syncfusion Team April 22, 2015 01:46 PM UTC

Hi Oleg,

We are regret to inform you that, we are not able to understand your requirement clearly. Please share simple sample that reproducing the reported issue otherwise share more details regarding your requirement, that would be more helpful for us to serve you better.

Regards,

Ganeshkumar



OL Oleg April 22, 2015 03:20 PM UTC

I found a solution to quickly add new rows to a table
https://peteohanlon.wordpress.com/2008/10/22/bulk-loading-in-observablecollection/


SC Saranya CJ Syncfusion Team April 23, 2015 07:30 AM UTC

Hi Oleg,

We are glad to know that you have found out solution for your issue. Please let us know if you require further assistance.

Regards,
Saranya


JA Jibran Ahmed Sheikh replied to Oleg October 14, 2020 12:35 PM UTC

I found a solution to quickly add new rows to a table
https://peteohanlon.wordpress.com/2008/10/22/bulk-loading-in-observablecollection/

Thanks for sharing the link mate. I really appreciate it.


MA Mohanram Anbukkarasu Syncfusion Team October 15, 2020 06:20 AM UTC

Hi Jibran, 
 
Thanks for the update.  
 
Regards, 
Mohanram A. 


Loader.
Live Chat Icon For mobile
Up arrow icon