Skip to content

Commit

Permalink
Server:APIJSONORM 解决 SQL 函数中参数的 : 被转成 AS;APIJSONBoot:数据库 URI 改为 local…
Browse files Browse the repository at this point in the history
…host
  • Loading branch information
TommyLemon committed Oct 27, 2019
1 parent 38678bd commit e3a748e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -89,13 +89,13 @@ public String getDBVersion() {
@Override
public String getDBUri() {
if (isMySQL()) {
return "jdbc:mysql://apijson.cn:3306"; //TODO 改成你自己的,TiDB 可以当成 MySQL 使用,默认端口为 4000
return "jdbc:mysql://localhost:3306"; //TODO 改成你自己的,TiDB 可以当成 MySQL 使用,默认端口为 4000
}
if (isPostgreSQL()) {
return "jdbc:postgresql://localhost:5432/postgres"; //TODO 改成你自己的
}
if (isSQLServer()) {
return "jdbc:jtds:sqlserver://apijson.org:1433/pubs;instance=SQLEXPRESS"; //TODO 改成你自己的
return "jdbc:jtds:sqlserver://localhost:1433/pubs;instance=SQLEXPRESS"; //TODO 改成你自己的
}
if (isOracle()) {
return "jdbc:oracle:thin:@localhost:1521:orcl"; //TODO 改成你自己的
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -929,7 +929,7 @@ else if (StringUtil.isName(origin)) {
}

String c = StringUtil.getString(keys);
c = (c.contains(":") == false ? c : c.replaceAll(":", " AS ")) + (StringUtil.isEmpty(joinColumn, true) ? "" : ", " + joinColumn);//不能在这里改,后续还要用到:
c = c + (StringUtil.isEmpty(joinColumn, true) ? "" : ", " + joinColumn);//不能在这里改,后续还要用到:
return isMain() && isDistinct() ? PREFFIX_DISTINCT + c : c;
default:
throw new UnsupportedOperationException(
Expand Down

0 comments on commit e3a748e

Please sign in to comment.