WebDB
Links
  • πŸ‘‹Welcome to WebDB Documentation
  • Installation
    • 1️⃣Standalone
    • πŸ”’Compose
    • ☸️K8S
    • πŸ–₯️Native
    • πŸ›‘οΈSecurity
    • ❌Uninstall
  • Connection
    • DBMS Discovery
    • Credentials Guessing
    • SSH Tunnel
  • Database
  • Interface
    • Schema
    • Database
    • Table
    • Relations
    • Structure
    • Offline
    • Symbols
    • Configuration
  • Explore
    • Explore
    • Search
    • Update
    • Batch Update
  • Query
    • Editor
      • Autocomplete
  • Structure
    • NoSQL inferring limitation
  • Insert
    • Generator
    • Framework embed
    • Foreign Key / Enum
    • Autocomplete
    • Error
  • Monitoring
    • Stats
    • Process List
  • Time machine
  • Compare
  • Blob
  • Encoding / Collation
  • Complexes
  • Backend
    • Configuration
    • Data storage
    • Docker container
  • Compatibility
  • More
    • Offline
    • Business Model
    • Alternatives
Powered by GitBook
On this page

Was this helpful?

  1. Insert

Generator

PreviousInsertNextFramework embed

Last updated 1 year ago

Was this helpful?

The code editor you see is Monaco is configure to eval JS code per column

From functions to Math library, you have full browser javascript support

Don't forget to add a `return` in your code, else nothing you will be generate

The generator will eval your code each n time the number of row you choose. The code don't know other column's code neither previous eval, so you cannot write a incremental counter

You can choose a preset JS function to generate random values but if you leave it blank, it will produce undefined which remove the property/column. It can be used for AutoIncrement/Serial columns or default value

It's exactly the same if you add 'Empty Rows', if you don't set a value, the cell is undefined