An interpreter implemented with .Net Core for JtSQL
- Hello World
- Lexer
- Parser
- SQL Executor
Chakilo.JtSQL.Run(new Chakilo.Linq.Work("Your JtSQL code here"));
-
Using placeholder in sql().
$<SELECT * FROM `user` WHERE user_id > {{0}} AND user_id < {{Math.abs(5)}};>
will be compiled into
sql("SELECT * FROM `user` WHERE user_id > ? AND user_id < ?;", 0, Math.abs(5))
-
Semicolons may be omitted.
Both
for (;;) { if (condition) { var result = $<SELECT * FROM {{table}};>; }; };
and
for (;;) {if (condition) {var result = $<SELECT * FROM {{table}}>}}
are avaliable.
-
Inline comments supported.
// get id by username var user_id = $<SELECT user_id FROM `user` WHERE username = {{username}} LIMIT 1;>
See also noear/JtSQL