Re: [sqlalchemy] delete not working on fk relation: sqlalchemy.exc.IntegrityError: (pymysql.err.IntegrityError) (1451, 'Cannot delete or update a parent row: a foreign key constraint fails

2019-05-15 Thread Jan Sakalos
Hi, today i was doing more troubleshooting and was reducing ReportModel relationships to be 'identical' to ScanModel. Once it was reduced it worked and during checks of db fk config i noticed, that in tables relation there was defined not only composite, but also single keys relation. I realized

[sqlalchemy] delete not working on fk relation: sqlalchemy.exc.IntegrityError: (pymysql.err.IntegrityError) (1451, 'Cannot delete or update a parent row: a foreign key constraint fails

2019-05-14 Thread Jan Sakalos
Hello, i am unable to delete ReportModel entry, because of: sqlalchemy.exc.IntegrityError: (pymysql.err.IntegrityError) (1451, 'Cannot delete or update a parent row: a foreign key constraint fails (`qualys_guard`.`report_server2patch`, CONSTRAINT `report_server2patch_ibfk_3` FOREIGN KEY (`rep