Check for null/empty commands/queries