Like fuzzy query for oracle, mysql, db2, and SQL server in Mybatis, mybatisdb2
<! -- Oracle --> <select id = "searchUserBySearchName" parameterType = "java. lang. string "resultType =" com. urm. entity. user "> select * from t_user where user_name like CONCAT ('%', # {search_name}, '%') </select> <! -- Or --> <select id = "searchUserBySearchName" parameterType = "java. lang. string "resultType =" com. urm. entity. user "> select * from t_user where user_name like '%' | # {search_name} | '%' </select> <! -- Mysql --> <select id = "searchUserBySearchName" parameterType = "java. lang. string "resultType =" com. urm. entity. user "> select * from t_user where user_name like CONCAT ('%', # {search_name}, '%') </select> <! -- SQL server --> <select id = "searchUserBySearchName" parameterType = "java. lang. string "resultType =" com. urm. entity. user "> select * from t_user where user_name like '%' + # {search_name} + '%' </select> <! -- Db2 --> <select id = "searchUserBySearchName" parameterType = "java. lang. string "resultType =" com. urm. entity. user "> select * from t_user where user_name like CONCAT ('%', # {search_name}, '%') </select> <! -- Or --> <select id = "searchUserBySearchName" parameterType = "java. lang. string "resultType =" com. urm. entity. user "> select * from t_user where user_name like '%' | # {search_name} | '%' </select>
Different database languages: SQL server, Oracle, mysql, db2''
There are too many database system types. To put it simply, ACESS is suitable for small websites. asp and MYSQL are recommended for new websites. SQL Server is suitable for medium-sized websites and PHP is recommended for small websites. ORACLE is suitable for large websites and JSP is recommended for large websites! ~! ~! You can search for details!
Differences between mysql, oracle, db2, and SQL Server
Mysql is an open-source, free, small-sized, and concurrently executed database. Mysql is generally enough for applications, and it still needs to be upgraded in terms of exception handling. It is used for website design and small software. PHP + mysql is hailed as a perfect combination.
SQL server is Microsoft Data, which is easy to use and simple and suitable for beginners. It is generally used in. net programming.
Oracle is a large database with a large volume. It supports running multiple instances at the same time and is very powerful.