
7th December 2008, 15:19
|
|
Senior Member
|
|
Join Date: Oct 2006
Posts: 533
Thanks: 4
Thanked 2 Times in 2 Posts
|
|
Problem on editing data on MySQL table
Hi folks,
I have a table tblPerdition created on dbPerdition
Code:
mysql> SHOW tables;
+-----------------------+
| Tables_in_dbPerdition |
+-----------------------+
| tblPerdition |
+-----------------------+
1 row in set (0.00 sec)
Code:
mysql> DESCRIBE tblPerdition;
+------------+--------------+------+-----+---------+-------+
| Field | Type | Null | Key | Default | Extra |
+------------+--------------+------+-----+---------+-------+
| user | varchar(128) | NO | PRI | | |
| servername | varchar(255) | NO | | | |
| port | varchar(8) | YES | | NULL | |
+------------+--------------+------+-----+---------+-------+
3 rows in set (0.00 sec)
On editing data on the table;
Code:
mysql> INSERT INTO user VALUES
-> ('userA@domainA.com'),
-> ('userA@domianB.com'),
-> ('userA@domainC.com');
ERROR 1146 (42S02): Table 'dbPerdition.user' doesn't exist
Please advise how to fix the problem? Whether I need to edit;
Code:
('userA'@'domainA.com')
???
TIA
B.R.
satimis
|

8th December 2008, 10:19
|
|
Member
|
|
Join Date: Feb 2006
Posts: 65
Thanks: 0
Thanked 2 Times in 2 Posts
|
|
your table seems to suggest
Quote:
Code:
mysql> DESCRIBE tblPerdition;
+------------+--------------+------+-----+---------+-------+
| Field | Type | Null | Key | Default | Extra |
+------------+--------------+------+-----+---------+-------+
| user | varchar(128) | NO | PRI | | |
| servername | varchar(255) | NO | | | |
| port | varchar(8) | YES | | NULL | |
+------------+--------------+------+-----+---------+-------+
3 rows in set (0.00 sec)
|
Code:
mysql> use dbPerdition;
->INSERT INTO tblPerdition (user, servername) VALUES
-> ('userA','domainA.com'),
-> ('userA','domianB.com'),
-> ('userA','domainC.com');
__________________
Always mention at least your distribution/version! You can add it in your signature if you don't want to always type it. ;-)
Distributions:
Ubuntu 5.10 with custom kernel (2.6.16-suspend2),
Debian Sarge 3.1 and Etch
Please submit your ISP or Webhost to (free)
http://www.ihostnz.com
|

8th December 2008, 14:27
|
|
Senior Member
|
|
Join Date: Oct 2006
Posts: 533
Thanks: 4
Thanked 2 Times in 2 Posts
|
|
Quote:
Originally Posted by geek.de.nz
Code:
mysql> use dbPerdition;
->INSERT INTO tblPerdition (user, servername) VALUES
-> ('userA','domainA.com'),
-> ('userA','domianB.com'),
-> ('userA','domainC.com');
|
Hi geek.de.nz,
Thanks for your advice.
Ran;
Code:
mysql> INSERT INTO tblPerdition (user, servername) VALUES
-> ('satimis','satimis.com'),
-> ('satimis','satimis.changeip.net'),
-> ('satimis','satimis.dnsalias.com');
ERROR 1062 (23000): Duplicate entry 'satimis' for key 1
B.R.
satimis
|

10th December 2008, 00:35
|
|
Senior Member
|
|
Join Date: Sep 2008
Posts: 139
Thanks: 2
Thanked 14 Times in 14 Posts
|
|
user field is primary key, so you can't have duplicate values. Maybe you created the primary key wrong.
________
VAPORBROTHERS
________
THREESOME MOVIES
Last edited by marpada; 13th May 2011 at 01:58.
|

10th December 2008, 03:34
|
|
Senior Member
|
|
Join Date: Oct 2006
Posts: 533
Thanks: 4
Thanked 2 Times in 2 Posts
|
|
Quote:
Originally Posted by marpada
user field is primary key, so you can't have duplicate values. Maybe you created the primary key wrong.
|
I was following this document;
http://www.vergenet.net/linux/perdit...tiondb.5.shtml
to config/setup perdition creating a MySQL table. The primary key is required there. Their mailing list can't help me out. I'm looking around for a solution.
Besides, the descriptor of Null is either YES or NO. It needs blank there.
satimis
|

11th December 2008, 22:57
|
|
Senior Member
|
|
Join Date: Sep 2008
Posts: 139
Thanks: 2
Thanked 14 Times in 14 Posts
|
|
Quote:
|
Perdition supports a dynamic library mechanism to access arbitrary databases that resolve a user to a host and port.
|
Quote:
|
The user field must also be a unique index as an exact match will be made of this field from the username supplied by the user.
|
If a user must be resolved to a host and a port is doesn't make sense that you try to add duplicate users, does it?
________
Ipad guide
________
big women Cam
Last edited by marpada; 13th May 2011 at 01:58.
|

12th December 2008, 00:52
|
|
Senior Member
|
|
Join Date: Oct 2006
Posts: 533
Thanks: 4
Thanked 2 Times in 2 Posts
|
|
Quote:
Originally Posted by marpada
If a user must be resolved to a host and a port is doesn't make sense that you try to add duplicate users, does it?
|
Same user holding several email address must be allowed which is not considered as duplicate user (on MySQL table maybe). Actually the setup on 2 key components are critical, the config file of perdition and the table of the database, 'tblPerdition'.
The whole system is now working perfectly on Intranet. Incoming mails are routed by the routing mail server to their mail servers running as guests on the Xen box. Mail clients running on workstations on the Intranet can send and receive mails via their own mail server. If allotting each mail server a port my problem may be solved already. But this is NOT the goal of my test. Not many perdition document/link can be found on googling. If I can't solve my problem with Perdition I'll move to nginx.
B.R.
satimis
|
| Thread Tools |
|
|
| Display Modes |
Linear Mode
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
All times are GMT +2. The time now is 13:55.
|
|
Recent comments
12 hours 33 min ago
17 hours 38 min ago
22 hours 3 min ago
23 hours 51 min ago
1 day 14 hours ago
1 day 14 hours ago
1 day 19 hours ago
2 days 1 hour ago
2 days 2 hours ago
2 days 3 hours ago