Answers for "sqlite to csv statement"

SQL
0

sqlite to csv statement

import pandas as pd

conn = sqlite3.connect(db_file, isolation_level=None,
                       detect_types=sqlite3.PARSE_COLNAMES)
db_df = pd.read_sql_query("SELECT * FROM table", conn)
db_df.to_csv('database.csv', index=False)
Posted by: Guest on February-08-2021

Code answers related to "SQL"

Browse Popular Code Answers by Language