Finding the pattern for the DCL commands, better error handling