I have followed some guidelines to import my data in to a datatable. My csv is 1.2MB, not sure if I am hitting a limit here.
My code taken from here:
@anvil.server.callable
def create_datatable():
# read file from datatable
my_media = app_tables.files.get(id=1)['results']
# parse it into a pandas dataframe
df = pd.read_csv(io.BytesIO(my_media.get_bytes()), header=0,\
names=['colA', 'colB', 'colC', 'colD', 'colE', 'colF', 'colG'])
# create list of dict for automatic insertion in table
list_of_dicts=df.to_dict('records')
# insert into new data table
for d in list_of_dicts:
app_tables.results.add_row(**d)
Cannot complete due to a time limit error… is there a way to avoid this limitation?