How to import data into excel from bigquery large data

It’s taking lot of time for importing data,we have around 10 lakh records,is thr any optimized way to import dtaa without iterating every row
we are using python aspose library
pls find below current code
data = [list(row.values()) for row in rows]

Import all rows at once

worksheet.getCells().importTwoDimensionArray([list(row.values()) for row in rows], 1, 0)
its taking lot of time on creating data data = [list(row.values()) for row in rows]

@rajch789,

Since you are importing such a huge list of data (1 million records), it will definitely take some time. There is no better way to deal with it. You may try to split your data into multiple lists/arrays, with each list containing a few thousand records, and then import each list/array into a different worksheet. This way, your output Excel file will be more efficient.

However, if you still insist on importing the long list of records in a single worksheet and all at once, kindly share a complete standalone sample (runnable) code that shows what data you are importing and how you are importing it into the Excel spreadsheet. We will review it as soon as possible.