Register to post in forums, or Log in to your existing account
 

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » zMUD General Discussion
Karth
Newbie


Joined: 17 Apr 2005
Posts: 5

PostPosted: Sun Apr 17, 2005 11:42 pm   

Question regarding database.
 
Ok, here's the situation, I'm an Imm on a mud, and in order to help crack down on various cheating a fellow Imm created this trigger to keep track of our player base's IP's, allowing us to quickly check to see if things are kosher.

The problem is that the database keeps track of *every* entry, and so you wind up with countless duplicates and over a short period of time I'm stuck with 10,000 plus entries, when I get that many, my computer just lags down each time the database is loaded. What I wanted to know is if there was any way to fix these triggers to prevent duplicate entries based on the IP to cut down on this massive database that I have to keep clearing out. And as a bonus, is there anyway to make a second alias that will scan the database based on the characters names along with the one show that scans based on the IP.

Here are the triggers.

#trigger {(%w)~[(*)~] has connected.>} {#dbload pl;#new pl %2 %1;#dbnext;#echo %2 %1;#wa 500;#dbsave}

#trigger {(%w)~[(*)~] ~(Guest~) has entered the game.>} {#dbload pl;#new pl %2 %1;#dbnext;#echo %2 %1;#wa 500;#dbsave}

#alias {ipchk} {#dbload pl;#find %1;#dbload pl}

Thanks in advance for any help, hope I got my question across clearly enough.
Reply with quote
Rorso
Wizard


Joined: 14 Oct 2000
Posts: 1368

PostPosted: Mon Apr 18, 2005 5:11 am   
 
Check my database tutorial at http://www.silverbridge.org/~varmel/zmud/tutorials/zmuddb.htm which explains how to handle duplicates.
Reply with quote
Karth
Newbie


Joined: 17 Apr 2005
Posts: 5

PostPosted: Mon Apr 18, 2005 8:31 am   
 
Thank you so much, that will be a lot of help.
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » zMUD General Discussion All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

© 2009 Zugg Software. Hosted by Wolfpaw.net