SQLite Forum

Create a trigger without a name, BUG?
The SQL:


Simply means: Create a Trigger named "AFTER" that gets called on UPDATE of "Proda_Page"....

So to the parser cannot read human intent, it can only read actual SQL, and if you put the word "AFTER" where it expects a name of a trigger, then it must assume your intent is to name that trigger "AFTER".

Unlike Dominique, I can't really see the "one would hope to error on" thing.  I'd like my parsers not to think for me and do what I say, not what it thinks I may have meant. If I really wanted to call my trigger so, why should the parser stop me?

This whole protecting people from themselves is Microsoft and Apple-ish nonsense that should be killed with fire. One designs things how you want it, and then tests if it is working, and if not, read the manual and debug. This is great for learning - you would never again make the mistake of misnaming a trigger, or at least, if your next trigger doesn't work, you'd immediately know where to check first. That is great, to my mind.

I do however agree (as I think Dominique specifically requested before, maybe others) that such things should be documented. (Perhaps the word I'm looking for is "documentationally mentioned"?).
There is indeed a pitfalls page in SQLite forum (I'm not sure if this one is mentioned on it) but I think it should gain a more prominent placement.

While on the subject, these three items I think should have prominent links on the main page of SQLite, AND on the new online forum page:
  - When To Use
  - How to Corrupt
  - SQLite common Pitfalls
Because, those 3 pages together answer 99% of questions posted here.