Re: Oracle encoding query

2017-12-11 Thread Tim Bunce
On Wed, Dec 06, 2017 at 04:53:36PM +0100, H.Merijn Brand wrote: > On Wed, 6 Dec 2017 15:34:17 +, Tim Bunce > wrote: > > > A view might be useful. Or perhaps define your own function to wrap the > > expression. > > That worked very well! > > CREATE OR REPLACE FUNCTION diac_u (v VARCHAR2) RE

Re: Oracle encoding query

2017-12-06 Thread H.Merijn Brand
On Wed, 6 Dec 2017 15:34:17 +, Tim Bunce wrote: > On Wed, Dec 06, 2017 at 04:12:53PM +0100, H.Merijn Brand wrote: > > On Wed, 6 Dec 2017 15:50:11 +0100, "H.Merijn Brand" > > > > > > I have been playing with several variants of > > > > > > select convert (land_u, 'AL16UTF16', 'UTF8') fro

Re: Oracle encoding query

2017-12-06 Thread Tim Bunce
On Wed, Dec 06, 2017 at 04:12:53PM +0100, H.Merijn Brand wrote: > On Wed, 6 Dec 2017 15:50:11 +0100, "H.Merijn Brand" > > > > I have been playing with several variants of > > > > select convert (land_u, 'AL16UTF16', 'UTF8') from land where c_land = > > 7072; > > > > but I didn't get SQL Devel

Re: Oracle encoding query

2017-12-06 Thread H.Merijn Brand
diac > > The field land_u contains the extended land *with* diacriticals, like > > Zuidrhodesië > ^ > > in UTF-8 encoding. Note that this is possible because of US7ASCII > > what is stored in the database is > > Zuidrhodesi\303\253 > > using perl to extract

Oracle encoding query

2017-12-06 Thread H.Merijn Brand
ial characters, like Zuidrhodesie the special characters are stored elsewhere, indicated by the field diac The field land_u contains the extended land *with* diacriticals, like Zuidrhodesië ^ in UTF-8 encoding. Note that this is possible because of US7ASCII what is stored in the databa

Re: Database encoding not recognized by DBD::Pg

2014-04-22 Thread Greg Sabino Mullane
-BEGIN PGP SIGNED MESSAGE- Hash: RIPEMD160 Vincent Veyron wrote: > Same thing for both servers: > > ppro_utf8=> show client_encoding; > client_encoding > - > LATIN9 Just to be clear, if client_encoding is not UTF8, then most bets are off as far as DBD::Pg doing the "

Re: Database encoding not recognized by DBD::Pg

2014-04-10 Thread Vincent Veyron
On Tue, 08 Apr 2014 08:40:45 +1000 Ron Savage wrote: Hi Ron, > > AFAICT locales have no effect on my code. > > I do have a policy of creating databases with: > > create database $name owner $role encoding 'UTF8'; > Yes, I agree, it does work, just not on this

Re: Database encoding not recognized by DBD::Pg

2014-04-08 Thread Vincent Veyron
On Tue, 08 Apr 2014 08:40:45 +1000 Ron Savage wrote: Hi Ron, > > AFAICT locales have no effect on my code. > > I do have a policy of creating databases with: > > create database $name owner $role encoding 'UTF8'; > Yes, I agree, it does work, just not on this

Re: Database encoding not recognized by DBD::Pg

2014-04-08 Thread Marica
On Mon, 07 Apr 2014 08:11:49 +1000 Ron Savage wrote: > Hi Vincent > > I ran a few tests, using: > > cat /etc/default/locale > # File generated by update-locale > LANG="en_AU.UTF-8" > LANGUAGE="en_AU:en" > > No problems showed up. > It only shows outside of ASCII ('é', 'ç' dont display corre

Re: Database encoding not recognized by DBD::Pg

