Intro
This guide helps you implement the Inline Editing app with your own data. For more information on the Inline Editing app, please visit the Inline Editing User Guide. Inline Editing is a premium app you can use to individually or collectively modify the content of any DataSet from a card within Domo. This guide details how to implement the Inline Editing app in the following topics:Preparing Your Data
The Inline Editing app is built to handle two types of data models: standard and upsert DataSets. For this version of the app, connector-based DataSets that are updated through outside sources are not recommended, as any changes you save are overwritten by data coming through the connector. Standard DataSets have some inherent limitations in terms of how they can be updated, and because of this, if your app is using a standard DataSet you are limited to DataSets that have 100,000 or fewer rows and 500 or fewer columns. Upsert DataSets can be any size, but they take a little extra effort to set up. Follow the instructions below to convert a DataSet to an upsert DataSet.Converting to an Upsert DataSet
(Optional) To convert a DataSet to an upsert DataSet, follow the steps below.- In Domo, navigate to your DataSet.
- Go to the Settings tab, then select the Update Mode setting to expand it.
- Select the Update method and choose Append from the list.
- Select Save to keep your changes.
- Now create your upsert keys. Upsert keys are a group of columns in your data that when put together create a unique key for each row— you must set these keys manually. The next steps describe how to set your keys.
- Download the Java CLI tool using the following link: https://app-domo-com-prod.s3.amazonaws.com/labs/java-sdk/latest/domoUtil.jar
- Navigate to and run the JAR file from either your terminal or command line tool.
Note: To run the JAR file in the Mac Terminal, make sure you have java installed and then navigate to the correct directory and use the following command:
'java -jar domoUtil.jar'-
When the program is running in your command line, you’ll first need to connect to your Domo instance and use the command:
connect -s <domain> -t <access_token>
<domain> is the name of your Domo instance (mycompany.domo.com ), and <access_token> is a generated access token from your Domo instance. Access tokens can be generated by admins in your Domo instance by navigating to Admin > Security > Access Tokens and selecting Generate Access Token. -
After you have connected to your instance, use the following command:
define-upsert -i <dataset_id> -c <columns>
<dataset_id> is the dataset id of the DataSet that you want to set as an upsert DataSet and <columns> is a comma-separated list of columns names that you want to use as upsert keys (” Column 1”, ” Column 2”, and so on). Remember to use double quotes around any columns that have spaces in the column name. -
To check to see if this process worked, use the following command:
get-schema -i <dataset_id>
and check to see if ‘upsertKey’ is set to true for the columns that you passed through in the last command. - Close the CLI tool. Your DataSet is now an upsert DataSet.