List:Internals« Previous MessageNext Message »
From:Shaukat Mahmood Ahmad Date:November 30 2012 2:50pm
Subject:Re: How can I get LocaleID / LANGID for current thread (thd) / query?
View as plain text  
Thanks for your reply,

My requirement is not to store some additional information  (LANGID)
as a session / system variable for MySQL, but I simply want to get
following information  from within my Custom Storage Engine code.

 - To get LANGID / LocaleID (Microsoft Windows Specific ) for current
thread / query / connection.
 - To get LANGID / LocaleID (microsoft specific) against language set
for mysql error reporting   (../MySQL/share/../err--.sys), in other
words I want toconvert mysql error reporting language name to
Microsoft Windows specific LANGID / LocaleId.

Refernces:
http://msdn.microsoft.com/en-us/library/windows/desktop/ms679351(v=vs.85).aspx
http://msdn.microsoft.com/en-us/library/windows/desktop/dd373763(v=vs.85).aspx
http://msdn.microsoft.com/en-us/library/ms912047(v=winembedded.10).aspx
http://msdn.microsoft.com/en-us/goglobal/bb964664.aspx
http://msdn.microsoft.com/en-us/library/ms186266.aspx


Regards,
Shaukat Mahmood Ahmad.

On Thu, Nov 29, 2012 at 11:38 PM, Abhishek Varshney
<abhishekvrshny@stripped> wrote:
> I am no expert, but, I will try to answer this to the best of my knowledge.
>
>
> If you wish to get error message in some other language apart from ENGLISH
> US, then, the LANGID would actually be useful. Still, if you wish to provide
> LANGID support in your storage engine, you can define a session variable to
> hold the LANGID as explained here:
> http://dev.mysql.com/doc/refman/5.1/en/plugin-data-structures.html and use
> it as THDVAR(thd,<the_name_of_your_variable>) wherever required.
>
>
> Thanks
> Abhishek
>
>
> On 29 November 2012 17:43, Shaukat Mahmood Ahmad <write@stripped> wrote:
>>
>> Dear All,
>> How I can get LocaleID / LANGID for current thread (thd), / query, I
>> want to use this LocaleID / LANGID with FormatMessage() Windows API
>>
>> (http://msdn.microsoft.com/en-us/library/windows/desktop/ms679351(v=vs.85).aspx)
>> to get error message against error code for my windows based storage
>> engine.
>> Regards,
>> Shaukat Mahmood Ahmad
>>
>> --
>> MySQL Internals Mailing List
>> For list archives: http://lists.mysql.com/internals
>> To unsubscribe:    http://lists.mysql.com/internals
>>
>
Thread
How can I get LocaleID / LANGID for current thread (thd) / query?Shaukat Mahmood Ahmad29 Nov
  • Re: How can I get LocaleID / LANGID for current thread (thd) / query?Abhishek Varshney29 Nov
  • Re: How can I get LocaleID / LANGID for current thread (thd) / query?Sergei Golubchik30 Nov
    • Re: How can I get LocaleID / LANGID for current thread (thd) / query?Shaukat Mahmood Ahmad30 Nov
      • Re: How can I get LocaleID / LANGID for current thread (thd) / query?Sergei Golubchik30 Nov
Re: How can I get LocaleID / LANGID for current thread (thd) / query?Shaukat Mahmood Ahmad30 Nov