Guest User

Untitled

a guest
Oct 17th, 2018
108
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.41 KB | None | 0 0
  1. TypeError: not all arguments converted during string formatting
  2.  
  3. import pandas as pd
  4. import psycopg2
  5. from psycopg2 import sql
  6. import xlsxwriter
  7.  
  8. def func(input):
  9. db_details = conn.cursor() # set DB Cursor
  10.  
  11. db_details.execute(sql.SQL("""select name from store where name = (%s)"""), (input))
  12. names = dwh_cursor.fetchall()
  13.  
  14. df = pd.DataFrame(names,columns=[desc[0] for desc in dwh_cursor.description])
Add Comment
Please, Sign In to add comment