Pawel Kot | 10 Feb 2012 20:25
Picon
Gravatar

Re: sms encoding problem on postgresql

Hi,

On Fri, Feb 10, 2012 at 13:26, Esmin Gracić <esmin.gracic <at> gmail.com> wrote:
> We have working (gnokii) smsd service on Debian 64bit, using

I have no idea why it happens but why is it that hard to imagine that
it is a MUST to provide gnokii version information?

> Postgresql 9.1 (utf8 db) as storage engine and ZTE MF622 usb modem.
> The issue is pg does not support utf16.

But what is the actual problem? This is not the problem description
from gnokii point of view.

> 1. How does smsd handle conversion from gsm encoding variants to uft8,
> and vice versa for sending?

What do you mean by "how"? Usually using iconv library.

> I see in official TODO:
> SHORT TERM
>  * remove encoding workarounds -- should be purely based on libiconv and
>   glib (in progress)

Well, it is mostly done. There are still leftovers with the
workarounds but only as alternative implementations.

> 2. Short term is how much exactly (estimation)?

Given current speed of development I'd say 5 years.
(Continue reading)

Esmin Gracić | 11 Feb 2012 23:19
Picon

Re: sms encoding problem on postgresql

On Fri, Feb 10, 2012 at 8:25 PM, Pawel Kot <gnokii <at> gmail.com> wrote:
> Hi,
>
> On Fri, Feb 10, 2012 at 13:26, Esmin Gracić <esmin.gracic <at> gmail.com> wrote:
>> We have working (gnokii) smsd service on Debian 64bit, using
>
> I have no idea why it happens but why is it that hard to imagine that
> it is a MUST to provide gnokii version information?
>
not hard, just forgot - 0.6.31. sorry...

>> Postgresql 9.1 (utf8 db) as storage engine and ZTE MF622 usb modem.
>> The issue is pg does not support utf16.
>
> But what is the actual problem? This is not the problem description
> from gnokii point of view.

When there is any of  šđžćčlŠĐŽĆČ (serbian, croatian,
bosnian...)characters in sms (my guess is when sms is using utf16 and
not gsm-7) , I get ? in inbox instead of each of these.
If I send sms with any of this characters, sms receipient gets empty sms.

>
>> 1. How does smsd handle conversion from gsm encoding variants to uft8,
>> and vice versa for sending?
>
> What do you mean by "how"? Usually using iconv library.
>
>> I see in official TODO:
>> SHORT TERM
(Continue reading)

Pawel Kot | 12 Feb 2012 17:40
Picon
Gravatar

Re: sms encoding problem on postgresql

Hi,

On Sat, Feb 11, 2012 at 23:19, Esmin Gracić <esmin.gracic <at> gmail.com> wrote:
> On Fri, Feb 10, 2012 at 8:25 PM, Pawel Kot <gnokii <at> gmail.com> wrote:
>>> Postgresql 9.1 (utf8 db) as storage engine and ZTE MF622 usb modem.
>>> The issue is pg does not support utf16.
>>
>> But what is the actual problem? This is not the problem description
>> from gnokii point of view.
>
> When there is any of  šđžćčlŠĐŽĆČ (serbian, croatian,
> bosnian...)characters in sms (my guess is when sms is using utf16 and
> not gsm-7) , I get ? in inbox instead of each of these.
> If I send sms with any of this characters, sms receipient gets empty sms.

It should basically work. Can you try gnokii --getsms/--sendsms? If it
works then the problem lies somewhere between smsd and postgres. If it
does not it lies around libgnokii.

>>
>>> 1. How does smsd handle conversion from gsm encoding variants to uft8,
>>> and vice versa for sending?
>>
>> What do you mean by "how"? Usually using iconv library.
>>
>>> I see in official TODO:
>>> SHORT TERM
>>>  * remove encoding workarounds -- should be purely based on libiconv and
>>>   glib (in progress)
>>
(Continue reading)

Jan Derfinak | 12 Feb 2012 18:21
Picon

Re: sms encoding problem on postgresql

On Sat, 11 Feb 2012, Esmin Gracić wrote:

> >> Postgresql 9.1 (utf8 db) as storage engine and ZTE MF622 usb modem.
> >> The issue is pg does not support utf16.
> >
> > But what is the actual problem? This is not the problem description
> > from gnokii point of view.
> 
> When there is any of  šđžćčlŠĐŽĆČ (serbian, croatian,
> bosnian...)characters in sms (my guess is when sms is using utf16 and
> not gsm-7) , I get ? in inbox instead of each of these.
> If I send sms with any of this characters, sms receipient gets empty sms.

The smsd - db conversion should work if you have the same client and server
encoding.  If your client has different encoding than db, try to use -e
option for setting client charset (see description of PQsetClientEncoding()
function in posgresql documentation). Postgresql library is then responsible
for correct conversion.
To check if gnokii library works, try with gnokii command line client.

jan

-- 
_______________________________________________
gnokii-users mailing list
gnokii-users <at> nongnu.org
https://lists.nongnu.org/mailman/listinfo/gnokii-users

Gmane