loadcsv

Load a csv file into a database
Download

loadcsv Ranking & Summary

Advertisement

  • Rating:
  • License:
  • GPL
  • Price:
  • FREE
  • Publisher Name:
  • Ferran Pegueroles Forcadell
  • Publisher web site:
  • http://www.pegueroles.com/

loadcsv Tags


loadcsv Description

Load a csv file into a database loadcsv is a small utility to load CSV files into a database.The utility gets the names of the columns from the first row of the CSV file.Developer commentsI wrote this utility because I was tired of doing always small scripts for doing this kind os loads.By now the utility suport MySQL, PostgresSQL and sqlite, but can be used with other SQL databases using the utility to generate the SQL statements and sending them to the database.Usage: loadcsv filename.csvIf no database provided, display SQL to stdoutOptions: -h, --help show this help message and exit -D DRIVER, --driver=DRIVER database driver mysql, pgsql, sqlite -H HOSTNAME, --hostname=HOSTNAME database server hostname,defaults to localhost -d DBNAME, --dbname=DBNAME database name (filename on sqlite) -u USER, --user=USER database username -p PASSWORD, --password=PASSWORD database password -P PORT, --port=PORT database port -t TABLE, --table=TABLE database table to load --test run text, do no commit to the database --delimiter=DELIMITER CSV file field delimiter, by default semi-colon~ Requirements: · Python


loadcsv Related Software