Skip to content
>_ TrueFileSize.com

Sample SQL Files — Database Dump Downloads for Testing

Download free sample SQL files for MySQL, PostgreSQL, and SQLite. Includes user tables, ecommerce schemas, blog databases, and large dumps up to 100,000 rows. Schema-only and data-only variants available.

sample-mysql.sql

55.2 KB

1,000 rows

Verified file details
Filename
sample-mysql.sql
Exact size
56,547 bytes
Displayed size
55.2 KB
MIME type
application/sql
Rows
1,000
License
CC0 / Public Domain
Download URL
https://truefilesize.com/files/sql/sample-mysql.sql

sample-postgresql.sql

55.4 KB

1,000 rows

Verified file details
Filename
sample-postgresql.sql
Exact size
56,771 bytes
Displayed size
55.4 KB
MIME type
application/sql
Rows
1,000
License
CC0 / Public Domain
Download URL
https://truefilesize.com/files/sql/sample-postgresql.sql

sample-sqlite.sql

55.2 KB

1,000 rows

Verified file details
Filename
sample-sqlite.sql
Exact size
56,555 bytes
Displayed size
55.2 KB
MIME type
application/sql
Rows
1,000
License
CC0 / Public Domain
Download URL
https://truefilesize.com/files/sql/sample-sqlite.sql

sample-users-table.sql

27.7 KB

500 rows

Verified file details
Filename
sample-users-table.sql
Exact size
28,413 bytes
Displayed size
27.7 KB
MIME type
application/sql
Rows
500
License
CC0 / Public Domain
Download URL
https://truefilesize.com/files/sql/sample-users-table.sql

sample-ecommerce.sql

245 KB

5,000 rows

Verified file details
Filename
sample-ecommerce.sql
Exact size
251,375 bytes
Displayed size
245 KB
MIME type
application/sql
Rows
5,000
License
CC0 / Public Domain
Download URL
https://truefilesize.com/files/sql/sample-ecommerce.sql

sample-blog.sql

228 KB

2,000 rows

Verified file details
Filename
sample-blog.sql
Exact size
233,200 bytes
Displayed size
228 KB
MIME type
application/sql
Rows
2,000
License
CC0 / Public Domain
Download URL
https://truefilesize.com/files/sql/sample-blog.sql

sample-schema-only.sql

528 B
Verified file details
Filename
sample-schema-only.sql
Exact size
528 bytes
Displayed size
528 B
MIME type
application/sql
License
CC0 / Public Domain
Download URL
https://truefilesize.com/files/sql/sample-schema-only.sql

sample-data-only.sql

110 KB

2,000 rows

Verified file details
Filename
sample-data-only.sql
Exact size
112,766 bytes
Displayed size
110 KB
MIME type
application/sql
Rows
2,000
License
CC0 / Public Domain
Download URL
https://truefilesize.com/files/sql/sample-data-only.sql

sample-large.sql

5.38 MB

100,000 rows

Verified file details
Filename
sample-large.sql
Exact size
5,640,359 bytes
Displayed size
5.38 MB
MIME type
application/sql
Rows
100,000
License
CC0 / Public Domain
Download URL
https://truefilesize.com/files/sql/sample-large.sql

Sample SQL file preview

Users table (MySQL)

CREATE TABLE users (
  id INT PRIMARY KEY AUTO_INCREMENT,
  username VARCHAR(50) NOT NULL,
  email VARCHAR(100) UNIQUE NOT NULL,
  created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP
);

INSERT INTO users (username, email) VALUES
('alice_johnson', '[email protected]'),
('bob_smith', '[email protected]');

How to import a SQL file

MySQL

mysql -u root -p database_name < sample-mysql.sql

PostgreSQL

psql -U username -d database_name -f sample-postgresql.sql

SQLite

sqlite3 database.db < sample-sqlite.sql

phpMyAdmin

Import tab → Choose file → Select the .sql file → Execute. Works with all MySQL-compatible SQL files.

Use cases for sample SQL files

  • Seeding development and staging databases
  • Testing database migration scripts
  • Verifying SQL import/export functionality
  • Testing ORM compatibility (Prisma, Sequelize, SQLAlchemy)
  • Load testing databases with large datasets
  • Testing schema-only vs data-only import flows

Technical specifications

DialectsMySQL, PostgreSQL, SQLite
ContentCREATE TABLE + INSERT statements
DataFaker.js-generated realistic dummy data
SchemasUsers, ecommerce (8 tables), blog (5 tables)
Size range10 KB to 5 MB (up to 100K rows)

Frequently Asked Questions

Are these SQL files compatible with my database?
We provide separate files for MySQL, PostgreSQL, and SQLite — each uses the correct dialect syntax. The MySQL files also work with MariaDB and Percona. Choose the file matching your database engine.
What is the difference between schema-only and data-only?
Schema-only (sample-schema-only.sql) contains only CREATE TABLE statements — no data. Data-only (sample-data-only.sql) contains only INSERT statements — assumes tables already exist. Use them to test separate schema migration and data seeding flows.
Is the data in these SQL files real?
No. All data is generated with faker.js — realistic usernames, emails, and addresses but entirely fictional. Safe for development, testing, and demos.
What tables does the ecommerce schema include?
8 tables: users, products, categories, orders, order_items, payments, addresses, and reviews. 5,000 total rows with foreign key relationships between all tables.
Can I use these with an ORM like Prisma or SQLAlchemy?
Yes. Import the SQL dump to create the database, then connect your ORM. For Prisma, use prisma db pull to introspect the schema. For SQLAlchemy, use automap_base() to reflect tables.

Other data formats

Related reading