
- Subscribe to RSS Feed
- Mark as New
- Mark as Read
- Bookmark
- Subscribe
- Printer Friendly Page
- Report Inappropriate Content
If you are building a scoped application for the store, you may want to include some demo data, or non-metadata application files to provide some demonstration of the functionality of the application. Records on regular metadata tables (tables that extend sys_metadata) will always be included in the application automatically, and you do not need to move them. In fact, you will not even have the option to do so because the Create Application File UI action is not available on metadata tables.
In this post, I will show you how to capture Demo Data and how customers can install an application along with Demo Data.
Application File Creation Options:
The Create Application File UI action provides three options:
- New Install and Upgrades
- New Install
- New Install with Demo Data
Steps to Capture Demo Data:
Let's pretend we created a scoped application called "Marketing Events" and as part of my app functionality, I would like to create a record in OOTB location "cmn_location" Table. As we know that location table is not extended from "sys_metadata", we will have to capture it as part of the demo data.
- On your instance navigate to User Administration > Locations
- Create a new Location record
- Now filter the records from the list view and select the option “Create Application File” from the List choice
4. A pop-up screen will be shown with details like the number of records selected from the table in the application scope
5. Select one of the options depending on the below description and save the record.
Once a non-metadata file has been moved into the application, it will appear on the Application Files related list on the sys_app record as a Metadata Snapshot class and will be published with your application. A record is also generated on the sys_metadata_link table, which is responsible for linking that record to the correct package folder.
Behavior of Application Installation with Demo Data:
A customer who installs the application will see the below option i.e Install or Install with Demo Data. This additional option i.e "Install with Demo Data or Update with Demo Data" is only visible when app author has captured the Demo Data as "New Install with Demo Data". In other cases, the demo data records will be created as part of app installation.
We have successfully covered how to package Demo Data as part of Scoped Applications. As a best practice, please ensure to review application Files related to "Metadata Snapshot" class aka Demo Data records before you publish your Scoped Application.
For more information, see the Create application files to include sample data product documentation topic.
- 7,279 Views
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.