lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


On Fri, Feb 5, 2010 at 10:14 AM, Vasanta <vtanna1@gmail.com> wrote:
> I found this string in sql file, does lua accepts "AFTER" instead "BEFORE"?
>
> CREATE TRIGGER "fk_eventLog_component_ins_on_eventLog" BEFORE INSERT ON
> eventLog FOR EACH ROW


these are SQL things, not Lua things.   any Lua SQL library simply
forwards the commands to the SQL library; it doesn't 'accept' one or
another syntax.

that 'BEFORE' is about trigger creation.  a totally different SQL
feature, it has _nothing_ to do with 'table ordering'.  Also remember
that as both Ge' and pan shizhu already said, an SQL database table
DOESN'T HAVE ORDER.  what you do is to ask in what order you want the
results when you ask for them.

you really need to learn some SQL for this.


-- 
Javier