postgresql7.1 select nls_language from ad_locales where lower(trim(language)) = lower(:language) limit 1