public class JdbcHelper.Table extends Object
public Table(String key, String tableName) throws SQLException
SQLException
@Comment(value="\u83b7\u53d6\u8868\u6240\u5728\u6570\u636e\u5e93\u540d\u79f0") public String getDatabaseName() throws SQLException
SQLException
@Comment(value="\u83b7\u53d6\u8868\u6240\u5728\u6570\u636e\u5e93\u7c7b\u578b\uff1amysql,mssql,oracle") public String getDatabaseType() throws SQLException
SQLException
@Comment(value="\u5355\u8868\u6279\u91cf\u66f4\u65b0") public int[] batchUpdate(@Comment(value="\u4f8b\u5982\uff1a[{id:1,name:\'name\',old:23},{id:2,name:\'name\',old:23}]") List<Map<String,Object>> data) throws SQLException
data
- SQLException
public int[] batchUpdate(Map<String,Object>[] data) throws SQLException
data
- SQLException
@Comment(value="\u5355\u8868\u6279\u91cf\u66f4\u65b0") public int update(@Comment(value="\u4f8b\u5982\uff1a{id:2,name:\'name\',old:3}") Map<String,Object> dataMap) throws SQLException
dataMap
- SQLException
@Comment(value="\u8bbe\u7f6e\u4e3b\u952e\u540d\uff0c\u9ed8\u8ba4:id") public JdbcHelper.Table primary(@Comment(value="\u4f8b\u5982: id,no....") String... primaryKey)
public JdbcHelper.Table where(String where)
@Comment(value="\u6839\u636e\u662f\u5426\u5305\u62ecID\u9879\uff0c\u6765\u51b3\u5b9a\u662f\u5426\u66f4\u65b0\u8fd8\u662f\u63d2\u5165\u6570\u636e") public int save(@Comment(value="\u4f8b\u5982: {field1\uff1a1\uff0cfield2:\'val1\'}") Map<String,Object> dataMap) throws SQLException, TokenAuthenticationException
dataMap
- SQLException
TokenAuthenticationException
@Comment(value="\u6570\u636e\u683c\u5f0f\u9a8c\u8bc1") public void validate(@Comment(value="\u4f8b\u5982: {field1\uff1a1\uff0cfield2:\'val1\'}") Map<String,Object> dataMap) throws SQLException
dataMap
- SQLException
@Comment(value="\u6839\u636e\u5b57\u6bb5\u4fe1\u606f\uff0c\u9a8c\u8bc1\u6570\u636e\u683c\u5f0f") public void validate(@Comment(value="\u8868\u5b57\u6bb5\u63cf\u8ff0") Map<String,Map<String,Object>> fieldMap, @Comment(value="\u4f8b\u5982: {id\uff1a3\uff0cname:\'name\',old:3}") Map<String,Object> dataMap) throws SQLException
fieldMap
- dataMap
- SQLException
@Comment(value="\u521d\u59cb\u5316\u6570\u636e\u683c\u5f0f") public Map<String,Object> initialByInsert(@Comment(value="\u4f8b\u5982: {id\uff1a3\uff0cname:\'name\',old:3}") Map dataMap) throws SQLException
SQLException
@Comment(value="\u6839\u636e\u8868\u5b57\u6bb5\u7684\u9ed8\u8ba4\u6570\u636e\u53bb\u521d\u59cb\u5316\u5b57\u6bb5\u503c") public Map<String,Object> initialByInsert(@Comment(value="\u8868\u5b57\u6bb5\u4fe1\u606f") Map<String,Map<String,Object>> fieldMap, @Comment(value="\u4f8b\u5982: {id\uff1a3\uff0cname:\'name\',old:3}") Map<String,Object> dataMap) throws SQLException
SQLException
@Comment(value="\u6839\u636e\u8868\u5b57\u6bb5\u7684\u9ed8\u8ba4\u6570\u636e\u53bb\u521d\u59cb\u5316\u5b57\u6bb5\u503c") public Map<String,Object> initialByUpdate(@Comment(value="\u4f8b\u5982: {id\uff1a3\uff0cname:\'name\',old:3}") Map<String,Object> dataMap) throws SQLException
SQLException
@Comment(value="\u6839\u636e\u8868\u5b57\u6bb5\u7684\u9ed8\u8ba4\u6570\u636e\u53bb\u521d\u59cb\u5316\u5b57\u6bb5\u503c") public Map<String,Object> initial(@Comment(value="\u4f8b\u5982: {id\uff1a3\uff0cname:\'name\',old:3}") Map<String,Object> dataMap) throws SQLException
SQLException
@Comment(value="\u6839\u636e\u8868\u7ed3\u6784\u683c\u5f0f\u5316\u6570\u636e") public void formatValue(@Comment(value="\u4f8b\u5982: {id\uff1a3\uff0cname:\'name\',old:3}") Map<String,Object> dataMap) throws SQLException
dataMap
- SQLException
@Comment(value="\u5355\u8868\u6279\u91cf\u63d2\u5165") public int[] batchInsert(@Comment(value="\u4f8b\u5982: [{id:3,name:\'name\',old:3},{id:2,name:\'name\',old:3}]") List<Map<String,Object>> data) throws SQLException
data
- SQLException
public int[] batchInsert(Map<String,Object>[] dataList) throws SQLException
dataList
- SQLException
@Comment(value="\u6839\u636e\u8868\u7ed3\u6784\u83b7\u53d6\u63d2\u5165\u8bed\u53e5") public String getSQLInsert() throws SQLException
SQLException
@Comment(value="\u5355\u8868\u63d2\u5165\u6570\u636e") public int insert(@Comment(value="\u4f8b\u5982: {id\uff1a3\uff0cname:\'name\',old:3}") Map<String,Object> dataMap) throws SQLException
dataMap
- SQLException
@Comment(value="\u6839\u636e\u4e3b\u5065\u5220\u9664\u6570\u636e") public int delete(@Comment(value="\u4f8b\u5982\uff1a1\u6216\u8005\u5b57\u7b26\u4e32") Object id)
id
- Map , String ,long,int@Comment(value="\u6839\u636e\u4e3b\u5065\u6279\u91cf\u5220\u9664\u6570\u636e") public int[] batchDelete(@Comment(value="\u4f8b\u5982: [1,2,3]") List<Object> ids)
ids
- public int[] batchDelete(Object[] ids)
ids
- Copyright © 2025. All rights reserved.