I just had the same problem as all of you guys.
I used Ralph Johns' steps but it didn't seem to work.
I was migrating from a Mac to another Mac with the same username.
The problem here is that your new mac wrongly recognizes you as the file owner already and doesn't let you switch it in the info panel.
While changing me to the file owner worked on the Attachments and archive folder, the Chat.db etc. were the problem.
The solution to this is to use a terminal command.
First you have to find out your exact user name. Use " Is /Users " and then press enter to find this out and copy it.
Now in the next line type " chown YourUsername FilePathHere"
Chown is the command used to make you the file owner.
YourUsername gets replaces by the username you found out in the step before
for FilePathHere just drag and drop the 3 databases from the -/Library/Messages/ folder in here.
Press enter (you might have to confirm with your password)
After you have completed this for all 3 Databases restart your Mac and everything should be working.