A quick search on Google finds this article in Quicken help:
https://www.quicken.com/support/move-transactions-between-quicken-accounts
Basically, it looks like you will have to pick one file as the one that will live on, and the other will need to be imported account-by-account into the first one. Call them master and slave files. Master continues, slave gets imported into master.
For the master, you will need to create empty accounts for every account in the slave file. You may also need to look at the full category list in the slave and make sure the master has these categories — if not then create them in the master.
The link above then provides guidance as to how to move a single transaction from an account in the slave to the account in the master file. You *should* be able to highlight or select all transactions in an account, but not positive this will work (I haven’t tried it).
This is from 2009 version, but it sounds like it might still work for recent versions and involves a lot of steps to export and then import data.
https://community.quicken.com/discussion/7150406/how-to-merge-two-quicken-files
It does look like it is very messy and a lot of work to do.
Final, but most importantly: make backups or copies of both files before doing anything so that if all goes wrong, you have the originals to start from again.