<?xml version="1.0" encoding="UTF-8"?>
<databaseChangeLog
        xmlns="http://www.liquibase.org/xml/ns/dbchangelog"
        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xmlns:ext="http://www.liquibase.org/xml/ns/dbchangelog-ext"
        xsi:schemaLocation="http://www.liquibase.org/xml/ns/dbchangelog http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-3.0.xsd
        http://www.liquibase.org/xml/ns/dbchangelog-ext http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-ext.xsd">
    <changeSet id="101" author="jian">
        <sql dbms="mysql" endDelimiter=";;" splitStatements="true" stripComments="true">
        <![CDATA[
            USE direct_delivery;;
            
            DROP EVENT IF EXISTS ev_reset_encoding_assets;;
            
            CREATE DEFINER = 'theorchard_dd'@'127.0.0.1' EVENT ev_reset_encoding_assets
            ON SCHEDULE EVERY 1 DAY STARTS '2014-12-04 13:36:38' 
            ON COMPLETION NOT PRESERVE 
            DISABLE ON SLAVE 
            DO BEGIN CALL sp_reset_encoding_assets(); END;;
        ]]>
        </sql>
        <rollback>
            <sql dbms="mysql" endDelimiter=";;" splitStatements="true" stripComments="true">
            <![CDATA[
                USE direct_delivery;;

                DROP EVENT IF EXISTS ev_reset_encoding_assets;;
            ]]>
            </sql>
        </rollback>
    </changeSet>
</databaseChangeLog>
