mirror of https://github.com/postgres/postgres
What it does: It solves stupid problem with cyrillic charsets IP-based on-fly recoding. take a look at /data/charset.conf for details. You can use any tables for any charset. Tables are from Russian Apache project. Tables in this patch contains also Ukrainian characters. Then run ./configure --enable-recodepull/50/head
parent
96316211c3
commit
0227a4e114
@ -0,0 +1,40 @@ |
||||
# |
||||
# Example PostgreSQL charsets control file. |
||||
# |
||||
# Should be placed in $PG_DATA directory. |
||||
# |
||||
# On the fly recoding charsets, based on client's IP address. |
||||
# For example: koi8-u (koi) <-> cp1251 (win) <-> cp866 (alt) |
||||
# |
||||
|
||||
# Base charset for backend |
||||
# Most Unices use koi8-r(u) as base charset. But Solaris |
||||
# use iso8859-5 and some networkless workstations use cp866. |
||||
BaseCharset koi |
||||
|
||||
# There are recode table definitions from base charset to |
||||
# other. Table names are relative to $PG_DATA directory. |
||||
# Tables are taken from Russian Apache <http://apache.lexa.ru>. |
||||
RecodeTable koi alt koi-alt.tab |
||||
RecodeTable koi win koi-win.tab |
||||
RecodeTable koi iso koi-iso.tab |
||||
RecodeTable koi koi koi-koi.tab |
||||
RecodeTable alt win othertabs/alt-win.tab |
||||
RecodeTable alt koi othertabs/alt-koi.tab |
||||
RecodeTable iso koi othertabs/iso-koi.tab |
||||
|
||||
# Local loopback |
||||
HostCharset 127.0.0.1 koi |
||||
|
||||
# Yet another Unix (maybe ;) |
||||
HostCharset 192.168.0.1 koi |
||||
|
||||
# There are Windows on 192.168.1.64 through 192.168.1.95 |
||||
HostCharset 192.168.1.64/27 win |
||||
|
||||
# There are cp866 (alt) systems on 192.168.2.3 through |
||||
# 192.168.2.7 (exept 192.168.2.4 - see below) |
||||
HostCharset 192.168.2.3-192.168.2.7 alt |
||||
|
||||
# This is exeption from previous rule! |
||||
HostCharset 192.168.2.4 win |
@ -0,0 +1,85 @@ |
||||
# Line with '#' at the begin is comment |
||||
# table file may contain number of line as you wana |
||||
# first - code of symbol, second translate code of symbol |
||||
# codes may be in two forms: decimal and hex |
||||
# examples: |
||||
# 192 225 |
||||
# 0x81 226 |
||||
# 226 0x81 |
||||
# 0x90 0xfe |
||||
# patch for Russia by Dm.Kryukov (dvk@stack.serpukhov.su) |
||||
# |
||||
163 241 |
||||
164 243 |
||||
166 249 |
||||
167 245 |
||||
173 173 |
||||
179 240 |
||||
180 242 |
||||
182 248 |
||||
183 244 |
||||
189 189 |
||||
192 238 |
||||
193 160 |
||||
194 161 |
||||
195 230 |
||||
196 164 |
||||
197 165 |
||||
198 228 |
||||
199 163 |
||||
200 229 |
||||
201 168 |
||||
202 169 |
||||
203 170 |
||||
204 171 |
||||
205 172 |
||||
206 173 |
||||
207 174 |
||||
208 175 |
||||
209 239 |
||||
210 224 |
||||
211 225 |
||||
212 226 |
||||
213 227 |
||||
214 166 |
||||
215 162 |
||||
216 236 |
||||
217 235 |
||||
218 167 |
||||
219 232 |
||||
220 237 |
||||
221 233 |
||||
222 231 |
||||
223 234 |
||||
224 158 |
||||
225 128 |
||||
226 129 |
||||
227 150 |
||||
228 132 |
||||
229 133 |
||||
230 148 |
||||
231 131 |
||||
232 149 |
||||
233 136 |
||||
234 137 |
||||
235 138 |
||||
236 139 |
||||
237 140 |
||||
238 141 |
||||
239 142 |
||||
240 143 |
||||
241 159 |
||||
242 144 |
||||
243 145 |
||||
244 146 |
||||
245 147 |
||||
246 134 |
||||
247 130 |
||||
248 156 |
||||
249 155 |
||||
250 135 |
||||
251 152 |
||||
252 157 |
||||
253 153 |
||||
254 151 |
||||
255 154 |
@ -0,0 +1,75 @@ |
||||
# Line with '#' at the begin is comment |
||||
# table file may contain number of line as you wana |
||||
# first - code of symbol, second translate code of symbol |
||||
# codes may be in two forms: decimal and hex |
||||
# examples: |
||||
# 192 225 |
||||
# 0x81 226 |
||||
# 226 0x81 |
||||
# 0x90 0xfe |
||||
# patch for Russia by Dm.Kryukov (dvk@stack.serpukhov.su) |
||||
# |
||||
192 0xee |
||||
193 0xd0 |
||||
194 0xd1 |
||||
195 0xe6 |
||||
196 0xd4 |
||||
197 0xd5 |
||||
198 0xe4 |
||||
199 0xd3 |
||||
200 0xe5 |
||||
201 0xd8 |
||||
202 0xd9 |
||||
203 0xda |
||||
204 0xdb |
||||
205 0xdc |
||||
206 0xdd |
||||
207 0xde |
||||
208 0xdf |
||||
209 0xef |
||||
210 0xe0 |
||||
211 0xe1 |
||||
212 0xe2 |
||||
213 0xe3 |
||||
214 0xd6 |
||||
215 0xd2 |
||||
216 0xec |
||||
217 0xeb |
||||
218 0xd7 |
||||
219 0xe8 |
||||
220 0xed |
||||
221 0xe9 |
||||
222 0xe7 |
||||
223 0xea |
||||
224 0xce |
||||
225 0xb0 |
||||
226 0xb1 |
||||
227 0xc6 |
||||
228 0xb4 |
||||
229 0xb5 |
||||
230 0xc4 |
||||
231 0xb3 |
||||
232 0xc5 |
||||
233 0xb8 |
||||
234 0xb9 |
||||
235 0xba |
||||
236 0xbb |
||||
237 0xbc |
||||
238 0xbd |
||||
239 0xbe |
||||
240 0xbf |
||||
241 0xcf |
||||
242 0xc0 |
||||
243 0xc1 |
||||
244 0xc2 |
||||
245 0xc3 |
||||
246 0xb6 |
||||
247 0xb2 |
||||
248 0xcc |
||||
249 0xcb |
||||
250 0xb7 |
||||
251 0xc8 |
||||
252 0xcd |
||||
253 0xc9 |
||||
254 0xc7 |
||||
255 0xca |
@ -0,0 +1,2 @@ |
||||
# Hmm ... |
||||
# |
@ -0,0 +1,130 @@ |
||||
# Hmm ... |
||||
# |
||||
128 0xc0 |
||||
129 0xc1 |
||||
130 0xc2 |
||||
131 0xc3 |
||||
132 0xc4 |
||||
133 0xc5 |
||||
134 0xc6 |
||||
135 0xc7 |
||||
136 0xc8 |
||||
137 0xc9 |
||||
138 0xca |
||||
139 0xcb |
||||
140 0xcc |
||||
141 0xcd |
||||
142 0xce |
||||
143 0xcf |
||||
144 0xd0 |
||||
145 0xd1 |
||||
146 0xd2 |
||||
147 0xd3 |
||||
148 0xd4 |
||||
149 0xd5 |
||||
150 0xd6 |
||||
151 0xd7 |
||||
152 0xd8 |
||||
153 0xd9 |
||||
154 0xda |
||||
155 0xdb |
||||
156 0xdc |
||||
157 0xdd |
||||
158 0xde |
||||
159 0xdf |
||||
160 0xa0 |
||||
161 0xa1 |
||||
162 0xa2 |
||||
163 0xa3 |
||||
164 0xa4 |
||||
165 0xa5 |
||||
166 0xa6 |
||||
167 0xa7 |
||||
168 0xa8 |
||||
169 0xa9 |
||||
170 0xaa |
||||
171 0xab |
||||
172 0xac |
||||
173 0xad |
||||
174 0xae |
||||
175 0xaf |
||||
176 0xb0 |
||||
177 0xb1 |
||||
178 0xb2 |
||||
179 0xb3 |
||||
180 0xb4 |
||||
181 0xb5 |
||||
182 0xb6 |
||||
183 0xb7 |
||||
184 0xb8 |
||||
185 0xb9 |
||||
186 0xba |
||||
187 0xbb |
||||
188 0xbc |
||||
189 0xbd |
||||
190 0xbe |
||||
191 0xbf |
||||
192 0xfe |
||||
193 0xe0 |
||||
194 0xe1 |
||||
195 0xf6 |
||||
196 0xe4 |
||||
197 0xe5 |
||||
198 0xf4 |
||||
199 0xe3 |
||||
200 0xf5 |
||||
201 0xe8 |
||||
202 0xe9 |
||||
203 0xea |
||||
204 0xeb |
||||
205 0xec |
||||
206 0xed |
||||
207 0xee |
||||
208 0xef |
||||
209 0xdf |
||||
210 0xf0 |
||||
211 0xf1 |
||||
212 0xf2 |
||||
213 0xf3 |
||||
214 0xe6 |
||||
215 0xe2 |
||||
216 0xfc |
||||
217 0xfb |
||||
218 0xe7 |
||||
219 0xf8 |
||||
220 0xfd |
||||
221 0xf9 |
||||
222 0xf7 |
||||
223 0xfa |
||||
224 0x9e |
||||
225 0x80 |
||||
226 0x81 |
||||
227 0x96 |
||||
228 0x84 |
||||
229 0x85 |
||||
230 0x94 |
||||
231 0x83 |
||||
232 0x95 |
||||
233 0x88 |
||||
234 0x89 |
||||
235 0x8a |
||||
236 0x8b |
||||
237 0x8c |
||||
238 0x8d |
||||
239 0x8e |
||||
240 0x8f |
||||
241 0x9f |
||||
242 0x90 |
||||
243 0x91 |
||||
244 0x92 |
||||
245 0x93 |
||||
246 0x86 |
||||
247 0x82 |
||||
248 0x9c |
||||
249 0x9b |
||||
250 0x87 |
||||
251 0x98 |
||||
252 0x9d |
||||
253 0x99 |
||||
254 0x97 |
||||
255 0x9a |
@ -0,0 +1,85 @@ |
||||
# Line with '#' at the begin is comment |
||||
# table file may contain number of line as you wana |
||||
# first - code of symbol, second translate code of symbol |
||||
# codes may be in two forms: decimal and hex |
||||
# examples: |
||||
# 192 225 |
||||
# 0x81 226 |
||||
# 226 0x81 |
||||
# 0x90 0xfe |
||||
# patch for Russia by Dm.Kryukov (dvk@stack.serpukhov.su) |
||||
# |
||||
163 184 |
||||
164 186 |
||||
166 179 |
||||
167 191 |
||||
173 180 |
||||
179 168 |
||||
180 170 |
||||
182 178 |
||||
183 175 |
||||
189 165 |
||||
192 254 |
||||
193 224 |
||||
194 225 |
||||
195 246 |
||||
196 228 |
||||
197 229 |
||||
198 244 |
||||
199 227 |
||||
200 245 |
||||
201 232 |
||||
202 233 |
||||
203 234 |
||||
204 235 |
||||
205 236 |
||||
206 237 |
||||
207 238 |
||||
208 239 |
||||
209 255 |
||||
210 240 |
||||
211 241 |
||||
212 242 |
||||
213 243 |
||||
214 230 |
||||
215 226 |
||||
216 252 |
||||
217 251 |
||||
218 231 |
||||
219 248 |
||||
220 253 |
||||
221 249 |
||||
222 247 |
||||
223 250 |
||||
224 222 |
||||
225 192 |
||||
226 193 |
||||
227 214 |
||||
228 196 |
||||
229 197 |
||||
230 212 |
||||
231 195 |
||||
232 213 |
||||
233 200 |
||||
234 201 |
||||
235 202 |
||||
236 203 |
||||
237 204 |
||||
238 205 |
||||
239 206 |
||||
240 207 |
||||
241 223 |
||||
242 208 |
||||
243 209 |
||||
244 210 |
||||
245 211 |
||||
246 198 |
||||
247 194 |
||||
248 220 |
||||
249 219 |
||||
250 199 |
||||
251 216 |
||||
252 221 |
||||
253 217 |
||||
254 215 |
||||
255 218 |
Loading…
Reference in new issue