Python Forum
SQLite DB integration duplicate columns
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
SQLite DB integration duplicate columns
#2
you need to change this line

 
sql_query = "CREATE TABLE %s (%s)" % (tablename, ", ".join(["%s TEXT" % col for col in row ]))
with

sql_query = "CREATE TABLE %s (%s)" % (tablename, ", ".join(["%s_TEXT" % col.replace(' ', '_') for col in row ]))
note that you have space also in %s TEXT
Reply


Messages In This Thread
RE: SQLite DB integration duplicate columns - by buran - Oct-27-2017, 11:20 AM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Active Directory integration dady 2 580 Oct-13-2023, 04:02 AM
Last Post: deanhystad
  Help with Integration Pandas excel - Python Gegemendes 5 1,982 Jun-05-2022, 09:46 PM
Last Post: Gegemendes
  Create SQLite columns from a list or tuple? snakes 6 9,046 May-04-2021, 12:06 PM
Last Post: snakes
Photo Integration of apache spark and Kafka on eclipse pyspark aupres 1 3,865 Feb-27-2021, 08:38 AM
Last Post: Serafim
  Tableau Time Series Prediction using Python Integration tobimarsh43 0 1,976 Jul-24-2020, 10:38 AM
Last Post: tobimarsh43
  R-PYTHON INTEGRATION RELATED PROBLEM arnab93 0 1,487 Jun-05-2020, 02:07 PM
Last Post: arnab93
  STATA/Python Integration jprender 0 1,896 May-03-2020, 09:38 PM
Last Post: jprender
  Sqlite CONCAT columns issac_n 4 5,269 Mar-22-2020, 09:31 AM
Last Post: buran
  Integration of a complex function having singularities using quad amjad26 0 5,786 May-17-2019, 09:16 PM
Last Post: amjad26
  phython language java integration jammytcs123123 1 2,350 Jul-04-2018, 03:13 AM
Last Post: Skaperen

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020