문제

Just wanted to know if it is possible to create database triggers in a MySQL database using web2py's DAL? If not what alternatives are available?

I need some way of linking back to some python code from a trigger that happens in MySQL.

Thanks in advance, nav

도움이 되었습니까?

해결책

The web2py DAL does not have specific syntax for creating triggers, but you can execute any SQL statements via db.executesql(). As an alternative, the web2py DAL includes its own before and after callbacks, which will work across different database backends.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top