Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- text_file = open("x.txt", "r")
- with open("x.sql", "a") as f:
- for line in text_file:
- b = line.split(";")
- text = b[1]
- sys = b[2].replace("'", "")[1:-2]
- print("INSERT INTO \"public\".\"x\" VALUES ( default, '{}', '{}' );".format(text, sys), file=f)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement