Em 18/07/13, Carlos Antônio Pereira
(VidaUTI)<[email protected]> escreveu:
> Mas se vamos a parte que se aplica ao sistema legado que dou manutenção:
> A aplicação já impede que o usuário digite com acentuação. Logo, não há
> nenhum
> acento gráfico nos registros do banco. Inclusive pensei em colocar esse
> banco em SQL_ASCII,
> já que não se utiliza nenhuma acentuação nessa aplicação.
> E colocando o banco em SQL_ASCII ainda poderei desabilitar o algorítimo que
> valida e retira acentos,
> já que o próprio banco já fará isso. Ou não?
>


Não.
Como você pode verificar no manual [1] SQL_ASCII significa "não fazer
qualquer verificação sobre o que é gravado no banco". Você é que terá
que garantir que o que será gravado sejam caracteres permitidos.

"The SQL_ASCII setting behaves considerably differently from the other
settings. When the server character set is SQL_ASCII, the server
interprets byte values 0-127 according to the ASCII standard, while
byte values 128-255 are taken as uninterpreted characters. No encoding
conversion will be done when the setting is SQL_ASCII. Thus, this
setting is not so much a declaration that a specific encoding is in
use, as a declaration of ignorance about the encoding."

Nunca use SQL_ASCII.

Osvaldo
[1] 
http://www.postgresql.org/docs/current/interactive/multibyte.html#MULTIBYTE-CHARSET-SUPPORTED
_______________________________________________
pgbr-geral mailing list
[email protected]
https://listas.postgresql.org.br/cgi-bin/mailman/listinfo/pgbr-geral

Responder a