Menu
100% Client-Side • In-Browser Execution • Privacy Guaranteed

SQL Mock & Test Data Generator Online

Generate realistic SQL test datasets and seed INSERT statements online for MySQL, PostgreSQL, SQLite, and SQL Server. Customize schemas or parse CREATE TABLE DDL locally in your browser.

Generate realistic, production-like synthetic test data and batch INSERT statements for your database without sharing sensitive production records or connecting to a live server. Choose from realistic business schema presets (Users, Orders, Products, Customers), configure custom column types and value ranges, or paste a CREATE TABLE DDL statement to auto-detect columns. Generates dialect-compliant SQL for MySQL, PostgreSQL, SQLite, and SQL Server with batch chunking up to 1,000 rows. All generation runs 100% locally in your browser—no schemas or data are sent over the network.

The SQL Mock Data Generator requires JavaScript to run in your browser. Please enable JavaScript to use this tool.

Why Generate Synthetic SQL Test Data?

Developing applications against real production database dumps introduces serious privacy, compliance, and reliability hazards:

  1. Regulatory Compliance (GDPR, HIPAA, CCPA): Exporting real customer PII (Personally Identifiable Information) like email addresses, phone numbers, and physical addresses to local developer workstations or staging environments violates data privacy mandates.
  2. Deterministic & Repeatable CI/CD Testing: Automated test suites require consistent starting states. Generating synthetic seeds allows tests to run predictably without depending on stateful external databases.
  3. Edge Case Validation: Synthetic generators let you test boundaries that rarely occur in real data, such as zero balances, large numbers, mixed character casing, and extreme date ranges.
  4. Instant In-Browser Experimentation: Paired with our SQLite SQL Playground, you can generate 100 rows of relational data and test query joins, window functions, and indexing strategies in seconds without installing any database server locally.

For an end-to-end tutorial on synthetic dataset design, check out our guide on How to Generate Realistic SQL Mock Data for Testing.

Supported Data Types and Formatting

The generator produces clean, escaped values customized for each column type:

Generator Type Output Description Configuration Syntax (Extra) Example Output
Sequence / Auto ID Incremental integer counter start,step (e.g. 1,1 or 1001,1) 1, 2, 3
UUID (v4) RFC 4122 compliant UUID v4 string None '8f1b2c3d-4e5f-4a1b-9c8d-7e6f5a4b3c2d'
First Name Realistic human given name None 'James', 'Sarah', 'Elena'
Last Name Realistic human surname None 'Miller', 'Zhang', 'Patel'
Full Name Combined first and last name None 'David Rodriguez', 'Emma Watson'
Username Lowercase sanitized handle with digits None 'sarah_42', 'm_chen_89'
Email Address Safe synthetic domain email None '[email protected]'
Phone Number Standard US formatted phone None '555-248-1934'
Random Integer Uniform random integer min,max (e.g. 1,100) 42, 87
Decimal / Price Fixed-point numeric string min,max,decimals (e.g. 9.99,499.99) 29.99, 149.50
Boolean Dialect-compliant boolean literal % true (e.g. 85 for 85% true) TRUE/FALSE or 1/0
Status / Enum Pick from custom comma-separated list val1,val2,val3 'pending', 'shipped'
Date ISO 8601 calendar date (YYYY-MM-DD) days_back (e.g. 365) '2026-04-12'
Timestamp Datetime timestamp days_back (e.g. 180) '2026-08-21 14:32:08'
City Global metropolitan city name None 'London', 'Tokyo', 'Berlin'
Country Country name None 'United States', 'Germany'
Order Code Alphanumeric business reference prefix (e.g. ORD-) 'ORD-729410'
Product SKU Retail inventory identifier prefix (e.g. SKU-) 'SKU-8192-3401'

Multi-Dialect Batch INSERT Constraints

Different relational database engines impose strict limits on multi-row INSERT INTO ... VALUES (...) statements:

  • MySQL & MariaDB: Governed by the max_allowed_packet server variable (default 64MB in modern versions). Backtick quoting (`users`) is standard for table and column identifiers.
  • PostgreSQL: Standard SQL double quotes ("users"). PostgreSQL supports tens of thousands of rows per INSERT, limited only by RAM and query buffer size.
  • SQLite: Historically limited by SQLITE_MAX_VARIABLE_NUMBER (999 before SQLite 3.32.0; 32,766 in modern releases). Using chunks of 100 to 500 rows avoids parameter limit overflows.
  • SQL Server (T-SQL): Enforces an explicit hard limit of 1,000 rows per single multi-row VALUES (...) clause (Database Engine Error 10738). The mock data generator automatically chunks batches at <= 1,000 rows and uses bracketed identifiers ([users]). When a generated column uses IDENTITY, the SQL includes explicit seed values; the output therefore wraps its INSERT batches with SET IDENTITY_INSERT [table] ON and OFF. Running this script requires permission to change that setting, and only one table per session can have it enabled at a time. Review generated SQL before running it against an existing table.

Frequently Asked Questions

Does this tool send any schemas or generated data to a server?

No. All random number generation, string formatting, DDL parsing, and SQL generation occur entirely in client-side JavaScript within your web browser tab. No database credentials, schema names, or generated records are transmitted to SQLiz or any external party.

Can I test the generated SQL immediately?

Yes! Click the “Test in SQLite Playground →” button. The generated CREATE TABLE and INSERT batch will be loaded directly into our in-browser SQLite SQL Playground using secure browser session storage, allowing you to run SELECT, GROUP BY, and window functions against your test dataset instantly.

How does the CREATE TABLE DDL extractor work?

When you paste a CREATE TABLE statement into the collapsible DDL section and click “Extract Columns from DDL”, a regex tokenizer extracts the table name and parses each column definition. It inspects column names and types (e.g., VARCHAR, INT, DECIMAL, BOOLEAN, TIMESTAMP, UUID) and automatically maps them to the most appropriate synthetic generator preset.