Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 5 additions & 3 deletions dinky-admin/src/main/resources/mapper/DocumentMapper.xml
Original file line number Diff line number Diff line change
Expand Up @@ -55,12 +55,14 @@
<if test='param.updateTime!=null and param.updateTime!=""'>
and a.update_time <![CDATA[>=]]> str_to_date( #{param.updateTime},'%Y-%m-%d %H:%i:%s')
</if>
<if test='ew.sqlSegment!=null and ew.sqlSegment!="" and !ew.sqlSegment.startsWith(" ORDER BY")'>
<!-- If SQL segment is present and doesn't start with ORDER BY and does not contain 'undefined', prepend 'and' -->
<if test='ew.sqlSegment!=null and ew.sqlSegment!="" and !ew.sqlSegment.startsWith(" ORDER BY") and ew.sqlSegment.indexOf("undefined")==-1'>
and
</if>
<if test='ew.sqlSegment!=null and ew.sqlSegment!=""'>
<!-- Only include the dynamic segment if it does not contain the literal 'undefined' -->
<if test='ew.sqlSegment!=null and ew.sqlSegment!="" and ew.sqlSegment.indexOf("undefined")==-1'>
${ew.sqlSegment}
</if>
</where>
</select>
</mapper>
</mapper>
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ public String getCreateTableSql(Table table) {
}
sb.append("\"" + columns.get(i).getName() + "\" "
+ getTypeConvert().convertToDB(columns.get(i).getDataType()));
if (columns.get(i).isNullable()) {
if (!columns.get(i).isNullable()) {
sb.append(" NOT NULL");
}
}
Expand Down
Loading