Google Sheets New Row to Dataverse Ingest
When a row is added to a Google Sheet (or on a short poll), the flow validates and upserts it into a Dataverse table, deduplicates on a key column, flags bad rows back in the sheet, and notifies the owner in Teams. Brings ad-hoc Google Sheets data into the governed Microsoft data layer.
Provided as-is, without warranty of any kind. Review and test each pattern in a non-production environment before deploying it to live automations. See our Terms.
Overview
This flow brings ad-hoc Google Sheets data into the governed Microsoft data layer. On a short schedule it polls a source worksheet, validates each row, upserts valid rows into a Dataverse table (deduplicating on a key column), flags invalid rows back in the sheet, and notifies the data owner in Teams — with a run summary at the end. Why it matters: Teams collect intake data in Google Sheets, but reporting and apps live in Dataverse. Automatic, validated ingest avoids manual re-keying and keeps one trusted copy. Ships Off — going live needs only connection auth + environment-variable values.
Use Case
A team captures intake/data in a Google Sheet and needs it landed cleanly in Dataverse, with bad rows surfaced for correction and an audit trail of what was ingested.
Flow Architecture
Poll Google Sheet On Schedule
RecurrenceEvery 5 minutes (the short poll). Google Sheets has no native row trigger, so Recurrence + GetItems is used.
Initialize variables
Initialize VariableRead source config (spreadsheet, worksheet, key column), target table, Teams target, a correlation id, and run counters.
Get Sheet Rows
Google Sheets — GetItemsReads all rows from the worksheet (real connector retrieval; no fixtures).
Apply to each Row
ForeachLoops over the rows and validates each.
Condition Row Is Valid
ConditionTrue when Name and the key column are both non-empty.
List Existing Records
Microsoft Dataverse — ListRecordsFor valid rows, queries by the dedupe key to detect an existing record.
Upsert Record
Microsoft Dataverse — UpdateRecord / CreateRecordUpdates if found, else creates; increments the processed counter.
Flag Bad Row In Sheet
Google Sheets — PatchItemFor invalid rows, writes Status/Note back to the sheet.
Notify Owner Invalid Row
Microsoft Teams — PostMessageToConversationNotifies the data owner about an invalid row; increments the invalid counter.
Post Ingest Summary
Microsoft Teams — PostMessageToConversationEnvironment Variables
| Schema name | Type | Default | Description |
|---|---|---|---|
| flowlibs_GSheetId | String | <configure> | Source Google spreadsheet (file) ID. |
| flowlibs_GSheetTab | String | Sheet1 | Source worksheet/tab name. |
| flowlibs_GSheetKeyColumn | String | Sheet column header used as the upsert/dedupe key. | |
| flowlibs_TargetTable | String | <configure> | Dataverse target table (documentation). |
| flowlibs_TeamsGroupId | String | <your-team-id> | Teams team (group) ID for notifications. |
| flowlibs_TeamsChannelId | String | <your-channel-id> | Teams channel ID for notifications. |
Connectors & Connections
| Connector | API name | Actions used |
|---|---|---|
| Google Sheets | shared_googlesheet | GetItems PatchItem |
| Microsoft Dataverse | shared_commondataserviceforapps | ListRecords CreateRecord UpdateRecord |
| Microsoft Teams | shared_teams | PostMessageToConversation |
Note — All connections are referenced as solution connection references; the flow is portable between environments as long as a connection is mapped at import time.
Customization Guide
Almost every realistic variant of this flow can be implemented by changing environment variable values. A few cases require small edits inside the flow definition — those are called out explicitly below.
- Configure the source
- Set flowlibs_GSheetId to the spreadsheet ID and flowlibs_GSheetTab to the worksheet. The sheet needs a header row; columns are referenced by header name.
- Sheet write-back columns
- For invalid-row flagging, add Status and Note columns to the source worksheet.
- Dedupe key
- Change flowlibs_GSheetKeyColumn to whatever header uniquely identifies a row (defaults to Email).
- Type coercion
- Extend the validate step / record mapping to parse numbers and dates from text cells.
- Quarantine tab
- Instead of flagging in place, route invalid rows to a separate worksheet via PostItem.
- Poll cadence
- Adjust the Recurrence interval to match how quickly rows must land.
Key Expressions
The flow is intentionally light on Power Fx / WDL gymnastics — the heaviest expressions are the branch-name concatenation and the approval outcome check. They are listed below in the order they appear in the flow.
EXPR.01Validation
Valid when Name and the key column are both non-empty.
EXPR.02Dedupe filter
OData filter on the Dataverse key column.
EXPR.03Exists check
True when a matching record already exists.
EXPR.04Update target id
Primary key of the record to update.
EXPR.05Sheet row id (PatchItem)
Row key used to flag the correct row.
Customize & download
Generate a ready-to-import copy of this solution with your environment-variable values baked in — available on Base, Pro, or Team.
Upgrade to customize
Comments
Sign in to join the conversation.
Sign inNo comments yet. Be the first to share your experience with this flow.