[Android Q&A, Help & Troubleshooting] Brickadier:
Before doing this BACK UP YOUR SMS/MMS!!! If you screw something up and lose everything don't come crying to me, back your crap up!

Now, here is how I did it. This merged 2 different phone numbers/threads into 1 SMS thread and moved all MMS (Pictures/Media) as well.

In my XML file I found these 4 formats for the number I was changing, why the numbers are all different formats I have no idea. Make sure you don't have even more.

(555) 444-7777

5554447777

+15554447777

+1 555-444-7777

And here is a small sample from the XML file with the numbers changed to the 555 crap or X'd out.

-----------------------------------------------------------------------------------------------------------------------------------------

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>

<threads count="7" xmlns="XXXXXXXXXXXXXXXXXXXXXX">

<thread address="+15554447777">

<sms msgBox="inbox" date="2012-07-30T21:40:43.522Z" locked="false" seen="true" read="true" serviceCenter="+1XXXXXXXXXX" address="+15554447777" encoding="plain">Hello World!</sms>

<sms msgBox="inbox" date="2012-07-30T21:41:13.522Z" locked="false" seen="true" read="true" serviceCenter="+1XXXXXXXXXX" address="+15554447777" encoding="plain">Hello World AGAIN!</sms>

<mms msgBox="sent" version="1.2" type="sendReq" contentType="application/vnd.wap.multipart.related" date="2012-09-08T02:30:19.000Z" locked="false" seen="true" read="true" subject="">

<addresses>

<address type="from">insert-address-token</address>

<address type="to">5554447777</address>

</addresses>

<part contentType="application/smil" contentId="<smil>" contentLocation="smil.xml" encoding="plain"><smil><head><layout><root-layout width="1230px" height="720px"/><region id="Image" left="0" top="0" width="1230px" height="648px" fit="meet"/></layout></head><body><par dur="5000ms"><img src="IMG_20120907_212958.jpg" region="Image"/></par></body></smil></part>

<part contentType="image/jpeg" order="0" contentId="<IMG_20120907_212958>" contentLocation="IMG_20120907_212958.jpg" encoding="base64">/9j/4ABAAD/2wBDAAIBAQEBAQIBAQECAgICAgQDAgICAgUEBAMEB</part>

</mms>

</thread>

</threads>

-----------------------------------------------------------------------------------------------------------------------------------------

First off, I used Titanium Backup Pro to dump SMS/MMS to XML (It's under Options/Backup data to XML) I have no idea if the standard Titanium Backup has this or not.

Titanium Backup Pro stores the messages with all SMS first, then all MMS after for that thread. What I did was a search/replace for all 4 different number formats listed above to the new phone number, then I cut/pasted all of the SMS from the new number thread the old number thread right under the last SMS message in that thread, then I cut/pasted the MMS from the new number thread to the old number thread at the end of the MMS section. In short, I moved the SMS and MMS from one thread to the other to their corresponding areas. I moved the "new" number to the old number thread because there were only a handful of messages in the new thread so I went that route. And because I did it this way, all the messages were in order by date.

After I had emptied out the thread (nothing between <thread address="XXXXXXXXXX"> and </thread>) I deleted the thread.

Then I updated the threads count to "6" because I was merging 2 threads and of course taking one thread away from the 7 threads = 6, saved it, and then restored it using Titanium Backup and BAM, 2 threads were now 1 with all of my texts and pictures intact.

Now, I have no idea if the cut/pasting is necessary or if Titanium and Android can magically figure out the two threads belong together after changing all the numbers but I didn't feel like messing with it. I just made it a nice neat XML file like I figured it should be and went with that.

For the XML editor I used XMLSpy 30 day trial (it's expensive to buy but I figured I would only be doing this once so what the heck, trial it is) but I'm sure anything that edits XML properly

would do just fine.

Initially I tried merging the two threads using Sqlite3 update commands on mmssms.db and succeeded in merging the 2 SMS threads but found that MMS didn't follow and decided that I'd rather mess with XML. Eh...

Also, if for some reason (like me) you can't see the XML backup file in Windows I wound up just using adb to pull/push the file from/to the phone.

Anyway, hope this helps those of you trying to do this. Good luck!