Class DeleteNotExistsExecutor

  • All Implemented Interfaces:
    StatementExecutor

    public class DeleteNotExistsExecutor
    extends java.lang.Object
    implements StatementExecutor
    The --DELETE_NOT_EXISTS primaryTable.columnName,secondaryTable1.columnName1,...,secondaryTableN.columnNameN batch.size.property statement is used to delete all the items that don't have any corresponding key in any of the secondary tables (e.g. secondaryTable1.columnName1,...,secondaryTableN.columnNameN).

    The processing of the tables and the actual deletes are done in batches to support a high volume of data. It can be influenced using:
    system.delete_not_exists.batchsize and/or system.delete_not_exists.delete_batchsize

    The statement can be executed in read only mode using: system.delete_not_exists.read_only.

    In case of high volume of data we can limit the processing time using: system.delete_not_exists.timeout_seconds.

    Author:
    Cristian Turlica
    • Field Detail

      • PROPERTY_BATCH_SIZE

        public static final java.lang.String PROPERTY_BATCH_SIZE
        See Also:
        Constant Field Values
      • PROPERTY_DELETE_BATCH_SIZE

        public static final java.lang.String PROPERTY_DELETE_BATCH_SIZE
        See Also:
        Constant Field Values
      • PROPERTY_READ_ONLY

        public static final java.lang.String PROPERTY_READ_ONLY
        See Also:
        Constant Field Values
      • PROPERTY_TIMEOUT_SECONDS

        public static final java.lang.String PROPERTY_TIMEOUT_SECONDS
        See Also:
        Constant Field Values
    • Constructor Detail

      • DeleteNotExistsExecutor

        public DeleteNotExistsExecutor​(java.sql.Connection connection,
                                       java.lang.String sql,
                                       int line,
                                       java.io.File scriptFile,
                                       java.util.Properties globalProperties)
    • Method Detail

      • checkProperties

        public void checkProperties()
      • execute

        public void execute()
                     throws java.lang.Exception
        Specified by:
        execute in interface StatementExecutor
        Throws:
        java.lang.Exception