0

I'm trying to set the connection Charset for my Firebird connection using Pentaho DI but still couldn't read the data in the right encoding.

I used many parameters like encoding , charSet,...etc but no luck.

enter image description here

enter image description here

Correct me what i have missed ?

Mark Rotteveel
  • 100,966
  • 191
  • 140
  • 197
Jason4Ever
  • 1,439
  • 4
  • 23
  • 43

1 Answers1

1

You either need to use encoding with the Firebird name of the character set, or charSet with the Java name of the character set(*).

WIN1256 is not a valid Java character set name, so the connection will fail. If you specify charSet, then you need to use the Java name Cp1256 or - with Jaybird 2.2.1 or newer - windows-1256.

If this doesn't work then either Pentaho is not correctly passing connection properties, or your data is stored in a column with character set NONE in a different encoding than WIN1256 (or worse: stored in a column with character set WIN1256, but the data is actually a different encoding).

*: Technically you can combine encoding and charSet, but it is only for special use cases where you want Firebird to read data in one character set, and have Jaybird interpret it in another character set.

Mark Rotteveel
  • 100,966
  • 191
  • 140
  • 197
  • I have tried both but no luck , i got the result like `ÒßÑíÇ ÇáÍÌÇæí : ãæÇá ÇáÔÌä` .. i think the data is stored in `ANSI` format . it contains arabic letter. when i used client like `FlameRobin` and set the charset `Windows-1256` it reads the `Arabic` data correctly .. I'm using Jaybird `2.2.10` with Pentaho – Jason4Ever Apr 05 '16 at 09:25
  • @Jason4Ever It sounds like Pentaho isn't passing the connection property. Which Pentaho version are you using? – Mark Rotteveel Apr 05 '16 at 09:27
  • I'm using kettle Pentaho CE v 5.0 – Jason4Ever Apr 05 '16 at 10:47
  • Thx a lot brother , i replaced `Jaybird 2.2.10` with the default one from Pentaho `jaybird-2.1.6` and now it's working fine with setting `charSet = CP1256` – Jason4Ever Apr 05 '16 at 10:51
  • @Jason4Ever That is very curious, because I would expect Jaybird 2.2.10 to work as well. I will investigate that further, thanks. – Mark Rotteveel Apr 05 '16 at 11:26
  • @Jason4Ever I just tested Pentaho 5.0.1 and replaced jaybird-2.1.6.jar with jaybird-2.2.10.jar (JDK 1.8) and added connector-api-1.5.jar and it worked correctly. In both cases the Arabic characters are displayed correctly (I only used `charSet = Cp1256` under Options). – Mark Rotteveel Apr 08 '16 at 10:06
  • Thank you for your useful help and your following up . I'll try v2.2 again later. – Jason4Ever Apr 10 '16 at 07:14