2014-04-08 Thread Marica
On Mon, 07 Apr 2014 08:11:49 +1000 Ron Savage wrote: Ron, Sorry for the PM, with a wrong identity too. I reposted correctly on the list. -- Salutations, Vincent Veyron http://marica.fr/ Gestion des contentieux, des dossiers de sinistres assurance et

Re: Database encoding not recognized by DBD::Pg

2014-04-07 Thread Ron Savage
FR:fr encoding is the one that displays characters correctly, as in your tests. It's the one with only fr_FR@euro that doesn't (on a cluster that was initialized with LATIN9; mixed encodings work fine on a UTF-8 default cluster). I don't quite grasp locales related matters in De

Re: Database encoding not recognized by DBD::Pg

2014-04-07 Thread Ron Savage
Hi Vincent On 07/04/14 20:03, Vincent Veyron wrote: On Mon, 07 Apr 2014 08:11:49 +1000 Ron Savage wrote: I ran a few tests, using: cat /etc/default/locale # File generated by update-locale LANG="en_AU.UTF-8" LANGUAGE="en_AU:en" It only shows outside of ASCII ('é', 'ç' dont display corr

Re: Database encoding not recognized by DBD::Pg

2014-04-07 Thread Vincent Veyron
[Hi Martin, you forgot to cc the list, pasting your message below] On Mon, 7 Apr 2014 11:38:59 -0400 Martin Gainty wrote: > > did you try to set the environment variable > > LANG? > You made me discover another difference between the two servers: /etc/environment is empty on the faulty serv

Re: Database encoding not recognized by DBD::Pg

2014-04-07 Thread Vincent Veyron
On Mon, 07 Apr 2014 20:10:31 +1000 Ron Savage wrote: > > Of course, but I tested Unicode characters which are not ASCII, OK? > duh! sorry about that, I should have known better. It's been a long week... Note that the server with the fr_FR:fr encoding is the one that displa

Re: Database encoding not recognized by DBD::Pg

2014-04-07 Thread Ron Savage
Hi Marica On 07/04/14 18:59, Marica wrote: On Mon, 07 Apr 2014 08:11:49 +1000 Ron Savage wrote: Hi Vincent I ran a few tests, using: cat /etc/default/locale # File generated by update-locale LANG="en_AU.UTF-8" LANGUAGE="en_AU:en" No problems showed up. It only shows outside of ASCII ('

Re: Database encoding not recognized by DBD::Pg

2014-04-07 Thread Vincent Veyron
On Mon, 07 Apr 2014 08:11:49 +1000 Ron Savage wrote: > > I ran a few tests, using: > > cat /etc/default/locale > # File generated by update-locale > LANG="en_AU.UTF-8" > LANGUAGE="en_AU:en" > It only shows outside of ASCII ('é', 'ç' dont display correctly, as shown in the link in my origin

Re: Database encoding not recognized by DBD::Pg

2014-04-07 Thread Vincent Veyron
On Mon, 7 Apr 2014 16:26:54 +1200 Chris Bannister wrote: > > # dpkg-reconfigure locales I tried that > And choose the right one, pick a UTF one this time. :) > Those machines host other applications that use an ISO-8859 encoding, the idea was to convert them to UTF-8 one by

Re: Database encoding not recognized by DBD::Pg

2014-04-06 Thread Chris Bannister
On Sun, Apr 06, 2014 at 07:59:32PM +0200, Vincent Veyron wrote: > > cat /etc/default/locale > #Primary > LANG=fr_FR@euro > LANGUAGE=fr_FR:fr > > #Backup > LANG=fr_FR@euro # dpkg-reconfigure locales And choose the right one, pick a UTF one this time. :) -- "If you're not careful, the newspaper

Re: Database encoding not recognized by DBD::Pg

2014-04-06 Thread Ron Savage
Hi Vincent I ran a few tests, using: cat /etc/default/locale # File generated by update-locale LANG="en_AU.UTF-8" LANGUAGE="en_AU:en" No problems showed up. On 07/04/14 03:59, Vincent Veyron wrote: On Sun, 6 Apr 2014 16:01:54 - "Greg Sabino Mullane" wrote: What are server_encoding a

Re: Database encoding not recognized by DBD::Pg

2014-04-06 Thread Vincent Veyron
On Sun, 6 Apr 2014 16:01:54 - "Greg Sabino Mullane" wrote: > > What are server_encoding and client_encoding set to on each database? > Hi Greg, Same thing for both servers: ppro_utf8=> show client_encoding; client_encoding - LATIN9 (1 ligne) ppro_utf8=> show server_e

Re: Database encoding not recognized by DBD::Pg

2014-04-06 Thread Greg Sabino Mullane
-BEGIN PGP SIGNED MESSAGE- Hash: RIPEMD160 > Why does data_string_desc return 'UTF8 off' all servers, > when the database is UTF8 encoded? What are server_encoding and client_encoding set to on each database? - -- Greg Sabino Mullane g...@turnstep.com End Point Corporation http://www

Database encoding not recognized by DBD::Pg

2014-04-03 Thread Vincent Veyron
Hi, I have the following setup : Workstation, Primary, and Backup servers all running on a current version of Debian Stable. All run an identical LAMP stack of Apache/Mod_perl/Postgresql, except for default locale (see below). DBD::PG version is 3.0.0 My perl modules misbehave when connecting

Re: DBD::Oracle not utf8 encoding PL/SQL out values

2012-02-09 Thread Martin J. Evans
On 07/02/12 09:28, Martin J. Evans wrote: On 07/02/12 04:56, Steve Baldwin wrote: #!/usr/bin/perl -w use strict; use warnings; use DBI; use Encode; sub main { my $dbh = DBI->connect( 'dbi:Oracle:', 'usr/pwd@instance', '', { PrintError => 0, AutoCommit => 0, RaiseError => 1, }, ); print {*STDERR

Re: DBD::Oracle not utf8 encoding PL/SQL out values

2012-02-07 Thread Martin J. Evans
On 07/02/2012 19:42, Steve Baldwin wrote: Thanks a lot Martin. Created https://rt.cpan.org/Public/Bug/Display.html?id=74753. Cheers, Steve Could you post on the rt if you apply the patch and it works for you. Thanks Martin On Tue, Feb 7, 2012 at 8:28 PM, Martin J. Evans wrote: On 07/0

Re: DBD::Oracle not utf8 encoding PL/SQL out values

2012-02-07 Thread Steve Baldwin
Thanks a lot Martin. Created https://rt.cpan.org/Public/Bug/Display.html?id=74753. Cheers, Steve On Tue, Feb 7, 2012 at 8:28 PM, Martin J. Evans wrote: > On 07/02/12 04:56, Steve Baldwin wrote: > >> #!/usr/bin/perl -w >> use strict; >> use warnings; >> use DBI; >> use Encode; >> >> sub main {

Re: DBD::Oracle not utf8 encoding PL/SQL out values

2012-02-07 Thread Martin J. Evans
On 07/02/12 04:56, Steve Baldwin wrote: #!/usr/bin/perl -w use strict; use warnings; use DBI; use Encode; sub main { my $dbh = DBI->connect( 'dbi:Oracle:', 'usr/pwd@instance', '', { PrintError => 0, AutoCommit => 0, RaiseError => 1, }, );

DBD::Oracle not utf8 encoding PL/SQL out values

2012-02-06 Thread Steve Baldwin
Hi all, I've tried this with 1.23 and 1.27 so it has probably been fixed long ago but in case it hasn't ... Consider the following script : #!/usr/bin/perl -w use strict; use warnings; use DBI; use Encode; sub main { my $dbh = DBI->connect( 'dbi:Oracle:', 'usr/pwd@instance',

Re: Perl, DBI and encoding problem

2010-03-02 Thread Martin Evans
Alex Bernier wrote: > Hello, > > I use DBI 1.605, the DBD MySQL driver 4.007, Perl 5.10.0, MySQL 5.1.41 (on a > Debian Lenny). > > Here is my script : > > > use DBI; > > $DB_name= 'xxx'; > $DB_user= 'xxx'; > $DB_pwd = 'xxx'; > my $dbh; > $dbh = DBI->connect("dbi:mysql:dbname=$DB_n

Perl, DBI and encoding problem

2010-03-02 Thread Alex Bernier
Hello, I use DBI 1.605, the DBD MySQL driver 4.007, Perl 5.10.0, MySQL 5.1.41 (on a Debian Lenny). Here is my script : use DBI; $DB_name= 'xxx'; $DB_user= 'xxx'; $DB_pwd = 'xxx'; my $dbh; $dbh = DBI->connect("dbi:mysql:dbname=$DB_name","$DB_user","$DB_pwd", {mysql_enable_utf8=>1}

Re: utf8 encoding problem

2006-12-22 Thread Peter J. Holzer
On 2006-12-22 10:11:57 +0100, Michael Kröll wrote: > Peter J. Holzer wrote: > >> $node_name = 'wre'; my $pound = " \xc2\xa3"; print "Pound =>$pound\n"; > > That doesn't look like a pound sign in WE8DEC. You need to set NLS_LANG > > to the charset that you actually use, i.e., AMERICAN_AMERICA.UTF8 i

Re: utf8 encoding problem

2006-12-22 Thread Michael Kröll
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Peter J. Holzer wrote: >> $node_name = 'wre'; my $pound = " \xc2\xa3"; print "Pound =>$pound\n"; > That doesn't look like a pound sign in WE8DEC. You need to set NLS_LANG > to the charset that you actually use, i.e., AMERICAN_AMERICA.UTF8 in > your cas

Re: utf8 encoding problem

2006-12-22 Thread Peter J. Holzer
On 2006-12-21 16:17:53 +1000, Anand.K.S. wrote: > Hello, > > I had posted this question in CPAN forum but i was directed here for a > better answer. > > Here is the problem I am facing. In the following piece of code I get a > customer name from the database and append a pound symbol to the custo

Re: utf8 encoding problem

2006-12-21 Thread Anand . K . S .
ot say for 100% sure this will solve you problem as there is no way to exactly match your system's setup. Oracle version/patches/Oracle client system enviornment etc. There were a large number of improvements in UTF encoding since 1.12 so my only sugestion is for you to install DBD::Oracle 1.19

RE: utf8 encoding problem

2006-12-21 Thread Garrett, Philip \(MAN-Corporate\)
riginal Message- From: Anand.K.S. [mailto:[EMAIL PROTECTED] Sent: Thursday, December 21, 2006 1:18 AM To: dbi-users@perl.org Subject: utf8 encoding problem Hello, I had posted this question in CPAN forum but i was directed here for a better answer. Here is the problem I am facing. In the follow

Re: utf8 encoding problem

2006-12-21 Thread John Scoles
Unfortunety I cannot say for 100% sure this will solve you problem as there is no way to exactly match your system's setup. Oracle version/patches/Oracle client system enviornment etc. There were a large number of improvements in UTF encoding since 1.12 so my only sugestion is for y

utf8 encoding problem

2006-12-21 Thread Anand . K . S .
get was to find this link http://search.cpan.org/dist/DBD-Oracle/Changes#___top. However the work around was to use "use Encoding" (Which is commented out in the following code) in perl which fixed the problem. Cheers, Anand. use strict; use encoding 'utf8'; use atadb; use

Re: Encoding

2006-09-04 Thread Martin J. Evans
mns) VALUES > >> ($list_of_values);"; > >> $dbh->do($sql); > > > > You would be better using bound parameters as then only the data can > be utf-8. > > > >> I have looked into the database using phpMyAdmin 2.8.2-Debian-0.1 > and

Re: Encoding

2006-09-04 Thread Daniel Zeman
list_of_columns) VALUES >> ($list_of_values);"; >> $dbh->do($sql); > > You would be better using bound parameters as then only the data can be utf-8. > >> I have looked into the database using phpMyAdmin 2.8.2-Debian-0.1 and it >> really looked like t

RE: Encoding

2006-09-04 Thread h-taguchi
> perl -MDBI -e 'print "$DBI::VERSION\n";' Less typed: perl -MDBI -le 'print DBI->VERSION' Regards,

RE: Encoding

2006-09-04 Thread Martin J. Evans
gt; I have looked into the database using phpMyAdmin 2.8.2-Debian-0.1 and it > really looked like the data were stored in correct UTF-8. > > However, when I retrieve the data from Perl/DBI, something in the chain > (MySQL? the driver? DBI?) decides that another encoding (probably, >

Encoding

2006-08-31 Thread Daniel Zeman
8. However, when I retrieve the data from Perl/DBI, something in the chain (MySQL? the driver? DBI?) decides that another encoding (probably, Latin1) would be better for me. It "converts" the strings from UTF-8 to that encoding, which means, at the time the data arrives in my Perl

RE: Oracle: change client-encoding at runtime?

2005-07-11 Thread Andy Hassall
t two connections with different encodings rather than change encoding for an existing connection (which I don't think is possible), then it looks like you'd need an environment handle per connection. There's the attribute ora_envhp that forces a new environment per dbh, although there se

Re: Oracle: change client-encoding at runtime?

2005-07-11 Thread Martin Hall
so on and does not affect the encoding of the data. what we need is the oracle equivalent of "SET CLIENT_ENCODING TO 'encoding'" (postgresql) or "SET NAMES 'encoding'" (SQL92 syntax) which change the character-encoding of the data the client gets from or sen

Re: Oracle: change client-encoding at runtime?

2005-07-11 Thread Hermann Schwaerzler
o on and does not affect the encoding of the data. what we need is the oracle equivalent of "SET CLIENT_ENCODING TO 'encoding'" (postgresql) or "SET NAMES 'encoding'" (SQL92 syntax) which change the character-encoding of the data the client gets from or send

Re: Oracle: change client-encoding at runtime?

2005-07-08 Thread Martin Hall
Can you use ALTER SESSION and set nls_language? Martin Hermann Schwaerzler wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 hello is it possible to change the character-encoding of the data one receives from an oracle-DB at runtime? i.e. is it possible to have connections to two oracle

Oracle: change client-encoding at runtime?

2005-07-08 Thread Hermann Schwaerzler
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 hello is it possible to change the character-encoding of the data one receives from an oracle-DB at runtime? i.e. is it possible to have connections to two oracle-DBs in one perl-application where from one DB you want to receive utf8-data and from

Re: encoding pragma aborts script

2005-01-24 Thread RH
"Jeff Zucker" <[EMAIL PROTECTED]> píse v diskusním príspevku news:[EMAIL PROTECTED] > RH wrote: > >>Hi, >>I have an app which connects via DBI:DBD:CSV to a flat file. >>When I include pragma use encoding, > Ah, ok I found it. This patch to DBD::File f

Re: encoding pragma aborts script

2005-01-23 Thread Jeff Zucker
RH wrote: Hi, I have an app which connects via DBI:DBD:CSV to a flat file. When I include pragma use encoding, Ah, ok I found it. This patch to DBD::File fixes it. 533c533 < sprintf('(?:%s|%s¦%s)', --- sprintf('(?:%s|%s|%s)', In other words, change line 533 in F

Re: encoding pragma aborts script

2005-01-23 Thread Jeff Zucker
RH wrote: I have an app which connects via DBI:DBD:CSV to a flat file. When I include pragma use encoding, the app aborts (message from OS and the script is killed). I found out that script is aborted during execute method of DBI. The DB file has only ASCII characters. I use pragma encoding to

encoding pragma aborts script

2005-01-21 Thread RH
Hi, I have an app which connects via DBI:DBD:CSV to a flat file. When I include pragma use encoding, the app aborts (message from OS and the script is killed). I found out that script is aborted during execute method of DBI. The DB file has only ASCII characters. I use pragma encoding to display

Re: encoding

2002-11-06 Thread Guillaume Rousse
ld work as expected. > > > > This doesn't seems to be the most portable construct among different > > systems/dbms... > > > > According to postgresql manual, the following is SQL 92 standard: > > SET NAMES 'encoding' > > > > Sofar, i've

Re: encoding

2002-11-06 Thread dams
ong different > systems/dbms... > > According to postgresql manual, the following is SQL 92 standard: > SET NAMES 'encoding' > > Sofar, i've tried $dbh->do("SET NAMES 'unicode'"); at the beginning of my > script to get utf8 strings, but

Re: encoding

2002-11-06 Thread Guillaume Rousse
ollowing is SQL 92 standard: SET NAMES 'encoding' Sofar, i've tried $dbh->do("SET NAMES 'unicode'"); at the beginning of my script to get utf8 strings, but i'm not sure about the portability of this specific encoding value. -- All components become obsolete. -- Murphy's Computer Laws n°8

Re: encoding

2002-11-05 Thread dams
"Gaul, Ken" <[EMAIL PROTECTED]> said: > Set your NLS_LANG environement variable before execution of your script and > it should work as expected. thanks I'll try that ! -- ~/.signature

RE: encoding

2002-11-05 Thread Gaul, Ken
Set your NLS_LANG environement variable before execution of your script and it should work as expected. Ken. -Original Message- From: [EMAIL PROTECTED] [mailto:dams@;idm.fr] Sent: 05 November 2002 16:07 To: [EMAIL PROTECTED] Subject: encoding Hi, I'm new to this list, so

encoding

2002-11-05 Thread dams
Hi, I'm new to this list, so hello everyone, and sorry if I ask already answered questions. My pb is that I have an oracle database with datas encoded in iso-latin15 and when I use DBI::Oracle to retreive them, they are encoded in ascii or some primitive encoding, (without accents, and so

RE: encoding issue

2002-09-06 Thread Peschka, Jeremiah
You might want to take a look at also explicitly setting the character encoding in your HTML document, since that is where the javascript is getting a hold of it. I am assuming, of course, that the client-side is what you believe is corrupting your data. If you're using UTF-8, you can tell

encoding issue

2002-09-06 Thread Vorce, Tim (T.)
reference, that is an accented e as in Pr\xE9nom. Perhaps it only requires setting up some sort of encoding. This is after all, only Latin1 encoding. Is there any way to tell perl to use this character set - rather than whatever it is using??? Thanks. Tim Vorce Ford Motor Company [EMAIL PROTECTED]

Re: encoding caracter

2002-05-30 Thread Bart Lateur
On Thu, 30 May 2002 14:03:01 +0200, Cédric Mallet wrote: >I would to send the request SET CLIENT_ENCODING TO 'iso-8859-15'; > >I get an error with those lines in my perl script : > > my $sql_encod = qq{ SET CLIENT_ENCODING TO 'iso-8859-15'; }; Try dropping the semicolon at the end of the SQL sta

encoding caracter

2002-05-30 Thread Cédric Mallet
Hi I would to send the request SET CLIENT_ENCODING TO 'iso-8859-15'; I get an error with those lines in my perl script : my $sql_encod = qq{ SET CLIENT_ENCODING TO 'iso-8859-15'; }; my $sth_encod = $dbh->prepare( $sql_encod ); my $sth_encod->execute(); I don't understand why it does not wor