db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Mamta A. Satoor (JIRA)" <j...@apache.org>
Subject [jira] Commented: (DERBY-1062) Change the internal implemetation of SYSCS_INPLACE_COMPRESS_TABLE to share existing alter table
Date Tue, 20 May 2008 20:42:55 GMT

    [ https://issues.apache.org/jira/browse/DERBY-1062?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12598456#action_12598456
] 

Mamta A. Satoor commented on DERBY-1062:
----------------------------------------

Knut, it indeed does look easy. I was running around the wrong bush and was thinking that
I would need to somehow change the parser for the special case of ALTER TABLE when it is called
for inplace compress. But of course, it is easier to tackle it when the ALTER TABLE sql is
being generated rather than when it is being parsed.

With your patch, I was not sure if always quoting the schema name and table name will work
in all cases but it appears that the parameters to these system procedures are always case
sensitive and hence it is ok to always quote them. For instance, in 10.4, following works
call syscs_util.syscs_compress_table('APP', 'test""table', 1);
but if I use lower case app for schema, it does not work
call syscs_util.syscs_compress_table('app', 'test""table', 1);
So, with your proposed solution, quoting the schema name and table name always should not
cause a problem.

I saw another system stored procedure, SYSCS_BULK_INSERT, in SystemProcedure which generates
its own SQL and it does not seem to handle special characters either. It can be taken up as
separate task but might be worth making it's behavior match the other system procedures.

I haven't run any tests with the patch yet. If the tests pass for you and no further comments
from anyone, feel free to commit the patch.

> Change the internal implemetation of SYSCS_INPLACE_COMPRESS_TABLE to share existing alter
table
> -----------------------------------------------------------------------------------------------
>
>                 Key: DERBY-1062
>                 URL: https://issues.apache.org/jira/browse/DERBY-1062
>             Project: Derby
>          Issue Type: Improvement
>          Components: Newcomer, SQL, Store
>    Affects Versions: 10.1.3.1
>            Reporter: Mike Matrigali
>            Assignee: Mamta A. Satoor
>            Priority: Minor
>         Attachments: d1062-escape.diff
>
>
>  Change the internal implemetation of SYSCS_INPLACE_COMPRESS_TABLE to share existing
alter table
> code. One suggested approach is to use the same mechanism as SYSCS_COMPRESS_TABLE. Such
> an implementation would involve:
> o change the parser for alter table to accecpt some internal only syntax for SYSCS_INPLACE_COMPRESS_TABLE
> o change the alter table constant action to get the required information for inplace
compress
> o move most of the inplace compress driving code to a routine in alter table execution,
following the same
>      coding pattern as existing alter table compress.
> I believe doing this will have multiple benefits:
> 1) shares existing alter table code, so things like error checking, security management,
... is all done by one piece of code
> 2) by sharing the code I believe the following outstanding JIRA issues will be addressed:
DERBY-719, DERBY-720 -
> 3) future changes addressing ddl like grant/revoke will automatically work.

-- 
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