MCPcopy Create free account
hub / github.com/Nemo1870/sql-parse / Select

Class Select

src/main/java/com/sql/parse/statement/Select.java:15–163  ·  view source on GitHub ↗

@date 2019年4月29日上午11:32:02 @desc Select语法操作类

Source from the content-addressed store, hash-verified

13 * @desc Select语法操作类
14 */
15public abstract class Select extends Statement {
16 /*是否替换所有字段*/
17 protected boolean isChangeColumn;
18
19 @Override
20 public abstract String getSql(boolean safe);
21
22 /**
23 * @title: addColumn
24 * @desc: 增加查询字段,支持别名
25 */
26 public abstract Select addColumn(String expr, String alias);
27
28 public abstract Select addColumn(SelectItem item);
29
30 /**
31 * @title: addColumn
32 * @desc: 增加查询字段,不支持别名
33 */
34 public abstract Select addColumn(String expr);
35
36 /**
37 * @title: where
38 * @desc "WHERE"符号
39 */
40 public abstract Select where(String expr);
41
42 /**
43 * @title: removeAllWhere
44 * @desc 移除where条件
45 */
46 public abstract Select removeAllWhere();
47
48 /**
49 * @title: and
50 * @desc "AND"符号
51 */
52 public abstract Select and(String expr);
53
54 /**
55 * @title: or
56 * @desc "OR"符号
57 */
58 public abstract Select or(String expr);
59
60 /**
61 * @title: simpleJoin
62 * @desc "select * form a,b"的JOIN方式
63 */
64 public abstract Select simpleJoin(String tableName);
65
66 public abstract Select simpleJoin(Table table);
67
68 /**
69 * @title: join
70 * @desc "JOIN"符号
71 */
72 public abstract Select join(String tableName, EqualsTo on);

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected