If your 2018 returns were prepared in Online TurboTax, log into your account and at the Tax Home scroll down and expand the section "Your Tax Returns & Documents". Choose the relevant tax year, and then click "Download/print the PDF." . If you can't find your 2018 return there, then you likely have multiple accounts. Many people end up with multiple accounts without realizing it. Here's how to troubleshoot for multiple accounts (User IDs) :
You can have up to 5 accounts that use the same email address for notification purposes. A User ID may be an email address, but it doesn't have to be. It might be only part of an email address, or it can be anything at all.
To get a list of your User IDs and recover account access, you can use the tool at the link below. When using the Account Recovery tool, try using your phone number first. After that, if necessary, then run the tool on your email address(es) that you can access.
NOTE: Before running the account recovery tool below, log out of all Intuit accounts including this user forum, or you might end up in a loop. Then clear your browser Internet cache, close your browser, then reopen it, and go to the link below. You may wish to copy this link so you can paste it into the new browser session.
If still no luck after running that on your phone number and email address(es) that you can access, here's another method:
Go back to the tool again, but this time leave the data field blank, and choose the small blue link that says "Try something else", and it will look you up by SSN and other parameters.
I'm not sure what you are asking about "5-digit code."
You can use the 2018 AGI to verify your 2019 return for efiling. You won't need the 5-digit Self-Select PIN from last year, although we may be able to tell you how to find it if you want to reuse it as your signing PIN. Otherwise, you can create a new 5-digit PIN (you choose the digits) on the screen where you electronically sign your 2019 return.
Once you find the account with your 2018 return, log into it and scroll down to the section "Your Tax Returns & Documents." Expand that section and choose 2018. Then there is a link to "Download/print the PDF". Or you can use the link "View adjusted gross income (AGI.)"