SQLAlchemy列名称在Python中保留

时间:2019-11-08 11:26:23

标签: python sqlalchemy

我正在使用SQLAlchemy,我想插入一些数据。我有一列名为“ class”的列,由于其保留的关键字列表,我必须将其插入,当然还有Python错误:

                self.db_connection.execute( self.common_template_table.insert().values(template_label=label,
                                                                                       **class**=class_of_template,
                                                                                       security_level=security_level,
                                                                                       condition=condtion,
                                                                                       template_type=type,
                                                                                       aco_id=aco_id,
                                                                                       service_id=service_id, 
                                                                                       translation_id=translation_id,
                                                                                       connect_point_id=cp_id, 
                                                                                       schema_enforcement_id=schema_id,
                                                                                       template_id=temp_object.id ))

有没有办法解决这个问题?

0 个答案:

没有答案