~olly/yoyo#102: 
cx_oracle _yoyo_log "comment" column

In oracle, comment is a keyword... it cannot be used in a schema definition as:

CREATE TABLE "_yoyo_log" ( id VARCHAR(36), migration_hash VARCHAR(64), migration_id VARCHAR(255), operation VARCHAR(10), username VARCHAR(255), hostname VARCHAR(255), comment VARCHAR(255), created_at_utc TIMESTAMP, PRIMARY KEY (id))

you need to add doublequotes in order to avoid this issue in internalmigrations/v2.py

def create_log_table(backend): backend.execute( "CREATE TABLE {0.log_table_quoted} ( " "id VARCHAR(36), " "migration_hash VARCHAR(64), " "migration_id VARCHAR(255), " "operation VARCHAR(10), " "username VARCHAR(255), " "hostname VARCHAR(255), " ""comment" VARCHAR(255), " "created_at_utc TIMESTAMP, " "PRIMARY KEY (id))".format(backend) )

But the comment column is really used? _yoyo_log seems to be used only in base.py and there the insert stament do not fullfill the "comment" column. Or I'm wrong?

Status
RESOLVED FIXED
Submitter
~ralcini
Assigned to
No-one
Submitted
8 months ago
Updated
8 months ago
Labels
No labels applied.

~ralcini 8 months ago

"comment" value as None is bassed as parameter to the query executed causing an insert error because not used...

~olly REPORTED FIXED 8 months ago

Fixed in 914dff3af4bd and e41b0a93a750

Register here or Log in to comment, or comment via email.