I can only rate one resource, when I try to Rate a different link, LinksSQL says my IP address is already in the database. How do I let users Rate more than one resource but not allow them to Rate the same one more than once?? Any help would be appreciated.
Jul 6, 2000, 7:04 PM
Veteran / Moderator (6956 posts)
Jul 6, 2000, 7:04 PM
Post #2 of 3
Views: 2642
This has been addressed before.
The program lets you rate any resource once in 24 hours from any IP.
If it's not, then you have a corrupted primary index in the rate_track (?) file (I don't have FTP access at the moment to check the files).
You need to have a primary key on IP & ID, not just IP or ID.
http://www.postcards.com
FAQ: http://www.postcards.com/FAQ/LinkSQL/
The program lets you rate any resource once in 24 hours from any IP.
If it's not, then you have a corrupted primary index in the rate_track (?) file (I don't have FTP access at the moment to check the files).
You need to have a primary key on IP & ID, not just IP or ID.
http://www.postcards.com
FAQ: http://www.postcards.com/FAQ/LinkSQL/
Jul 7, 2000, 2:46 AM
Veteran / Moderator (6956 posts)
Jul 7, 2000, 2:46 AM
Post #3 of 3
Views: 2635
Ok,
I dropped the table, and reconstructed it from the SQL.mysql file.
CREATE TABLE Rate_Track (
LinkID INT UNSIGNED NOT NULL,
IP CHAR(25) NOT NULL,
Created TIMESTAMP,
UNIQUE lndx (LinkID, IP),
INDEX cndx (Created)
)
Let me know if it's working now.
Before, you only had the IP field as "primary". Now both the IP,LinkID are flagged as "primary"
That should fix the problem.
http://www.postcards.com
FAQ: http://www.postcards.com/FAQ/LinkSQL/
I dropped the table, and reconstructed it from the SQL.mysql file.
CREATE TABLE Rate_Track (
LinkID INT UNSIGNED NOT NULL,
IP CHAR(25) NOT NULL,
Created TIMESTAMP,
UNIQUE lndx (LinkID, IP),
INDEX cndx (Created)
)
Let me know if it's working now.
Before, you only had the IP field as "primary". Now both the IP,LinkID are flagged as "primary"
That should fix the problem.
http://www.postcards.com
FAQ: http://www.postcards.com/FAQ/LinkSQL/