Import a JSON file as records in a new table

Structure a local JSON export as rows and columns, preview the result, and create a Mainbase table from it.

Use this workflow for a local .json file that contains records, such as an inventory export. You need permission to import records and create a table. The import accepts an array of objects at the top level or inside a top-level records or data property. Use a single array with one object per record.

Prepare a tabular JSON file

Save a small sample like this as equipment.json.

{
  "records": [
    { "name": "Portable projector", "room": "Studio", "quantity": 2 },
    { "name": "Folding screen", "room": "Workshop", "quantity": 1 }
  ]
}

Mainbase uses the properties of each object as columns. Put values you want in separate columns directly on each record. For example, export room and floor as separate properties if your source puts them together in a nested location object.

Create and verify the table

  1. Open Settings → Database. In the page toolbar, select More options → Import and check that the dialog says Import into a new table. Add the .json file.
  2. In Preview, check that sample records appear as separate rows with the expected headings. If Mainbase rejects the structure, check that the file contains the expected array and that every item in it is an object.
  3. In Mapping, enter a Destination name and select a Title column such as name. Use Include to keep only the columns you need. Check the sample values before continuing.
  4. In Confirm, select Start Import. Review the proposed table and its inferred fields, then approve the proposed changes if they match the file. After the import finishes, open the new table and compare a few records with the sample. If the result is unclear, check for the destination table and its records before starting again.

If the destination already has the fields you need, import the JSON file into the existing table. To move a workspace’s table and field definitions, use the workspace blueprint import.

Check formula results after importing JSON records

For a JSON export that includes table and relationship definitions, see Import a workspace schema package.

Ask Mainbase AI

Ask about any feature in Mainbase. Find a setting, get step-by-step guidance, or troubleshoot a problem.

Open the AI assistant

Copy a question to get started

  • How do I create a Kanban view?
  • How do I invite a teammate?
  • Why is a record missing from this view?