首页| JavaScript| HTML/CSS| Matlab| PHP| Python| Java| C/C++/VC++| C#| ASP| 其他|
购买积分 购买会员 激活码充值

您现在的位置是:虫虫源码 > 其他 > clione-sql

clione-sql

资 源 简 介

Welcome ClioneSQL is a library for generating SQL easily and safety. First Sample If you use ClioneSQL, you can write find method as follows. -method import static tetz42.clione.SQLManager.*; : public List findAllByAgeAndPref(Integer age, String pref) throws SQLException { return sqlManager().useFile(getClass(), "Select.sql") .findAll( Entity.class, params("age", age).$("pref", pref) ); } -"Select.sql" SELECT * FROM people WHERE age = /* $age */25 AND prefecture = /* $pref */"Tokyo" The parameters of "Select.sql" is specified as SQL comment. So it can be performed by general SQL client tools. ClioneSQL replaces /* $age */ and /* $pref */ to place holders as follows: SEL
VIP VIP
0.181869s