Es sql query
From EventScripts Community Encyclopedia
|
[edit] OverviewSyntax: Note: Command parameters are described inside the
< and > characters. Optional parameters are contained within [ and ] characters.Variation of this command that doesn't expand variables: es_xsql query [edit] DescriptionExecutes a SQL statement against a SQLite database and returns the results, optionally, in a keygroup. [edit] Parameters
[edit] ExamplesSee the ServerMail example in ES v1.5 for a detailed example. // open a SQLite database file, creates/opens es_mydb.sqldb es_sql open mydb |myscript es_sql query mydb mykeygroup "SELECT * FROM mytable WHERE myname='Mattie';" es_foreachkey mykey in mykeygroup "es_msg Found a result!" // ... // quick query where we don't care about the return es_sql query mydb "INSERT INTO mytable (myname, mymoney) VALUES ('Venjax', 9999);"
[edit] Notes
[edit] See also
|
