Restore and copy operations apply exclusive utility (HUT) locks on all objects to be restored or copied.
SQL User-Defined Function
When you copy an SQL User-Defined Function, the corresponding DBC.DBASE row is locked with a write hash lock. This prevents the user from using any Data Definition Language on that database for the dictionary phase of the copy operation.