[prev in list] [next in list] [prev in thread] [next in thread] 

List:       freetds
Subject:    Re: [freetds] unicode
From:       "James K. Lowden" <jklowden () freetds ! org>
Date:       2008-07-30 3:41:08
Message-ID: 20080729234108.4d76dbda.jklowden () freetds ! org
[Download RAW message or body]

Murray, Laura (US) wrote:
> 
> "Please try to change FreeTDS's client char set setting from UTF-8 to
> EUCJP-MS as below.
> 
> 1) add code EUCJP-MS to 'src/tds/encodings.h'.
> 
> 2) change strings buffer from 256 to 100000 in 'src/tds/write.c'.
> 
> 3) modify freetds.conf as such:  client charset=EUCJP-MS
> 
> 
> I implemented 2) and 3) but for 1) did not know where to put the code in
> the file.  Also, just wanted to know if you approve of this approach, in
> general.  If so.....after these modifications, do I need to redo the
> freetds "make" and "make install"?

Hi Laura, 

If these changes are necessary, yours would be the first case, and I'd
like to understand why.  Adding code to encodings.h isn't baby simple: the
file is generated because there are interlocking parts.  I suspect it
would be better to add the name -- assuming that's required at all -- to
alternative_character_sets.h and regenerate encodings.h.  And, yes, it
would mean rebuilding and re-installing FreeTDS.  

But how do we know the solution lies in that direction?  To answer that,
we'd have to know more about your environment.  To wit:

1.  OS and version
2.  iconv library implementation
3.  encoding of data coming from the Oracle server
4.  encoding of single-byte data on the Microsoft server
5.  the gadget that's using FreeTDS (maybe)

I would also pursue getting a TDSDUMP log.  

I don't see how #2 will change anything.  Whether the buffer is 10 bytes
or 10 million, the data are all converted and written.  

#1 and #3 are related.  They're based on the premise that FreeTDS is not
#recognizing the encoding being used by the "client" i.e. the Oracle
#server.  That could be true but, as I said, I'm skeptical.  

Can you log onto the gateway machine and use tsql to insert Japanese
characters correctly?  That would demonstrate none of the above changes
are needed.  

Regards, 

--jkl
_______________________________________________
FreeTDS mailing list
FreeTDS@lists.ibiblio.org
http://lists.ibiblio.org/mailman/listinfo/freetds
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic