db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Knut Anders Hatlen (JIRA)" <j...@apache.org>
Subject [jira] Commented: (DERBY-2188) Developer's Guide talks about a jdbc url property "locale" which is not supported by Derby.
Date Sat, 20 Oct 2007 16:24:50 GMT

    [ https://issues.apache.org/jira/browse/DERBY-2188?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12536437
] 

Knut Anders Hatlen commented on DERBY-2188:
-------------------------------------------

> Knut mentions a property called 'derby.ui.locale'. Is this still a
> valid property?

Yes, it is still valid. It is used by the tools in derbyTools.jar to
decide which locale they should use for the messages they
produce. This property only applies to the messages from the tools,
not to the messages produced by the Derby engine (hence the 'ui' part
of the property name).

Take this ij session as an example:

  % java -jar derbyrun.jar ij
  ij version 10.4
  ij> connect 'jdbc:derby:no_such_database';
  ERROR XJ004: Database 'no_such_database' not found.

If we set derby.ui.locale=de_DE, the output is changed to:

  $ java -Dderby.ui.locale=de_DE -jar derbyrun.jar ij
  IJ Version 10.4
  ij> connect 'jdbc:derby:no_such_database';
  FEHLER XJ004: Database 'no_such_database' not found.

Here we see that the message "ij version 10.4" is translated to "IJ
Version 10.4", and "ERROR XJ004" is translated to "FEHLER
XJ004". These two messages are produced by ij itself. However, the
actual error message from the Derby engine (database not found) is not
affected by derby.ui.locale.

It also works for other tools than ij:

  $ java -Dderby.ui.locale=de_DE -jar derbyrun.jar dblook -d jdbc:derby:/tmp/testdb
  -- Zeitmarke: 2007-10-20 18:03:19.888
  -- Quellendatenbank: /tmp/testdb
  -- Verbindungs-URL: jdbc:derby:/tmp/testdb
  -- appendLogs: false

> Knut mentions the Tools and Utilities guide example under
> 'derby.ui.codeset' which uses a property called
> 'derby.ui.territory'.

I believe this is a typo in the example. It should have said
'derby.ui.locale'. To my knowledge, there is no property called
'derby.ui.territory'.

> Developer's Guide talks about a jdbc url property "locale" which is not supported by
Derby.
> -------------------------------------------------------------------------------------------
>
>                 Key: DERBY-2188
>                 URL: https://issues.apache.org/jira/browse/DERBY-2188
>             Project: Derby
>          Issue Type: Bug
>          Components: Documentation
>    Affects Versions: 10.2.1.6
>            Reporter: Mamta A. Satoor
>            Assignee: Laura Stewart
>
> Under "Localizing Derby" section, Developer's Guide talks about error messages and tools
not relying on database's locale set by "locale=ll_CC". But Derby does not support any property
called "locale". 
> The exact statement from documentation is as follows 
> "The locale of the error messages and of the tools is not determined by the database's
localle set by the locale=ll_CC attribute when the database is created but instead by the
default system locale. This means that it is possible to create a database with a non-default
locale. In such a case, error messages would not be returned in the language of the database's
locale but in the language of the default locale instead."

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message