本文整理汇总了Java中net.sf.jsqlparser.statement.select.PlainSelect.getStringList方法的典型用法代码示例。如果您正苦于以下问题:Java PlainSelect.getStringList方法的具体用法?Java PlainSelect.getStringList怎么用?Java PlainSelect.getStringList使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类net.sf.jsqlparser.statement.select.PlainSelect
的用法示例。
在下文中一共展示了PlainSelect.getStringList方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: toString
import net.sf.jsqlparser.statement.select.PlainSelect; //导入方法依赖的package包/类
public String toString() {
String sql = "";
String ifNotExistsStr = this.tableIfNotExists ? "IF NOT EXISTS " : "";
String orReplaceStr = this.orReplaceTable ? "DROP TABLE " + table + ";\n" : "";
sql += orReplaceStr;
sql += "CREATE TABLE " + ifNotExistsStr + table + " (";
sql += PlainSelect.getStringList(columnDefinitions, true, false);
if (indexes != null && indexes.size() != 0) {
sql += ", ";
sql += PlainSelect.getStringList(indexes);
}
sql += ") ";
sql += PlainSelect.getStringList(tableOptionsStrings, false, false);
return sql;
}
示例2: toString
import net.sf.jsqlparser.statement.select.PlainSelect; //导入方法依赖的package包/类
@Override
public String toString() {
String referenceOptions = "";
if(onDeleteReferenceOption != null) {
referenceOptions += " ON DELETE " + onDeleteReferenceOption;
}
if(onUpdateReferenceOption != null) {
referenceOptions += " ON UPDATE " + onUpdateReferenceOption;
}
return super.toString()
+ " REFERENCES " + table + PlainSelect.getStringList(getReferencedColumnNames(), true, true)
+ referenceOptions;
}
示例3: toString
import net.sf.jsqlparser.statement.select.PlainSelect; //导入方法依赖的package包/类
@Override
public String toString() {
String sql;
String createOps = PlainSelect.getStringList(createOptionsStrings, false, false);
sql = "CREATE " + (unlogged ? "UNLOGGED " : "") +
(!"".equals(createOps)?createOps + " ":"") +
"TABLE " + (ifNotExists?"IF NOT EXISTS ":"") + table;
if (select != null) {
sql += " AS " + select.toString();
} else {
sql += " (";
sql += PlainSelect.getStringList(columnDefinitions, true, false);
if (indexes != null && !indexes.isEmpty()) {
sql += ", ";
sql += PlainSelect.getStringList(indexes);
}
sql += ")";
String options = PlainSelect.getStringList(tableOptionsStrings, false, false);
if (options != null && options.length() > 0) {
sql += " " + options;
}
}
return sql;
}
示例4: toString
import net.sf.jsqlparser.statement.select.PlainSelect; //导入方法依赖的package包/类
@Override
public String toString() {
StringBuilder arraySpec = new StringBuilder();
for (Integer item : arrayData) {
arraySpec.append("[");
if (item != null) {
arraySpec.append(item);
}
arraySpec.append("]");
}
return dataType
+ (argumentsStringList != null ? " " + PlainSelect.getStringList(argumentsStringList, true, true) : "")
+ arraySpec.toString()
+ (characterSet != null ? " CHARACTER SET " + characterSet : "");
}
示例5: toString
import net.sf.jsqlparser.statement.select.PlainSelect; //导入方法依赖的package包/类
@Override
public String toString() {
String sql = "DROP " + type + " "
+ (ifExists?"IF EXISTS ":"") + name.toString();
if (parameters != null && !parameters.isEmpty()) {
sql += " " + PlainSelect.getStringList(parameters);
}
return sql;
}
示例6: toString
import net.sf.jsqlparser.statement.select.PlainSelect; //导入方法依赖的package包/类
public String toString() {
String sql = "";
sql = "INSERT INTO ";
sql += table+" ";
sql += ((columns!=null)?PlainSelect.getStringList(columns, true, true)+" ":"");
if(useValues) {
sql += "VALUES "+itemsList+"";
} else {
sql += ""+itemsList+"";
}
return sql;
}
示例7: toString
import net.sf.jsqlparser.statement.select.PlainSelect; //导入方法依赖的package包/类
public String toString() {
String sql = "REPLACE "+table;
if(expressions != null && columns != null ) {
//the SET col1=exp1, col2=exp2 case
sql += " SET ";
//each element from expressions match up with a column from columns.
for (int i = 0, s = columns.size(); i < s; i++) {
sql += ""+columns.get(i)+"="+expressions.get(i);
sql += (i<s-1)?", ":"";
}
}
else if( columns != null ) {
//the REPLACE mytab (col1, col2) [...] case
sql += " "+PlainSelect.getStringList(columns, true, true);
}
if( itemsList != null ) {
//REPLACE mytab SELECT * FROM mytab2
//or VALUES ('as', ?, 565)
if( useValues ) {
sql += " VALUES";
}
sql += " "+itemsList;
}
return sql;
}
示例8: toString
import net.sf.jsqlparser.statement.select.PlainSelect; //导入方法依赖的package包/类
public String toString() {
String sql = "DROP "+type+" "+name;
if( parameters != null && parameters.size() > 0) {
sql += " "+PlainSelect.getStringList(parameters);
}
return sql;
}
示例9: toString
import net.sf.jsqlparser.statement.select.PlainSelect; //导入方法依赖的package包/类
@Override
public String toString() {
return (getCommentCase() != null ? getCommentCase() + " " : "") + "CASE "
+ ((switchExpression != null) ? switchExpression + " " : "")
+ PlainSelect.getStringList(whenClauses, false, false) + " "
+ ((elseExpression != null) ? (getCommentElse() != null ? getCommentElse() + " " : "")
+ "ELSE " + elseExpression + " " : "")
+ (getCommentEnd() != null ? getCommentEnd() + " " : "") + "END";
}
示例10: toString
import net.sf.jsqlparser.statement.select.PlainSelect; //导入方法依赖的package包/类
@Override
public String toString() {
return PlainSelect.getStringList(expressions, true, true);
}
示例11: toString
import net.sf.jsqlparser.statement.select.PlainSelect; //导入方法依赖的package包/类
@Override
public String toString() {
return "CASE " + ((switchExpression != null) ? switchExpression + " " : "")
+ PlainSelect.getStringList(whenClauses, false, false) + " "
+ ((elseExpression != null) ? "ELSE " + elseExpression + " " : "") + "END";
}
示例12: toString
import net.sf.jsqlparser.statement.select.PlainSelect; //导入方法依赖的package包/类
@Override
public String toString() {
return columnName + " " + colDataType + (columnSpecStrings != null ? " " + PlainSelect.getStringList(columnSpecStrings, false, false) : "");
}
示例13: toString
import net.sf.jsqlparser.statement.select.PlainSelect; //导入方法依赖的package包/类
@Override
public String toString() {
String idxSpecText = PlainSelect.getStringList(getIndexSpec(), false, false);
return (getName() != null ? "CONSTRAINT " + getName() + " " : "")
+ getType() + " " + PlainSelect.getStringList(getColumnsNames(), true, true) + (!"".equals(idxSpecText) ? " " + idxSpecText : "");
}
示例14: toString
import net.sf.jsqlparser.statement.select.PlainSelect; //导入方法依赖的package包/类
@Override
public String toString() {
String idxSpecText = PlainSelect.getStringList(idxSpec, false, false);
return type + (name != null ? " " + name : "") + " " + PlainSelect.getStringList(columnsNames, true, true) + (!"".equals(idxSpecText)?" " + idxSpecText:"");
}
示例15: toString
import net.sf.jsqlparser.statement.select.PlainSelect; //导入方法依赖的package包/类
@Override
public String toString() {
return " WHEN NOT MATCHED THEN INSERT " + PlainSelect.getStringList(columns, true, true)
+ " VALUES " + PlainSelect.getStringList(values, true, true);
}