Skip to content

Based on the csv file, generate a sql table capable of storing the generated insert statements #13

@htmfilho

Description

@htmfilho

Is your feature request related to a problem? Please describe.

The problem is when the table I want to import the data doesn't exist yet. I need to spend time creating it so I can run the insert statements.

Describe the solution you'd like

We can deduct the database to store the CSV data from the CSV itself. The solution would be to figure out the table name, columns, and column types, then generate the DDL script to create the table. The code would also verify if all rows of a column contains or not contain value to figure out if the column is null or not null.

The resulting DDL script would be added to the beginning of the script.

Describe alternatives you've considered

The alternative is to create the DDL script ourselves and add it as the prefix of the file. But this job can be automated.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions