The ModMyTM Family of Sites:
ModMyMotoModMyiModMyGphone




 
 
Register or Connect with Facebook

Discuss AppStore Apps | Browse / Search Cydia | MMi Cydia Stats




  Apple Forums & iPhone Forums, Mods, Hacks, News, Themes, Downloads, and more! | ModMyi.com > iPhone Modding > File Mods
Reply
 
LinkBack Thread Tools Display Modes
  #1  
Old 06-02-2008, 12:13 AM
iPhone? More like MyPhone
 
Join Date: Jul 2007
Posts: 122
Thanks: 2
Thanked 10 Times in 8 Posts
Increasing call_history.db count bug

So awhile back I posted a thread on this and with the help of Piranha I was able to increase my call history count past 100. It was basically a simple trigger to re-insert the record back into the call table when it gets deleted by the system because it seems the 100 count is hard coded and no way to get around that.

So Ive been running it for almost 6-8months and noticed the other day that my recent list is somewhat jacked up, looking at the date it goes from todays to back a week then all the sudden jumps 2months back. After investigating more this is whats happening. I have my call_history set to hold 1000 (I do a select count on the condition of <1000 before enabling the trigger) and what seems to be happening is that anything above 100 is still being deleted and basically 900 are being deleted and reinserted. So whats happening is that they all get new ROWIDs as well. So every call I make the new ROWID is 900 higher than the previous one.

I tried a bunch of things, removed the condition to make it so its unlimited, but then it would just delete more from the list, so then it would delete 901, then 902 for the next call, 903 and so on, so basically it seems clear cut that its simply right off the bat deleting anything past 100 and the trigger is basically reinserted everything it deletes. So this is probably not going to work in the long run.

So not sure if anyone has seen this or looked at their recent calls list in detail if they have used this, but wondering if someone has a better solution to increasing the call_history table count.

Dixit



Here is the delete trigger Piranha helped me out with

Code:
CREATE TRIGGER [deleteKeep] 
BEFORE DELETE ON [call] 
FOR EACH ROW WHEN (select count(*) from call)<1000 
BEGIN 
insert into call
select null,address,date,duration,flags,id from call
where call.ROWID=OLD.ROWID ;
END
Digg StumbleUpon Delicious Reddit Newsvine Google Yahoo Thanks Reply With Quote
Reply

  Apple Forums & iPhone Forums, Mods, Hacks, News, Themes, Downloads, and more! | ModMyi.com > iPhone Modding > File Mods

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



Go to Top
ModMyI

All times are GMT -6. The time now is 12:36 PM. Powered by vBulletin® Version 3.8.4
If you need Dedicated Server Hosting, you should check out SingleHop. | Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.3.0 Copyright © 2007-09 by ModMy, LLC. All rights reserved.

iPhone News / iPhone Forums / Apple News / Apple Forums / RSS / Contact Us / / Privacy Statement / Top