You are viewing a plain text version of this content. The canonical link for it is here.
Posted to derby-dev@db.apache.org by "Daniel John Debrunner (JIRA)" <de...@db.apache.org> on 2006/09/07 18:16:25 UTC

[jira] Created: (DERBY-1825) Errors 2850A,2850G,28508 are similar - can be combined into a single message.

Errors 2850A,2850G,28508 are similar - can be combined into a single message.
-----------------------------------------------------------------------------

                 Key: DERBY-1825
                 URL: http://issues.apache.org/jira/browse/DERBY-1825
             Project: Derby
          Issue Type: Improvement
          Components: SQL
            Reporter: Daniel John Debrunner



ERROR 2850A: User 'SAM' does not have execute permission on PROCEDURE 'SYSCS_UTIL'.'SYSCS_EXPORT_TABLE'.

ERROR 2850G: User 'MAMTA2' does not have grant permission on object 'MAMTA2'.'V21VIEWTEST'.

ERROR 28508: User 'MAMTA3' does not have select permission on column 'C111' of table 'MAMTA2'.'V21VIEWTEST'. 


-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Updated: (DERBY-1825) Errors 2850A,2850G,28508 are similar - can be combined into a single message.

Posted by "Jørgen Løland (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/DERBY-1825?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jørgen Løland updated DERBY-1825:
---------------------------------

    Attachment: DERBY-1825-1.stat
                DERBY-1825-1.diff

It seems that the effect of merging error messages is that either the messages get ugly due to the "Table/View" text, or information is lost (if I replace "table" with "object" in message 28506). I think this outweighs the positive effects achieved by removing 2 or 3 error codes. Hence, I stop working on this issue.

I'm attaching a patch for future reference that does what I previously described. I.e., error codes 28506, 2850A and 2850G are merged into one error message 28506:

   User '{0}' does not have {1} permission on {2} '{3}'.'{4}'. 

Further, error codes 28507 and 2850B are merged into one message 28507:

   User '{0}' does not have {1} permission on {2} '{3}'.'{4}' for grant.

The patch is not intended for inclusion, and has therefore not been tested.

> Errors 2850A,2850G,28508 are similar - can be combined into a single message.
> -----------------------------------------------------------------------------
>
>                 Key: DERBY-1825
>                 URL: https://issues.apache.org/jira/browse/DERBY-1825
>             Project: Derby
>          Issue Type: Improvement
>          Components: SQL
>            Reporter: Daniel John Debrunner
>         Assigned To: Jørgen Løland
>         Attachments: DERBY-1825-1.diff, DERBY-1825-1.stat
>
>
> ERROR 2850A: User 'SAM' does not have execute permission on PROCEDURE 'SYSCS_UTIL'.'SYSCS_EXPORT_TABLE'.
> ERROR 2850G: User 'MAMTA2' does not have grant permission on object 'MAMTA2'.'V21VIEWTEST'.
> ERROR 28508: User 'MAMTA3' does not have select permission on column 'C111' of table 'MAMTA2'.'V21VIEWTEST'. 

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


[jira] Closed: (DERBY-1825) Errors 2850A,2850G,28508 are similar - can be combined into a single message.

Posted by "Jørgen Løland (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/DERBY-1825?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jørgen Løland closed DERBY-1825.
--------------------------------


I heard no objections against closing the issue, but feel free to reopen it...

> Errors 2850A,2850G,28508 are similar - can be combined into a single message.
> -----------------------------------------------------------------------------
>
>                 Key: DERBY-1825
>                 URL: https://issues.apache.org/jira/browse/DERBY-1825
>             Project: Derby
>          Issue Type: Improvement
>          Components: SQL
>            Reporter: Daniel John Debrunner
>         Assigned To: Jørgen Løland
>         Attachments: DERBY-1825-1.diff, DERBY-1825-1.stat
>
>
> ERROR 2850A: User 'SAM' does not have execute permission on PROCEDURE 'SYSCS_UTIL'.'SYSCS_EXPORT_TABLE'.
> ERROR 2850G: User 'MAMTA2' does not have grant permission on object 'MAMTA2'.'V21VIEWTEST'.
> ERROR 28508: User 'MAMTA3' does not have select permission on column 'C111' of table 'MAMTA2'.'V21VIEWTEST'. 

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


[jira] Commented: (DERBY-1825) Errors 2850A,2850G,28508 are similar - can be combined into a single message.

Posted by "Dag H. Wanvik (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/DERBY-1825?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12489446 ] 

Dag H. Wanvik commented on DERBY-1825:
--------------------------------------

I had 2850H.C, 2850I.C and 2850J.C as one message originally as part of
DERBY-2264 (see review comment at http://issues.apache.org/jira/browse/DERBY-2264#action_12480398)
but split them apart since the operation name has to be localized, e.g. "(re)encrypt" 
would be "(re)kryptere" in Norwegian locale, and should not be embedded of the calling code which calls
the exception constructor. Would your proposed change address this?


> Errors 2850A,2850G,28508 are similar - can be combined into a single message.
> -----------------------------------------------------------------------------
>
>                 Key: DERBY-1825
>                 URL: https://issues.apache.org/jira/browse/DERBY-1825
>             Project: Derby
>          Issue Type: Improvement
>          Components: SQL
>            Reporter: Daniel John Debrunner
>         Assigned To: Jørgen Løland
>
> ERROR 2850A: User 'SAM' does not have execute permission on PROCEDURE 'SYSCS_UTIL'.'SYSCS_EXPORT_TABLE'.
> ERROR 2850G: User 'MAMTA2' does not have grant permission on object 'MAMTA2'.'V21VIEWTEST'.
> ERROR 28508: User 'MAMTA3' does not have select permission on column 'C111' of table 'MAMTA2'.'V21VIEWTEST'. 

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


[jira] Commented: (DERBY-1825) Errors 2850A,2850G,28508 are similar - can be combined into a single message.

Posted by "Jørgen Løland (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/DERBY-1825?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12489313 ] 

Jørgen Løland commented on DERBY-1825:
--------------------------------------

I have looked into all the '28'-error messages. I suggest that
the following similar errors are combined:

Errors 28506, 2850A and 2850G replaced by:
<msg>   
    <name>28506</name>
    <text>User '{0}' does not have {1} permission on {2} '{3}'.'{4}'.</text>
    <arg>authorizationID</arg>
    <arg>permissionName</arg>
    <arg>objectType</arg>
    <arg>schemaName</arg>
    <arg>objectName</arg>
</msg>

Errors 28507 and 2850B replaced by:
<msg>
    <name>28507</name>
    <text>User '{0}' does not have {1} permission on {2} '{3}'.'{4}' for grant.</text>
    <arg>authorizationID</arg>
    <arg>permissionType</arg>
    <arg>objectType</arg>
    <arg>schemaName</arg>
    <arg>tableName</arg>
</msg>

Errors 2850E, 2850H.C, 2850I.C and 2850J.C replaced by
<msg>
    <name>2850E</name>
    <text>User '{0}' cannot {1} {2} '{3}'. Only the database owner can perform this operation.</text>
    <arg>authorizationID</arg>
    <arg>operationType</arg>
    <arg>objectType</arg>
    <arg>objectName</arg>
</msg>


Jørgen Løland


> Errors 2850A,2850G,28508 are similar - can be combined into a single message.
> -----------------------------------------------------------------------------
>
>                 Key: DERBY-1825
>                 URL: https://issues.apache.org/jira/browse/DERBY-1825
>             Project: Derby
>          Issue Type: Improvement
>          Components: SQL
>            Reporter: Daniel John Debrunner
>         Assigned To: Jørgen Løland
>
> ERROR 2850A: User 'SAM' does not have execute permission on PROCEDURE 'SYSCS_UTIL'.'SYSCS_EXPORT_TABLE'.
> ERROR 2850G: User 'MAMTA2' does not have grant permission on object 'MAMTA2'.'V21VIEWTEST'.
> ERROR 28508: User 'MAMTA3' does not have select permission on column 'C111' of table 'MAMTA2'.'V21VIEWTEST'. 

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


[jira] Resolved: (DERBY-1825) Errors 2850A,2850G,28508 are similar - can be combined into a single message.

Posted by "Jørgen Løland (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/DERBY-1825?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jørgen Løland resolved DERBY-1825.
----------------------------------

    Resolution: Won't Fix

> Errors 2850A,2850G,28508 are similar - can be combined into a single message.
> -----------------------------------------------------------------------------
>
>                 Key: DERBY-1825
>                 URL: https://issues.apache.org/jira/browse/DERBY-1825
>             Project: Derby
>          Issue Type: Improvement
>          Components: SQL
>            Reporter: Daniel John Debrunner
>         Assigned To: Jørgen Løland
>         Attachments: DERBY-1825-1.diff, DERBY-1825-1.stat
>
>
> ERROR 2850A: User 'SAM' does not have execute permission on PROCEDURE 'SYSCS_UTIL'.'SYSCS_EXPORT_TABLE'.
> ERROR 2850G: User 'MAMTA2' does not have grant permission on object 'MAMTA2'.'V21VIEWTEST'.
> ERROR 28508: User 'MAMTA3' does not have select permission on column 'C111' of table 'MAMTA2'.'V21VIEWTEST'. 

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


[jira] Commented: (DERBY-1825) Errors 2850A,2850G,28508 are similar - can be combined into a single message.

Posted by "Dag H. Wanvik (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/DERBY-1825?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12489908 ] 

Dag H. Wanvik commented on DERBY-1825:
--------------------------------------

What is localized as far as SQL keywords is a bit tricky, possibly arbitrary currently.
I guess if you are intending to quote a keyword, no localization is
wanted, e.g. in Portuguese variant of 2850F, the SQL keyword "GRANT" is used (note uppercase)
unlocalized.

If the message intends to reference a concept, a localized version is probably better, e.g.
in the text for 28508, the Portuguese words "tabela" and "coluna" are used, 
although these are also SQL reserved keywords...

Do we have any guidelines for this?

In the current case, I would think that the permission names would not need to be localized,
but table/view probably should. I am not sure I like the capitalized "Table/View" in the 
middle of a sentence either..

> Errors 2850A,2850G,28508 are similar - can be combined into a single message.
> -----------------------------------------------------------------------------
>
>                 Key: DERBY-1825
>                 URL: https://issues.apache.org/jira/browse/DERBY-1825
>             Project: Derby
>          Issue Type: Improvement
>          Components: SQL
>            Reporter: Daniel John Debrunner
>         Assigned To: Jørgen Løland
>
> ERROR 2850A: User 'SAM' does not have execute permission on PROCEDURE 'SYSCS_UTIL'.'SYSCS_EXPORT_TABLE'.
> ERROR 2850G: User 'MAMTA2' does not have grant permission on object 'MAMTA2'.'V21VIEWTEST'.
> ERROR 28508: User 'MAMTA3' does not have select permission on column 'C111' of table 'MAMTA2'.'V21VIEWTEST'. 

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


[jira] Assigned: (DERBY-1825) Errors 2850A,2850G,28508 are similar - can be combined into a single message.

Posted by "Jørgen Løland (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/DERBY-1825?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jørgen Løland reassigned DERBY-1825:
------------------------------------

    Assignee: Jørgen Løland

> Errors 2850A,2850G,28508 are similar - can be combined into a single message.
> -----------------------------------------------------------------------------
>
>                 Key: DERBY-1825
>                 URL: https://issues.apache.org/jira/browse/DERBY-1825
>             Project: Derby
>          Issue Type: Improvement
>          Components: SQL
>            Reporter: Daniel John Debrunner
>         Assigned To: Jørgen Løland
>
> ERROR 2850A: User 'SAM' does not have execute permission on PROCEDURE 'SYSCS_UTIL'.'SYSCS_EXPORT_TABLE'.
> ERROR 2850G: User 'MAMTA2' does not have grant permission on object 'MAMTA2'.'V21VIEWTEST'.
> ERROR 28508: User 'MAMTA3' does not have select permission on column 'C111' of table 'MAMTA2'.'V21VIEWTEST'. 

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


[jira] Commented: (DERBY-1825) Errors 2850A,2850G,28508 are similar - can be combined into a single message.

Posted by "Jørgen Løland (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/DERBY-1825?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12489616 ] 

Jørgen Løland commented on DERBY-1825:
--------------------------------------

That's a good point, Dag. The current solution does not solve this. Furthermore, I think it may be a bad idea to merge xxxxx.C error codes with xxxxx codes, hence 2850E will not be merged with H, I and J.

> Errors 2850A,2850G,28508 are similar - can be combined into a single message.
> -----------------------------------------------------------------------------
>
>                 Key: DERBY-1825
>                 URL: https://issues.apache.org/jira/browse/DERBY-1825
>             Project: Derby
>          Issue Type: Improvement
>          Components: SQL
>            Reporter: Daniel John Debrunner
>         Assigned To: Jørgen Løland
>
> ERROR 2850A: User 'SAM' does not have execute permission on PROCEDURE 'SYSCS_UTIL'.'SYSCS_EXPORT_TABLE'.
> ERROR 2850G: User 'MAMTA2' does not have grant permission on object 'MAMTA2'.'V21VIEWTEST'.
> ERROR 28508: User 'MAMTA3' does not have select permission on column 'C111' of table 'MAMTA2'.'V21VIEWTEST'. 

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


[jira] Commented: (DERBY-1825) Errors 2850A,2850G,28508 are similar - can be combined into a single message.

Posted by "Jørgen Løland (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/DERBY-1825?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12489696 ] 

Jørgen Løland commented on DERBY-1825:
--------------------------------------

I have reexamined the error messages with respect to localization. First of all, 2850E, 2850H.C, 2850I.C and 2850J.C are not merged due to the problem described by Dag.

28506 and 2850G can be merged into one message 

    User '{0}' does not have {1} permission on {2} '{3}'.'{4}'.

If this is done, however, the former "table" and "object" words will be replaced with "Table/View" since this is what is returned from TableDescriptor#getDescriptorType. Hence, the messages

ERROR 28506: User 'USER2' does not have insert permission on table 'USER1'.'DERBYDB'.
ERROR 2850G: User 'USER2' does not have grant permission on object 'USER1'.'TEST'.

will be replaced with

ERROR 28506: User 'USER2' does not have insert permission on Table/View 'USER1'.'DERBYDB'.
ERROR 28506: User 'USER2' does not have grant permission on Table/View 'USER1'.'TEST'.

Note that the privilege names ("select/insert/grant" etc) are not localized in the current code (TablePrivilegeInfo#checkPrivileges and StatementTablePermission#check). If the word "execute" of ERROR 2850A can be non-localized similarly, 2850A can also be merged with 28506 and 2850G.

1) Should 28506 and 2850G be merged with the described "Table/View" effect?
2) Should 2850A also be merged with these, resulting in non-localized "execute"?

