How to Auto-Import Data Into Google Sheets



Summary.

In this tutorial, we'll auto import transaction data from a sample CSV file to our Coffee Budget Google Sheets Dashboard. This will save us immense time since we won't need to manually enter transaction data one row at a time. Plus you only have to do this once, say at the end of the month.


This tutorial is broken down into 4 Parts.

  • Part 1 - Upload CSV file to Google Drive
  • Part 2 - Authorize App Scripts
  • Part 3 - Automatic Import
  • Part 4 - Other ways to enter transactions


Before you start, please do the following.

1. Save the sample CSV file, "sample_transactions" from your Etsy purchases to your local computer.

Figure 1. Excerpt of Sample CSV file

2. Login to your Google Drive Account.

Part 1: Upload CSV file to Google Drive.

1. Go to your Google Drive Account: drive.google.com.

2. Click on "+ New", then click  "File Upload".

3. Select the sample CSV file from your local folder. It does not matter which folder you upload too.
Figure 2. Google Drive File Upload

4. For your own files, make sure it has all the columns in the sample. The Category and Subcategory columns do NOT need to be filled out. 

5. Repeat steps 1-4 for any CSV file you want to import into the Coffee Budget.

Part 2: Authorize App Scripts.

1. Before you can use the automation, you need to allow App Scripts to use your Google Drive (you only need to do this once).

2. Open the Coffee Budget Dashboard and Make a Copy.

3. Make an edit on the dashboard and the function will appear.

4. Click on "Add Transaction", then "Import from Drive".

Figure 3. Google Sheets UI


5. A pop up similar to below will appear. Click on "Allow".

Figure 4. Permission Pop up

6. If you get this error: Click on "Advanced" in the lower left corner. 

Figure 5. Click on Advanced

7. Then click on "Go to Coffee Budget".

Figure 6. Click on Go to Coffee Budget


Part 3: Using the Function.

1. Go back to Google Sheets.

2. Click on "Add Transactions", then click on "Import CSV".

Figure 7. Import CSV

3. Enter "sample_transactions.csv" into the input box. 

Figure 8. Enter CSV file Name UI

4. Click "Ok".

5. The Dashboard will import all records from the CSV file and add it to the "All Transactions" tab. 

Figure 9. All Transactions

6. Select the Category and Subcategory for each transaction. Subcategory is optional, but Category is needed in order for the Dashboard to accurately aggregate your needs, wants, and savings & debts.

Figure 10. Add Category & Subcategory

7. Most financial institutions will allow you to download your transactions as a CSV file by logging into your online bank account. Please contact them if you're not sure how to do this. 


Part 4: Other Options.

1. Use Coffee to Add. Enter details and Coffee will add it to All Transactions.

Figure 11. Coffee Can Also Add Transactions 

2. Happy Planning!


Comments