Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(2)  |  Call(0)  |  Derive(0)  |  Import(2)
Creates DatabaseTriggers.java

Examples:

>>> t1 = Trigger('tr_archive').temp.if_not_exists.before.delete_on('notes')    .do_sql('INSERT INTO archive (noteid,notetext) VALUES (old._id,old.text)')

>>> t2 = Trigger('tr_log').if_not_exists.before.update_on('notes')    .do_sql('INSERT INTO log (noteid,notetext) VALUES (new._id,new.text)')

>>> dt = DatabaseTriggers("com.example.appname.database")
>>> dt.add(t1, t2)(more...)

src/a/n/AndroidCodeGenerator-HEAD/sample_with_trigger.py   AndroidCodeGenerator(Download)
from AndroidCodeGenerator.db_table import (Table, Column, ForeignKey, Unique,
                                           Trigger)
from AndroidCodeGenerator.database_triggers import DatabaseTriggers
 
persons = Table('Person').add_cols(Column('firstname').text.not_null.default("''"),\

src/a/n/AndroidCodeGenerator-HEAD/sample_test.py   AndroidCodeGenerator(Download)
 
from AndroidCodeGenerator.generator import Generator
from AndroidCodeGenerator.db_table import (Table, Column, ForeignKey, Unique,
                                           Trigger)
from AndroidCodeGenerator.database_triggers import DatabaseTriggers