db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Bryan Pendleton (JIRA)" <j...@apache.org>
Subject [jira] Commented: (DERBY-268) Add Support for truncate table
Date Sat, 04 Sep 2010 15:17:34 GMT

    [ https://issues.apache.org/jira/browse/DERBY-268?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12906251#action_12906251

Bryan Pendleton commented on DERBY-268:

Hi Eranda,

Does your 'ant.properties' file contain the line 'sane=true'? If it does, then I think
you are performing a "debug" build, and TRUNCATE TABLE is enabled.

Try removing 'sane=true' from your ant.properties, then do 'ant clobber' and 'ant all',
and see if TRUNCATE TABLE still works.

The relevant code is this, in java/engine/org/apache/derby/impl/sql/compile/AlterTableNode.java

  public void init(Object objectName)
    throws StandardException

    //truncate table is not suppotted in this release
    //semantics are not yet clearly defined by SQL Council yet
    //truncate will be allowed only in DEBUG builds for testing purposes.
    if (SanityManager.DEBUG)
      /* For now, this init() only called for truncate table */
      truncateTable = true;
      schemaDescriptor = getSchemaDescriptor();
      throw StandardException.newException(SQLState.NOT_IMPLEMENTED,
                         "truncate table");

> Add Support for truncate table
> ------------------------------
>                 Key: DERBY-268
>                 URL: https://issues.apache.org/jira/browse/DERBY-268
>             Project: Derby
>          Issue Type: Improvement
>          Components: SQL
>            Reporter: Lance Andersen
>            Assignee: Eranda Sooriyabandara
>            Priority: Minor
> Adding support for truncate table command will aid to portability

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

View raw message