0
postgresql 쿼리에서 instr을 시도한 다음 instr 기능이없는 것 같았습니다. 유니 코드와 함께 작동하는 Postgresql instr
는 PostgreSQL을의 plpgsql 언어 INSTR을 구현하는 방법을 보여줍니다 URL을 http://www.postgresql.org/docs/9.1/static/plpgsql-porting.html#PLPGSQL-PORTING-APPENDIX발견.
ERROR: character with byte sequence 0xe4 0xb9 0xa6 in encoding "UTF8" has no equivalent in encoding "WIN1252"
내 클라이언트에서
SET client_encoding = 'UTF8';
를 사용하는 경우에도 : 내가 다음과 같은 오류를 얻을 수 있기 때문에, 유니 코드 VARCHAR 컬럼에서 작동하지 않는 것 같습니다 그러나
. 누구나 유니 코드로 instr을 수행하는 방법을 알고 있습니까?
position
은 instr
에 해당하는 postgresql이지만 위와 같은 오류가 발생합니다.
이 또한 작동하지 않았다 :
select start from cnetd where substr(start, 6, 1) <> '/' and position('/' in convert(start, 'UTF8', 'LATIN1')) > 0 limit 90;
ERROR: function convert(character varying, unknown, unknown) does not exist
LINE 1: ...re substr(start, 6, 1) <> '/' and position('/' in convert(st...
^
HINT: No function matches the given name and argument types. You might need to
add explicit type casts.
오류 메시지는 유효하지 않은 UTF-8 문자열을 보냈지 만 함수가 UTF-8에서 작동하지 않는다고 말합니다. 함수 자체와는 아무런 관련이 없습니다. Btw : Postgres에'strpos' 함수가 있습니다. –
UTF8 문자열이 유효하지 않은 이유는 무엇입니까? – Superdooperhero
문제의 행을 어떻게 식별 할 수 있습니까? – Superdooperhero