PDA

View Full Version : Help me with VSDan's Rate Mod


PortProphecy
08-27-2006, 11:08 PM
I have dowloaded VSDan's Rate Listing [phpLD 3.04+ Only] and would like to add to one of my directories. My only problem is that I am completely hopeless when it comes to MySQL and PHPmyAdmin.

One of the steps in the install is:
Content visible to registered users only.

I am only good with commands that I can just run an SQL query on. But this kind of thing, I am lost. Any help would be appreciated. Thanks.

Boby
08-27-2006, 11:29 PM
Run following SQL query via phpMyAdmin or in the maintenance section of your phpLD admin panel
System >> Maintenance >> Run SQL query on database

Content visible to registered users only.
That's all ;)

Boby

PortProphecy
08-28-2006, 12:01 AM
Thanks for the help, Boby. :D

potyka
10-15-2006, 12:12 PM
Hi I my also similar problem phpld2.0 version


CREATE TABLE `PLD_LINK_RATE` (
`ID` int( 11 ) NOT NULL AUTO_INCREMENT ,
`LINK_ID` int( 11 ) NOT NULL default '0',
`IPADDRESS` varchar( 15 ) NOT NULL default '',
PRIMARY KEY ( `ID` ) ,
KEY `LINK_ID` ( `LINK_ID` , `IPADDRESS` )
) ENGINE = InnoDB;

MySQL jelzi: Dokumentáció
#1050 - Table 'PLD_LINK_RATE' already exists

VSDan
10-15-2006, 06:35 PM
1. I apologize for that. I've updated all mods that require changes to be made to the database - they now provide the SQL statements to use.

2.
Content visible to registered users only.

Were you not using another rating mod before? What does PLD_LINK_RATE look like now? Don't know how?

1. Go to your phpMyAdmin.
2. Select phpLD database.
3. Select PLD_LINK_RATE table.
4. Click on the [Export] tab.
5. De-select Data: box.
6. Click on the [Go] button.

Or, you could just drop the PLD_LNK_RATE table, and restore via:

CREATE TABLE `PLD_LINK_RATE` (
`ID` int( 11 ) NOT NULL AUTO_INCREMENT ,
`LINK_ID` int( 11 ) NOT NULL default '0',
`IPADDRESS` varchar( 15 ) NOT NULL default '',
PRIMARY KEY ( `ID` ) ,
KEY `LINK_ID` ( `LINK_ID` , `IPADDRESS` )
) ENGINE = InnoDB;

potyka
10-15-2006, 07:02 PM
Now the bug I tried message the consequent :(

ALTER TABLE `PLD_LINK` ADD `RATE_TOTAL` INT( 11 ) DEFAULT '0' NOT NULL ,
ADD `RATE_COUNT` INT( 11 ) DEFAULT '0' NOT NULL ,
ADD `RATE` DECIMAL( 2, 2 ) DEFAULT '0' NOT NULL ,
ADD `RATE_ENABLED` TINYINT( 4 ) DEFAULT '1' NOT NULL ;

MySQL jelzi: Dokumentáció
#1060 - Duplicate column name 'RATE_TOTAL'

VSDan
10-15-2006, 07:21 PM
Content visible to registered users only.

One quick and easy option is to drop those 4 fields from the PLD_LINK table, but any existing rating data will be lost. To preserve the data, edit those existing fields so that they are in same format as those in the SQL statement - odds are that you just need to rename some of them, or you may not have to make any changes (in which case, you can skip this step).

potyka
10-16-2006, 06:16 PM
At last succeeded!Very very I thank !!!!:)

VSDan
10-16-2006, 06:20 PM
You're welcome =)