Search Postgresql Archives

Re: Language Code to Language name conversion for use in pg_ts_config?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Josh Hayes-Sheen <grevian@xxxxxxxxx> writes:
> I've started tinkering with the FTS functionality in 8.3 and was
> wondering if there was a good way to convert from a language code (like
> en-us) to a language name as used in pg_ts_config.cfgname (like
> 'english'), As far as I know ISO639 language codes are used pretty much
> everywhere else in postgres but there for some reason? I can build a
> table to do the mapping if I have to, but wasn't sure if there was a
> better way planned or one that was missing? (I want to build indexes
> based on languages passed in from the application as language codes)

Feel free to make your own TS configuration names according to whatever
convention you like.  The predefined ones are really meant as samples
anyway, not necessarily the ones you'd use in production.

			regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 2: Don't 'kill -9' the postmaster

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux