SQL CREATE TABLE Generator
Infer column types from sample data and emit CREATE TABLE for PostgreSQL, MySQL, SQLite, or SQL Server.
CREATE TABLE
</>Use this tool programmaticallycurl · JavaScript · MCP
Same tool, callable from any HTTP client or from Claude (via MCP). Anonymous: 100 req/day per IP. Sign up for 1,000 req/day.
curl
curl https://api.b-e-a-d.com/tools/sql-create-table-generator/run \
-H "Content-Type: application/json" \
-d '{
"input": "your input here",
"tableName": "a",
"dialect": "postgres",
"ifNotExists": true
}'JavaScript (fetch)
const res = await fetch("https://api.b-e-a-d.com/tools/sql-create-table-generator/run", {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify({
"input": "your input here",
"tableName": "a",
"dialect": "postgres",
"ifNotExists": true
}),
});
const data = await res.json();
console.log(data.result);MCP (Claude Desktop / Claude Code)
# In Claude Desktop / Claude Code, add to your MCP config:
{
"mcpServers": {
"bead": {
"command": "npx",
"args": ["-y", "mcp-remote", "https://mcp.b-e-a-d.com"]
}
}
}
# Then ask Claude to call:
mcp__bead__bead_sql_create_table_generatorFull reference: developer docs · OpenAPI spec
Type inference
Each column is scanned: if every value parses as an integer, it picks INT (or BIGINT when values get large); decimals become NUMERIC; date-like strings become DATE or TIMESTAMP; everything else is VARCHAR(n) sized to the longest sample.
Dialect quirks
PostgreSQL uses SERIAL/BIGSERIAL; MySQL uses AUTO_INCREMENT; SQLite folds everything to flexible type affinity. The generator picks the right primary-key syntax for the dialect you choose.
You might also like
- SQL INSERT GeneratorConvert CSV / TSV / JSON into INSERT INTO statements — multi-row VALUES or one statement per row.
- SQL Result → Table PreviewPaste CSV, TSV, pipe-delimited, or JSON results and preview them as a styled table with inferred column types.
- CSV ↔ JSON ConverterConvert CSV to JSON or JSON to CSV with quoted fields and configurable delimiters.
- cURL ConverterParse a curl command and emit fetch, Node https, Python requests, Ruby Net::HTTP, Go net/http, PowerShell, HTTPie, and wget equivalents.