Re: sms database

Dennis Reichel <[email protected]> Sat, 19 May 2012 11:59:21 -0400
Newsgroups gmane.comp.mobile.bitpim.devel
Organization Reichel Systems Support
Message-ID <[email protected]>
--===============6090468556562404077==
Content-Type: multipart/alternative; boundary="=-ucLn8Na7kkJDOQV37JZF"


--=-ucLn8Na7kkJDOQV37JZF
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: 7bit

My guess about  UIDs is that they are something like email message
uids.. They commonly encode an identifier for the client that originated
the message and a timestamp
to ensure uniqueness.  There's probably an RFC covering this.

A possible use of UID would be to identity replies and even threads of
messaging.

I'd suggest that you test your hypothesis that the original DB can not
be read because of the records with invalid UIDs by deleting those
suspect records and 
trying to read the SMS table in Bitpim.

Also, you could set some UIDS to NULL in your working test database to
see if that causes breakage.

A useful resource: http://www.sqlite.org/sqlite.html


On Fri, 2012-05-18 at 20:47 -0700, JusGreen Auto Wash wrote: 

> Hello, My BitPim database had become currupted somehow in January of
> this year, and I only recently discovered this when I tried to
> retreive an old text.
>  
> When I downloaded my text's from my phone, I could see that the texts
> were being downloaded as I could read the status bar and it saying
> that it was retrieving texts from the OUTBOX of my phone. Yes I only
> had a problem with my SENT text's download to the BitPim database.
>  
> I feel that my database had somehow became currupted during one of my
> system restores, and I had not noticed the problem till now.
>  
> After some research, I found out what sort of database BitPim used and
> tried to fix the error manually. On, before this, I moved my regular
> BitPim folder from the My Documents folder and allowed BitPim to
> create a new database. I then tested it and it downloaded and
> displayed both incoming and out going message.
>  
> It appeared that the problem was with the UID field, as a few of the
> records were NULL, and most the rest were not; most of the sent texts
> from my phone had not had a UID, but others did, and the ones that did
> displayed in BitPim.
>  
> I converted the database to access, then wrote an ASP script to
> regenerate UID's. I noticed that only the last 9 digits had changed
> throughout the database. After generating UID's, imported the database
> back into the BitPim database and tried to access the sms's via
> BitPim. It did not work...
>  
> So, this brings me here; could someone explain to me, how the UID's
> are generated, so that I could repair my database. My ASP script took
> the first # of the UID and hard fixed it for all records [ 1337112 ];
> then it randomly generated two more strings separated by a decimal
> point; one 3 [ 097 ] digits and the other 6 [ 097414 ] digits.
>  
> Additionally, for each sms record, I had my script generate a record
> into the sms__serials table, although, when the sms__serials table was
> done building it only had 1219 records versus the 1269 in sms table;
> exactly the same results as when started this show.
>  
> Any help would be appreciated. Thanks!
>  
> 
> ------------------------------------------------------------------------------
> Live Security Virtual Conference
> Exclusive live event will cover all the ways today's security and 
> threat landscape has changed and how IT managers can respond. Discussions 
> will include endpoint security, mobile security and the latest in malware 
> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
> _______________________________________________ BitPim-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/bitpim-devel


-- 
Best Regards, Dennis Reichel
Reichel Systems Support
[email protected]
http://www.reichel.net
561-463-6020




--=-ucLn8Na7kkJDOQV37JZF
Content-Type: text/html; charset="utf-8"
Content-Transfer-Encoding: 7bit

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 TRANSITIONAL//EN">
<HTML>
<HEAD>
  <META HTTP-EQUIV="Content-Type" CONTENT="text/html; CHARSET=UTF-8">
  <META NAME="GENERATOR" CONTENT="GtkHTML/4.2.3">
</HEAD>
<BODY>
My guess about&nbsp; UIDs is that they are something like email message uids.. They commonly encode an identifier for the client that originated the message and a timestamp<BR>
to ensure uniqueness.&nbsp; There's probably an RFC covering this.<BR>
<BR>
A possible use of UID would be to identity replies and even threads of messaging.<BR>
<BR>
I'd suggest that you test your hypothesis that the original DB can not be read because of the records with invalid UIDs by deleting those suspect records and <BR>
trying to read the SMS table in Bitpim.<BR>
<BR>
Also, you could set some UIDS to NULL in your working test database to see if that causes breakage.<BR>
<BR>
A useful resource: <A HREF="http://www.sqlite.org/sqlite.html">http://www.sqlite.org/sqlite.html</A><BR>
<BR>
<BR>
On Fri, 2012-05-18 at 20:47 -0700, JusGreen Auto Wash wrote: <BR>
<BLOCKQUOTE TYPE=CITE>
    Hello, My BitPim database had become currupted somehow in January of this year, and I only recently discovered this when I tried to retreive an old text.<BR>
    &nbsp;<BR>
    When I downloaded my text's from my phone, I could see that the texts were being downloaded as I could read the status bar and it saying that it was retrieving texts from the OUTBOX of my phone. Yes I only had a problem with my SENT text's download to the BitPim database.<BR>
    &nbsp;<BR>
    I feel that my database had somehow became currupted during one of my system restores, and I had not noticed the problem till now.<BR>
    &nbsp;<BR>
    After some research, I found out what sort of database BitPim used and tried to fix the error manually. On, before this, I moved my regular BitPim folder from the My Documents folder and allowed BitPim to create a new database. I then tested it and it downloaded and displayed both incoming and out going message.<BR>
    &nbsp;<BR>
    It appeared that the problem was with the UID field, as a few of the records were NULL, and most the rest were not; most of the sent texts from my phone had not had a UID, but others did, and the ones that did displayed in BitPim.<BR>
    &nbsp;<BR>
    I converted the database to access, then wrote an ASP script to regenerate UID's. I noticed that only the last 9 digits had changed throughout the database. After generating UID's, imported the database back into the BitPim database and tried to access the sms's via BitPim. It did not work...<BR>
    &nbsp;<BR>
    So, this brings me here; could someone explain to me, how the UID's are generated, so that I could repair my database. My ASP script took the first # of the UID and hard fixed it for all records [ 1337112 ]; then it randomly generated two more strings separated by a decimal point; one 3 [ 097 ] digits and the other 6 [&nbsp;097414 ] digits.<BR>
    &nbsp;<BR>
    Additionally, for each sms record, I had my script generate a record into the sms__serials table, although, when the sms__serials table was done building it only had 1219 records versus the 1269 in sms table; exactly the same results as when started this show.<BR>
    &nbsp;<BR>
    Any help would be appreciated. Thanks!<BR>
    &nbsp;
<PRE>
------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. <A HREF="http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/">http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/</A>
_______________________________________________ BitPim-devel mailing list <A HREF="mailto:[email protected]">[email protected]</A> <A HREF="https://lists.sourceforge.net/lists/listinfo/bitpim-devel">https://lists.sourceforge.net/lists/listinfo/bitpim-devel</A>
</PRE>
</BLOCKQUOTE>
<BR>
<TABLE CELLSPACING="0" CELLPADDING="0" WIDTH="100%">
<TR>
<TD>
-- <BR>
Best Regards, Dennis Reichel<BR>
Reichel Systems Support<BR>
<A HREF="mailto:[email protected]">[email protected]</A><BR>
<A HREF="http://www.reichel.net">http://www.reichel.net</A><BR>
561-463-6020<BR>
<BR>
<BR>
<BR>
</TD>
</TR>
</TABLE>
</BODY>
</HTML>

--=-ucLn8Na7kkJDOQV37JZF--



--===============6090468556562404077==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
--===============6090468556562404077==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

_______________________________________________
BitPim-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bitpim-devel

--===============6090468556562404077==--