[Answer]-Adding string values (varchars) to MySQL table without quotation marks with Django/Python

1👍

Strip the quotation using strip

new_value = value[0].strip('"')  # for double quoted strings

You can also do it for single-quoted strings:

new_value = value[0].strip("'")  # for single-quoted strings

Then store it in the database.

👤Kedar

Leave a comment