Escape single quotes by doubling them up.
This commit is contained in:
parent
a2337346fb
commit
dcf84dedf8
1 changed files with 1 additions and 0 deletions
|
@ -145,6 +145,7 @@ def literal(item):
|
|||
return f'{item:f}'
|
||||
|
||||
elif isinstance(item, str):
|
||||
item = item.replace("'", "''")
|
||||
return f"'{item}'"
|
||||
|
||||
elif isinstance(item, bytes):
|
||||
|
|
Loading…
Reference in a new issue