How can I merge Notes from two Macbooks without using iCloud?
You can use Exporter (free app from app store) to save all notes as text to a folder on your computer. Then import them into other notes. 

It likely did work equivalent or extending on this reverse-engineering effort to get data from the database that backs the application:


https://articles.forensicfocus.com/2013/11/02/analysis-of-ios-notes-app/
What format does the apple notes sqlite db date use?


You could also just set up an IMAP server (even on your Mac) to sync up and then merge down the notes. iCloud isn’t the only server that can sync notes.


Sync Notes from Mac and iOS devices without iCloud