Workflows Tips #20: How to Manage Tables for Fast Short-Term Storage
Tags: nocode, workflows, okta, ipaas
Published: 2022-08-25 19:10:58

---
title: Workflows Tips #20: How to Manage Tables for Fast Short-Term Storage
published: true
date: 2022-08-25 06:41:11 UTC
tags: NoCode,Workflows,okta,ipaas
canonical_url: https://maxkatz.net/2022/05/13/workflows-tips-20-how-to-manage-tables-for-fast-short-term-storage/
---

Welcome to another Okta Workflows Tips post. Read all other tips ⤵️
{% embed https://dev.to/oktaworkflows/okta-workflows-tips-57bj %}

This post is all about managing tables:

- When to use tables
- Import data from a CSV file into a table
- Exporting and deleting all rows
- Show/Hide columns
- Change column order with drag and drop
- Resizing columns
- Sorting by a column
- Filtering by column value
- Default column value
- Copy table

Tables should be used as a fast cache/transitory place for storing small amounts of data. We shared when to use tables in [Workflows Tip #17](https://dev.to/maxkatz/workflows-tips-17-exporting-a-flow-when-to-use-tables-and-online-meetup-reply-28jb-temp-slug-4643995). It’s worth to review it again before learning how to manage a table.

## When to use tables

_[Gabriel Sroka](https://www.linkedin.com/in/gabrielsroka/)_, _[AJ Ahrens](https://www.linkedin.com/in/arthur-a-756209188/)_ (Okta), _[Bryan Barrows](https://www.linkedin.com/in/bbarrows89/)_ (Okta), and [Brent Garlow](https://www.linkedin.com/in/brent-garlow-8a9175/) (Okta) contributed to this tip. 

Event though tables can store up to 100k rows, tables should be used as a fast cache/transitory place for storing small amounts of data. Tables are not ideal for storing a lot of data, or sensitive data. It’s not really a database (there is no record locking, for example). And, you should consider clearing the table once its data was persisted or no longer needed.

Some recommended use cases for tables: 

- Store data for different flow runs 
  - A flow saves data into a table to be read when it runs again
- Store data for different flows
  - A flow saves data into a table to be read by a different flow
- Look-up tables
  - Information such as country and country code (see image above)
- Basic reporting
  - Keep track of successful and failed flow runs
  - How many times “something” happened
  - Save any report data into a table to be later exported into Google Sheets and clear the table
- Static data or data that changes infrequently 
  - Keep data such as emails, phone numbers, IDs and so on that a flow would need to look up as it runs

While it is recommend using tables for relatively short-term storage, there are use cases where data can stored outside of transactional storage between flows. For example, log a user event like  **created** , then check the table to see if 90 days has past.

## Import data from a CSV file into a table

This tip is from [Mick Johnson](https://www.linkedin.com/in/mick-johnson-00025018/), Workflows Builder Advocate at Okta.

You can import data from a CSV file into a table. Before importing create columns that correspond to columns in the CSV file. Click **Import** to choose a CSV file. On the import dialog you can map CSV columns to table columns.

[![Importing a CSV file](https://katzmax.files.wordpress.com/2022/05/workflows_tips20_table_import.png?w=1024)](https://katzmax.files.wordpress.com/2022/05/workflows_tips20_table_import.png)
<figcaption>Importing a CSV file</figcaption>

[![Import CSV file](https://katzmax.files.wordpress.com/2022/05/workflows_tips20_table_countries.png?w=1024)](https://katzmax.files.wordpress.com/2022/05/workflows_tips20_table_countries.png)
<figcaption>Import CSV file</figcaption>

You can also hide a column by clicking the column’s **gear** icon.

[![Column options](https://katzmax.files.wordpress.com/2022/05/workflows_tips20_tables_column_gear_options.png?w=654)](https://katzmax.files.wordpress.com/2022/05/workflows_tips20_tables_column_gear_options.png)
<figcaption>Column options</figcaption>

## Exporting and deleting all rows

If you need to get a CSV file from an existing table, click the **Export** link.

And, if you need to delete the entire table (yes, everything), click **Delete All Rows**.

[![Export and delete all rows options](https://katzmax.files.wordpress.com/2022/05/workflows_tips20_export_deleteall.png?w=750)](https://katzmax.files.wordpress.com/2022/05/workflows_tips20_export_deleteall.png)
<figcaption>Export and delete all rows options</figcaption>

## Show/Hide columns

If a table has many columns or you want to hide the system columns, click on **Columns** where you can choose which columns to show/hide.

[![Show/hide columns](https://katzmax.files.wordpress.com/2022/05/workflows_tips20_showhide_columns.png?w=1024)](https://katzmax.files.wordpress.com/2022/05/workflows_tips20_showhide_columns.png)
<figcaption>Show/hide columns</figcaption>

## Change column order with drag and drop

You can change columns order with drag and drop.

[![Changing column order](https://katzmax.files.wordpress.com/2022/05/workflows_tips20_tables_column_dragdrop.gif)](https://katzmax.files.wordpress.com/2022/05/workflows_tips20_tables_column_dragdrop.gif)
<figcaption>Changing column order</figcaption>

## Resizing columns

You can resize columns by dragging the column’s side border.

[![Resizing columns](https://katzmax.files.wordpress.com/2022/05/workflows_tips20_tables_resize.gif)](https://katzmax.files.wordpress.com/2022/05/workflows_tips20_tables_resize.gif)
<figcaption>Resizing columns</figcaption>

## Sorting by a column

Click a column to sort a table by that column.

[![Sorting a table by a column](https://katzmax.files.wordpress.com/2022/05/workflows_tips20_tables_sorting.png?w=1024)](https://katzmax.files.wordpress.com/2022/05/workflows_tips20_tables_sorting.png)
<figcaption>Sorting a table by a column</figcaption>

## Filtering by column value

Use filtering to show only data you need. Click **Filter** and enter a condition.

[![Filter conditions](https://katzmax.files.wordpress.com/2022/05/workflows_tips20_tables_filter2.png?w=1024)](https://katzmax.files.wordpress.com/2022/05/workflows_tips20_tables_filter2.png)
<figcaption>Filter conditions</figcaption>

Table view will be updated based on the filter.

[![Filtered view](https://katzmax.files.wordpress.com/2022/05/workflows_tips20_tables_filter3.png?w=1024)](https://katzmax.files.wordpress.com/2022/05/workflows_tips20_tables_filter3.png)
<figcaption>Filtered view</figcaption>

## Default column value

When creating a new column, you can set its default value. Every time a new row is created, the column will be set to its default value automatically.

[![Column default value](https://katzmax.files.wordpress.com/2022/05/workflows_tips20_tables_default_column_value.png?w=886)](https://katzmax.files.wordpress.com/2022/05/workflows_tips20_tables_default_column_value.png)
<figcaption>Column default value</figcaption>

## Copy table

When a building a flow that leverages a table you might want to create another version of the table for testing. Go back to table list, click **duplicate** icon to create a copy of a table.

[![Copy a table](https://katzmax.files.wordpress.com/2022/05/workflows_tips20_tables_duplicate-1.png?w=1024)](https://katzmax.files.wordpress.com/2022/05/workflows_tips20_tables_duplicate-1.png)
<figcaption>Copy a table</figcaption>

And, you can toggle between list view and care view.

* * *

Two resources to help you learn more:

📌 Try this step-by-step getting started tutorial: [Build Your First Automation With Okta Workflows: Notify When User Is Suspended](https://dev.to/maxkatz/build-your-first-automation-with-okta-workflows-notify-when-user-is-suspended-1l3p-temp-slug-2933517).

📌 All the [Workflows resources](https://dev.to/maxkatz/okta-workflows-resources-1ebi) (docs, tutorial, office hours, templates, office hours and more)