Welcome to Geeklog, Anonymous Thursday, July 18 2024 @ 08:39 pm EDT

Geeklog Forums

duplicate sid's, please help


M4CFR34K

Anonymous
So, I started designing this site in geeklog and I have fallen in love with the system. I'm writing a repeating events engine that keeps track of the many events it creates so they can all be deleted at once (and yes i do plan to release the code when I’m done). But the problem is when I’m creating particularly large sets of events, I get events with the same eid Doh! - that was a mistake . is there any easy way of fixing this without having to rewrite the sid code and completely reset the site? Any help would be greatly appreciated. Thanks!
 Quote

Status: offline

Dirk

Site Admin
Admin
Registered: 01/12/02
Posts: 13073
Location:Stuttgart, Germany
The standard IDs are a timestamp plus up to 3 random characters. You should really only run into duplicates if you create several IDs per second.

Geeklog itself doesn't rely on the event id being formatted as it is, so you are free to create your own IDs. As long as they don't exceed 20 characters and there's no 3rd party add-on that relies on the old format, you should be fine.

bye, Dirk
 Quote

Status: offline

M4CFR34K

Forum User
Newbie
Registered: 06/02/05
Posts: 1
Thanks. The code does create the events individually, so in large repeating event jobs this poses a problem, I will probably keep the timestamp but use an incremental value following it. However if I continue to use event.php to create the events, this becomes a bit more in-depth of a hack.
 Quote

Status: Banned

gtgillis

Forum User
Full Member
Registered: 11/05/03
Posts: 121
Did you ever have any luck getting this code together?
 Quote

All times are EDT. The time is now 08:39 pm.

  • Normal Topic
  • Sticky Topic
  • Locked Topic
  • New Post
  • Sticky Topic W/ New Post
  • Locked Topic W/ New Post
  •  View Anonymous Posts
  •  Able to post
  •  Filtered HTML Allowed
  •  Censored Content