The merging of errors 28507 and 2850B inherits both 1) and 2). Hence, if the answer is yes to both questions, they
will be merged.

> Errors 2850A,2850G,28508 are similar - can be combined into a single message.
> -----------------------------------------------------------------------------
>
>                 Key: DERBY-1825
>                 URL: https://issues.apache.org/jira/browse/DERBY-1825
>             Project: Derby
>          Issue Type: Improvement
>          Components: SQL
>            Reporter: Daniel John Debrunner
>         Assigned To: Jørgen Løland
>
> ERROR 2850A: User 'SAM' does not have execute permission on PROCEDURE 'SYSCS_UTIL'.'SYSCS_EXPORT_TABLE'.
> ERROR 2850G: User 'MAMTA2' does not have grant permission on object 'MAMTA2'.'V21VIEWTEST'.
> ERROR 28508: User 'MAMTA3' does not have select permission on column 'C111' of table 'MAMTA2'.'V21VIEWTEST'. 

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


[jira] Commented: (DERBY-1825) Errors 2850A,2850G,28508 are similar - can be combined into a single message.

Posted by "Jørgen Løland (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/DERBY-1825?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12494477 ] 

Jørgen Løland commented on DERBY-1825:
--------------------------------------

Is it ok to close this issue? There have been no comments since i marked it as Won't Fix on April 19

> Errors 2850A,2850G,28508 are similar - can be combined into a single message.
> -----------------------------------------------------------------------------
>
>                 Key: DERBY-1825
>                 URL: https://issues.apache.org/jira/browse/DERBY-1825
>             Project: Derby
>          Issue Type: Improvement
>          Components: SQL
>            Reporter: Daniel John Debrunner
>         Assigned To: Jørgen Løland
>         Attachments: DERBY-1825-1.diff, DERBY-1825-1.stat
>
>
> ERROR 2850A: User 'SAM' does not have execute permission on PROCEDURE 'SYSCS_UTIL'.'SYSCS_EXPORT_TABLE'.
> ERROR 2850G: User 'MAMTA2' does not have grant permission on object 'MAMTA2'.'V21VIEWTEST'.
> ERROR 28508: User 'MAMTA3' does not have select permission on column 'C111' of table 'MAMTA2'.'V21VIEWTEST'. 

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