No project description provided
Project description
table2sql
Python CLI tool which allows you to convert file with table (CSV and Excel) to SQL insert statements.
Basic usage
some.csv
a,b,c,d
int,str,float,sql
1,2,3,(SELECT id FROM another.table WHERE name = 'Paul')
5,6,7,(SELECT id FROM another.table WHERE name = 'Paul')
Command:
table2sql some.csv --output-table some.table --has-types-row
Result:
INSERT INTO some.table (a, b, c, d)
VALUES (1, '2', 3.0, (SELECT id FROM another.table WHERE name = 'Paul')), (5, '6', 7.0, (SELECT id FROM another.table WHERE name = 'Paul'));
Install
pip install table2sql
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
table2sql-1.0.5.tar.gz
(4.7 kB
view details)
Built Distribution
File details
Details for the file table2sql-1.0.5.tar.gz
.
File metadata
- Download URL: table2sql-1.0.5.tar.gz
- Upload date:
- Size: 4.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.2.0a2 CPython/3.8.12 Linux/5.13.0-1025-azure
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | ec936816ab3a25ab641bca6c7b64d6fe55a5266345831dd7dcc98c447db74f9b |
|
MD5 | 769c31fd0803ff7f7321b6fd9c509feb |
|
BLAKE2b-256 | 71acceba03953269d02d20cc7974c4eac4a33da129ef147c1e5b1684225d6205 |
File details
Details for the file table2sql-1.0.5-py3-none-any.whl
.
File metadata
- Download URL: table2sql-1.0.5-py3-none-any.whl
- Upload date:
- Size: 5.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.2.0a2 CPython/3.8.12 Linux/5.13.0-1025-azure
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 42190e2491ba53739e7eedcc1d0c8cb04d7e581c938f55c5ce67e446292027ea |
|
MD5 | 30aefa31af5a37d1207be5b604a15415 |
|
BLAKE2b-256 | 70b5318b226a5bb8745860e5f41aff402dba2888aacbec640b615cc9c91e56ac |