📤 Allow User to Upload and Import CSV Files Tutorial

:waving_hand: Hey fellow Gliders!

Allowing users to import CSV data is a feature not natively supported in Glide, but it can be achieved through clever workarounds.

The video breaks down two primary methods for handling bulk data:

:one: Method 1: Looping Workflow (for Smaller Imports)

This approach involves creating a workflow that iterates through each row of a CSV file and adds it as a new record.

:white_check_mark: Pros: Relatively straightforward to set up within Glide.
:prohibited: Cons: Limited to approximately 1,000 records due to Glide’s operation limits and can be slow for larger datasets, consuming more app updates.

:two: Method 2: Glide API with Stashing (for Large Imports)

This advanced technique leverages Glide’s API v2, specifically the “stashing” feature, for highly efficient bulk uploads.

:white_check_mark: Pros: Handles hundreds or thousands of records near-instantaneously, significantly more cost-effective (e.g., 2,000 records cost only 20 updates instead of 2,000).
:prohibited: Cons: Requires a deeper understanding of API calls, JSON manipulation, and a bit of JavaScript for “chunking” data. It also introduces the need to work with column IDs instead of readable headers, often requiring AI assistance for conversion.

The video includes a step-by-step guide for both methods, including:

  • Building an importer interface.
  • Validating CSV files and headers.
  • Converting CSV to JSON.
  • Enabling manual workflow triggers.
  • Configuring the API calls leveraging stashing to keep updates to a minimum

:popcorn: Enjoy!

6 Likes

Cool video!

2 Likes

Thanks! Intrigued to see if anyone can leverage this or improve upon it.

1 Like