protected void getModificationResult(
     SQLObject e,
     EStructuralFeature feature,
     Object oldValue,
     Object newValue,
     boolean quoteIdentifiers,
     boolean qualifyNames,
     boolean fullSyntax,
     SybaseDdlScript script) {
   if (!(e instanceof SybaseASABaseViewTable)) {
     return;
   }
   if (feature.getFeatureID()
       == SybaseasabasesqlmodelPackage.SYBASE_ASA_BASE_VIEW_TABLE__DESCRIPTION) {
     SybaseASADdlBuilder builder = (SybaseASADdlBuilder) SybaseASADdlBuilder.getInstance();
     String description = null;
     if (e.getDescription() == null || e.getDescription().trim().length() == 0) {
       description = NULL;
     } else {
       description = SQLUtil.quote(e.getDescription(), SINGLE_QUOTE);
     }
     String objectName =
         builder.getName((SybaseASABaseViewTable) e, quoteIdentifiers, qualifyNames);
     StringBuffer comment = new StringBuffer("");
     comment
         .append(COMMENT)
         .append(SPACE)
         .append(ON)
         .append(SPACE)
         .append(VIEW)
         .append(SPACE)
         .append(objectName);
     comment.append(SPACE).append(IS).append(SPACE).append(description);
     script.addAlterOtherStatements(comment.toString());
   }
 }
  public void processAlterStatement(
      SQLObject element,
      Map modifyRecordMap,
      boolean quoteIdentifiers,
      boolean qualifyNames,
      boolean fullSyntax,
      SybaseDdlScript script,
      IProgressMonitor monitor) {
    if (!(element instanceof SybaseASEProcedure)) {
      return;
    }
    SybaseASEProcedure proc = (SybaseASEProcedure) element;
    TransactionModeType xmode = proc.getTransactionMode();
    String modeLiteral = SQLUtil.quote(xmode.getLiteral(), "'");
    String owner = SQLUtil.quote(proc.getSchema().getName(), "'");
    boolean xmodeChanged = false;
    boolean sourceChanged = false;

    List records = (List) modifyRecordMap.get(element);
    if (records != null) {
      String source = proc.getSource().getBody();
      for (Iterator iter = records.iterator(); iter.hasNext(); ) {
        FeatureChangeRecord r = (FeatureChangeRecord) iter.next();
        if (r.feature.getFeatureID() == SQLRoutinesPackage.PROCEDURE__NAME && r.changed == proc) {
          // rename, the name inside source should have already been updated
          String name = SQLUtil.quote((String) r.oldValue, "'");
          String drop =
              DROP
                  + (quoteIdentifiers
                      ? SQLUtil.quote((String) r.oldValue, "\"")
                      : (String) r.oldValue);
          drop = SQLUtil.quote(drop, "'");
          String newname = SQLUtil.quote((String) r.newValue, "'");

          script.addCreateRoutineStatements(source);
          String alter =
              (RENAME)
                  .replaceAll("<<@owner>>", owner)
                  .replaceAll("<<@name>>", name)
                  .replaceAll("<<@drop>>", drop)
                  .replaceAll("<<@newname>>", newname)
                  .replaceAll("<<xmode>>", modeLiteral);
          script.addCreateRoutineStatements(alter);

          return;
        } else if (r.feature.getFeatureID()
            == SybaseasesqlmodelPackage.SYBASE_ASE_PROCEDURE__TRANSACTION_MODE) {
          xmodeChanged = true;
        } else if (r.feature.getFeatureID() == SQLRoutinesPackage.SOURCE__BODY
            && r.changed == proc.getSource()) {
          sourceChanged = true;
        }
      }
      // normal modification
      String name = SQLUtil.quote(proc.getName(), "'");
      String drop =
          DROP + (quoteIdentifiers ? SQLUtil.quote(proc.getName(), "\"") : proc.getName());
      drop = SQLUtil.quote(drop, "'");
      String newname = SQLUtil.quote(makeNewName(name), "'");

      String alter = "";
      if (xmodeChanged && !sourceChanged) {
        alter = "exec sp_procxmode " + name + ", " + modeLiteral;
        script.addCreateRoutineStatements(alter);
        return;
      }

      if (!sourceChanged) {
        return;
      }

      alter =
          (DECLARE + BACKUP)
              .replaceAll("<<@name>>", name)
              .replaceAll("<<@drop>>", drop)
              .replaceAll("<<@newname>>", newname)
              .replaceAll("<<xmode>>", modeLiteral);
      script.addCreateRoutineStatements(alter);
      script.addCreateRoutineStatements(source);
      alter =
          (DECLARE + CLEANUP)
              .replaceAll("<<@owner>>", owner)
              .replaceAll("<<@name>>", name)
              .replaceAll("<<@drop>>", drop)
              .replaceAll("<<@newname>>", newname)
              .replaceAll("<<xmode>>", modeLiteral);
      script.addCreateRoutineStatements(alter);
    }
  }