提交 952b0951 编写于 作者: S serge-rider

#3473 PG procedures search fix (exclude internal functions)


Former-commit-id: 6dad4d19
上级 edbe461d
......@@ -191,6 +191,7 @@ public class PostgreStructureAssistant extends JDBCStructureAssistant
try (JDBCPreparedStatement dbStat = session.prepareStatement(
"SELECT DISTINCT x.oid,x.proname,x.pronamespace FROM pg_catalog.pg_proc x " +
"WHERE x.proname " + (caseSensitive ? "LIKE" : "ILIKE") + " ? " +
"AND x.proname NOT LIKE '\\_%'" + // Exclude procedures starting with underscore
(CommonUtils.isEmpty(schema) ? "" : " AND x.pronamespace IN (" + SQLUtils.generateParamList(schema.size())+ ")") +
" ORDER BY x.proname LIMIT " + maxResults)) {
dbStat.setString(1, procNameMask);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册