Make sure that everything you need from the old iPad is backed up or you already have copies of it stored somewhere...
You can either perform erase all from within the iPad and it will ask you to enter the Apple ID password to continue or what I usually do, log in to iCloud on the web browser [desktop], erase device then remove from account...
The reason I do not do it within the device is I don't want it to upload anything to iCloud unless I specifically asked it to do...