🤖 Importing data to Glide by use of robot (RPA)

Challenge 1
In this moment of time it is not possible to import data (or paste chunks of data) into Glide.

@Manu.n has shown a way to import a row at a time from Google sheets to Glide tables which is quite handy if you have not to much data to import. But if you have hundreds or thousands of rows this approach is not the way to go.

Manu.n's approach - great for a smaller number of rows

Import Data From Excel & Sheets into Glide Table - #18 by Manu.n

I will show how to use a software robot (RPA) to do the job.

Challenge 2
Deleting items from Glide tables also causes problems as rows are not always deleted by Glide - they sometimes comes back.

I propose that you just mark a row as deleted and then do a batch delete job by use of a robot

Video of setup
I will take you through the process in this video

How-to
Prerequisite:
Install the robot - it is opensource

Installing robot

Install like suggested in root of c directory

Installation — TagUI 6.46.0 documentation

If you want to further understand how to use the robot please have a look in the documentation
Main concepts — TagUI 6.46.0 documentation

RPA script files
Download the files and place them in this directory on your computer: C:\tagui\flows\samples

RPA script for copying data from GS to GT

Copy_data_from_GS_to_GT_ver_1_2_template.tag - Google Drive

//-----------------------------------------------------------
// Copy data from GS to GT
// Created by krivo aka Kristian Voigt
//-----------------------------------------------------------

// this command that must be run in command line window (cmd)
// tagui c:\tagui\flows\samples\Copy_data_from_GS_to_GT_ver_1_2_template.tag

//------------------------ open app and sign in--------------
//open the glide app

//wait is used in order to make the app open correctly AND sign in. It can also be used to maximize the window
wait 45

// ------------------------ copy ---------------------

// Select the tab where list of elements are found to be copied
click //button [contains(., ‘Copy to glide’)]

// copy a number a elements from google sheet to glide table
// sometimes the clicks are not registered so therefore you might have to specify a bigger number than elements that needs to be copied
// the job will fail gracefully if there are no more items to copy
for n from 1 to 100
click //*[contains(@class,‘separator selected-item-list-item’)]

RPA script for deleting data from to GT

Delete_data_from_GT_ver_1_2_template.tag - Google Drive

//-----------------------------------------------------------
// Delete data from Glide table
// Created by krivo aka Kristian Voigt
//-----------------------------------------------------------

// the command that must be run in command line window (cmd)
// tagui c:\tagui\flows\samples\Delete_data_from_GT_ver_1_2_template.tag

//------------------------ open app and sign in--------------
//open the glide app

//wait is used in order to make the app open correctly AND sign in. It can also be used to maximize the window
wait 60

//------------------------ delete ------------------------

// Select the window where list of elements are found to be deleted
click //button [contains(., ‘Delete from glide’)]

// delete a number a elements from glide table
// sometimes the clicks are not registered so therefore you might have to specify a bigger number than elements that needs to be deleted
// the job will fail gracefully if there are no more items to delete
for n from 1 to 200
click //*[contains(@class,‘separator selected-item-list-item’)]

App to try out
Copy the app to your own Glide account

Run
Adjust the scripts so they point to your own app. Inside the script file it is indicated where to change
Run the scripts from a command window (cmd in windows)

Use the concept in your already created app
There are a few ways where you can use the concept in your existing apps.

  1. Recreate the sample app inside your existing app - you just need two extra tabs (which you should put visibility on so your users don’t see them)
  2. Create a new app where the Glide table is a link to an existing table inside your existing app

Lessons learned
Trying to get the signing in process to be supported by the robot was a nightmare. Either the robot, cookies or glide made the email address reappear and couldn’t be totally cleared. Anyway, you will still need to input the pin-code so the benefit of automation a part of sign-in process isn’t that big.

Feedback
Please leave some feedback on how you succeed - or if you encounter problems e.g. when doing large Google sheets.

16 Likes

Thin,
I who put all my savings in the actions of mouse manufacturers !!
With your robot, everything falls apart.
Joke!

3 Likes

Any way via Mac OS

https://tagui.readthedocs.io/en/latest/setup.html#macos-linux

yes, I expect so.

This is so cool omg

1 Like

Just want to say thanks to you, I have been able to do this to import thousands of rows to Glide Tables in an app last week. I can let the robot do its thing while I do other tasks. I’m on Mac.

Thanks a lot!

9 Likes

@ThinhDinh cool. Great to hear

3 Likes

Thanks a lot!!

Hi there, it might sound stupid but why would we want to transfer data from the google table to the glide table, isn’t it the same? what are the differences?

Thank you in advance.

With Glide Tables, you will enhance the performance of your app since data won’t have to travel back and forth between Glide servers and the Sheet. It also won’t cost you sheet edits.

2 Likes

@dvamvoo01 exactly as thinh says and sometimes you might also want to import data from a totally different source and here google sheets can serve as an intermediate source.

Database → google sheets → glide table

3 Likes

wooh i didn’t know about that and it is a perfect application for my app.
thanks i will try to implement it

1 Like

Im amazed thank you for this integration!
i will try to implement it…

2 Likes

Building the data exclusively in Glide Tables is quite restrictive. I have a concern when data reaches 50k rows and above, I couldn’t archive it to my own database. My yearly data is about 50k and we know 50k rows cause huge performance issue in glideapps. So my plan is to archive it to external DB but I still couldn’t figure out the way to easily import it to my db. How do I export/sync data from glide tables to other sources?

This is a valid concern. 25k is already a big problem let alone 50k. I don’t have a good answer for now as you can’t mass import/sync data to Glide Tables in a matter of minutes, exporting however is possible with the export data option we already have.

Oh sorry, yes we can export but we can’t do it in scheduled manner or to sync with external db right?

Yes, that’s true.

1 Like

Computed columns are not exported, so not fully usable

2 Likes