public SqlStatement getPreparedDeleteStatement(ClassDescriptor cld)
    {
        SqlForClass sfc = getSqlForClass(cld);
        SqlStatement sql = sfc.getDeleteSql();
        if(sql == null)
        {
            ProcedureDescriptor pd = cld.getDeleteProcedure();

            if(pd == null)
            {
                sql = new SqlDeleteByPkStatement(cld, logger);
            }
            else
            {
                sql = new SqlProcedureStatement(pd, logger);
            }
            // set the sql string
            sfc.setDeleteSql(sql);

            if(logger.isDebugEnabled())
            {
                logger.debug("SQL:" + sql.getStatement());
            }
        }
        return sql;
    }
public SqlStatement getPreparedDeleteStatement ( ClassDescriptor cld ) { SqlForClass sfc = getSqlForClass ( cld ) ; SqlStatement sql = sfc . getDeleteSql ( ) ; if ( sql == null ) { ProcedureDescriptor pd = cld . getDeleteProcedure ( ) ; if ( pd == null ) { sql = new SqlDeleteByPkStatement ( cld , logger ) ; } else { sql = new SqlProcedureStatement ( pd , logger ) ; } sfc . setDeleteSql ( sql ) ; if ( logger . isDebugEnabled ( ) ) { logger . debug ( "SQL:" + sql . getStatement ( ) ) ; } } return sql ; }
generate a prepared DELETE-Statement for the Class
described by cld.
@param cld the ClassDescriptor