I was fixing some code in the bind() for UpdateNode and DeleteNode for
DERBY-571 and noticed that the methods are very similar and possibly
could be combined.

One thing that stood out is that UpdateNode has this code at the
beginning of bind() related to SYNONYMs

                // check if targetTable is a synonym
                if (targetTableName != null)
                {
                        TableName synonymTab = 
resolveTableToSynonym(this.targetTableName);
                        if (synonymTab != null)
                                this.targetTableName = synonymTab;
                }

DeleteNode does not have this code.

However, both nodes call verifyTargetTable(), which also performs the
same SYNONYM lookup.

Is the code in UpdateNode required, or is it just left over from the
implementation by mistake?

Any ideas?
Dan.

Reply via email to