【发布时间】:2016-03-09 07:00:41
【问题描述】:
下面是从h2生成的statmen
INSERT INTO EPSG_ALIAS
(ALIAS_CODE, OBJECT_TABLE_NAME, OBJECT_CODE, NAMING_SYSTEM_CODE, ALIAS, REMARKS)
VALUES
(1431, 'Datum', 6123, 7300, STRINGDECODE('Kartastokoordinaattij\ufffdrjestelm\ufffd (1966)'), NULL);
当我在 postgresql 中执行上述语句时,出现以下错误。
ERROR: function stringdecode(unknown) does not exist
SQL state: 42883
Hint: No function matches the given name and argument types. You might need to add explicit type casts.
Character: 140
【问题讨论】:
-
stringdecode 是做什么的,在 postgres 中找到一个等效的函数并使用它。
-
它将Unicode字符串(\ufffd)转换为实际字符(即特殊字符)
-
这个正则表达式有什么关系?
-
您是否调查过是否可以在 PostgreSQL 中通过
CREATE FUNCTION STRINGDECODE(text) ...来模拟相应 H2 函数的行为?
标签: postgresql jdbc h2db