Anonymous Login
2019-11-19 17:54 PST

View Issue Details Jump to Notes ]
IDProjectCategoryView StatusLast Update
0000516v2.2 Release (Closed)[All Projects] Generalpublic2010-12-19 13:22
ReporterFran 
Assigned Tocaseydk 
PrioritynormalSeveritymajorReproducibilityalways
StatusclosedResolutionfixed 
Product Version 
Target VersionFixed in Version2.2 
Summary0000516: Error in "contact_id" ambiguous displayed in several views and user admin not working
DescriptionHi everyone

After a fresh remote installation of r1239 I got an error displayed in the additional info.

Previously with v2.0 I coud not log in aftr a remote install because of a contact_id ambiguous error...

I follwed caseydk instructions for v2.0 and could log in after a minor tweak in /classes/ui.class.php but then another error for User Admin appeared. The fix for my previous problem is already included in the r1239, but now I can log in both with 2.0 and r1239 but I can not administrate users and get the error as I said before.

Thanks to you all...
Additional InformationERROR:

/trunk/classes/w2p/Database/Query.class.php(1115) : query failed(SELECT DISTINCT(user_id), user_username, contact_last_name, contact_first_name,
         company_name, contact_company, dept_id, dept_name, CONCAT(contact_first_name,' ',contact_last_name) contact_name, user_type,cm.method_value AS contact_email FROM ((`users` AS users))

INNER JOIN `contacts` AS con ON contact_id = user_contact
LEFT JOIN `contacts_methods` AS cm ON cm.contact_id = con.contact_id
LEFT JOIN `companies` AS com ON company_id = contact_company
LEFT JOIN `departments` AS dep ON dept_id = contact_department WHERE cm.method_name = 'email_primary'
GROUP BY user_id
ORDER BY contact_first_name, contact_last_name)

- error was: Column 'contact_id' in on clause is ambiguous

Backtrace:
0 .../trunk/classes/w2p/Database/Query.class.php:1115 dprint()
1 .../trunk/classes/w2p/Database/Query.class.php:1152 exec()
2 .../trunk/includes/main_functions.php:368 loadList()
3 .../trunk/modules/calendar/vw_day_events.php:67 w2PgetUsersList()
4 .../trunk/style/web2project/overrides.php:101 require()
5 .../trunk/modules/calendar/day_view.php:93 show()
6 .../trunk/index.php:363 require()
TagsNo tags attached.
Attached Files

-Relationships
+Relationships

-Notes

~0001140

caseydk (administrator)

Can you give me the url that you're seeing this at? Feel free to leave off the domain name.

~0001146

Fran (reporter)

Last edited: 2010-07-23 07:07

http://www.domainname.com/trunk

You meant that?

~0001148

Fran (reporter)

I didn't understand... but you can check at www.linkid7.com/trunk

Is a fresh installation of Web2project with an empty database so check it without problem.

User: admin
pass: admin

~0001149

zbyszek (reporter)

log on to the program, go to the module files, there may find a solution

~0001155

caseydk (administrator)

Thanks for the info.. resolved this one in r1274.

Here's the specific change:
http://web2project.svn.sourceforge.net/viewvc/web2project/trunk/includes/main_functions.php?r1=1259&r2=1274&pathrev=1274

~0001162

Fran (reporter)

Now the same type of error appears under Tasks view...

ERROR:

/home/linkidco/public_html/trunk/classes/w2p/Database/Query.class.php(1115) : query failed(SELECT DISTINCT(user_id), user_username, contact_last_name, contact_first_name, company_name, contact_company, dept_id, dept_name, CONCAT(contact_first_name,' ',contact_last_name) contact_name, user_type,cm.method_value AS contact_email FROM ((`users` AS users))

INNER JOIN `contacts` AS con ON contact_id = user_contact
LEFT JOIN `contacts_methods` AS cm ON cm.contact_id = con.contact_id
LEFT JOIN `companies` AS com ON company_id = contact_company
LEFT JOIN `departments` AS dep ON dept_id = contact_department WHERE cm.method_name = 'email_primary'
GROUP BY user_id
ORDER BY contact_first_name, contact_last_name)

- error was: Column 'contact_id' in on clause is ambiguous

Backtrace:
0 .../trunk/classes/w2p/Database/Query.class.php:1115 dprint()
1 .../trunk/classes/w2p/Database/Query.class.php:1180 exec()
2 .../trunk/includes/main_functions.php:408 loadHashList()
3 .../trunk/modules/tasks/tasks.class.php:1767 w2PgetUsersHashList()
4 .../trunk/modules/tasks/tasks.php:495 getAllocation()
5 .../trunk/modules/tasks/index.php:101 include()
6 .../trunk/index.php:363 require()

Column 'contact_id' in on clause is ambiguous

Feel free to check it using the same url user and pass.

Thanks

~0001163

caseydk (administrator)

I suspect this is due to your older version of mysql, but I've patched it a bit more in r1275. You can grab the update just as you did before.

Please let me know the result *asap* so I can close this if applicable. Thanks.

~0001164

Fran (reporter)

Finally...it did the trick... no error reporting under any tab now.

Thanks a million again. I will update the forums just in case someone has the same MySql problem.

Cheers

~0001165

caseydk (administrator)

Mostly a mysql problem, but somewhat fought in our code.

~0001211

Fran (reporter)

More MySql problems... this time when submitting an added a new Topic in Forums Module:

ERROR: .../classes/w2p/Database/Query.class.php(1115) : query failed (SELECT contact_first_name, contact_last_name,cm.method_value as contact_email FROM ((`users` AS u))

INNER JOIN `contacts` AS con ON contact_id = user_contact
LEFT JOIN `contacts_methods` AS cm ON cm.contact_id = con.contact_id WHERE cm.method_name = 'email_primary' AND user_id = 2) -

error was: Column 'contact_id' in on clause is ambiguous

Backtrace:
0 .../classes/w2p/Database/Query.class.php:1115 dprint()
1 .../modules/forums/forummessage.class.php:148 exec()
2 .../modules/forums/forummessage.class.php:85 sendWatchMail()
3 .../modules/forums/do_post_aed.php:18 store()
4 .../index.php:253 require()

ERROR: .../classes/w2p/Database/Query.class.php(1115) : query failed(SELECT DISTINCT user_id, contact_first_name, contact_last_name,cm.method_value as contact_email FROM ((`users` AS users,`forum_watch` AS forum_watch))

LEFT JOIN `contacts` AS con ON contact_id = user_contact
LEFT JOIN `contacts_methods` AS cm ON cm.contact_id = con.contact_id WHERE cm.method_name = 'email_primary' AND user_id = watch_user AND (watch_forum = 9 OR watch_topic = -1)) -

error was: Column 'contact_id' in on clause is ambiguous

Backtrace:
0 .../classes/w2p/Database/Query.class.php:1115 dprint()
1 .../modules/forums/forummessage.class.php:189 exec()
2 .../modules/forums/forummessage.class.php:85 sendWatchMail()
3 .../modules/forums/do_post_aed.php:18 store()
4 .../index.php:253 require()

After the error display the Topic is created but accessing the topic is useless because the error keeps on displaying in the "Post Reply" action.

~0001215

caseydk (administrator)

Updated and resolved in r1298.

~0001218

Fran (reporter)

Last edited: 2010-08-22 21:34

Applying the revision apparently doesn't fix the problem in my case... I haven't changed my MySql version or anything like that in between...or any other file but those in this present revision history.

after applying the revision r1298, clicking on any topic previously created ends in this following error:


ERROR: .../classes/w2p/Database/Query.class.php(1115) : query failed(SELECT forum_messages.*, contact_first_name, contact_last_name, user_username, forum_moderated, visit_user,cm.method_value as contact_email FROM ((`forums` AS forums,`forum_messages` AS forum_messages))

LEFT JOIN `forum_visits` AS v ON visit_user = 2 AND visit_forum = 11 AND visit_message = forum_messages.message_id
INNER JOIN `users` AS u ON message_author = u.user_id INNER JOIN `contacts` AS con ON contact_id = user_contact
LEFT JOIN `contacts_methods` AS cm ON cm.contact_id = con.contact_id WHERE cm.method_name = 'email_primary' AND forum_id = message_forum AND (message_id = 4 OR message_parent = 4)
ORDER BY message_date asc)

- error was: Column 'contact_id' in on clause is ambiguous

Backtrace:

0 .../classes/w2p/Database/Query.class.php:1115 dprint()
1 .../classes/w2p/Database/Query.class.php:1152 exec()
2 .../modules/forums/view_messages.php:24 loadList()
3 .../epm/modules/forums/viewer.php:91 include()
4 .../index.php:363 require()

~0001219

Fran (reporter)

Starting a new topic gives me this...

ERROR: /home/linkidco/public_html/epm/classes/w2p/Database/Query.class.php(1115) : query failed(SELECT contact_first_name, contact_last_name,cm.method_value as contact_email FROM ((`users` AS u))

INNER JOIN `contacts` AS con ON contact_id = user_contact
LEFT JOIN `contacts_methods` AS cm ON cm.contact_id = con.contact_id WHERE cm.method_name = 'email_primary' AND user_id = 2)

- error was: Column 'contact_id' in on clause is ambiguous

Backtrace:
0 .../classes/w2p/Database/Query.class.php:1115 dprint()
1 .../modules/forums/forummessage.class.php:148 exec()
2 .../modules/forums/forummessage.class.php:85 sendWatchMail()
3 .../modules/forums/do_post_aed.php:18 store()
4 .../index.php:253 require()

~0001220

Fran (reporter)

...after those errors, topics are created though, but clicking on them later on results in the error stated in the 0001218 post and so on...

Thanks.

~0001221

caseydk (administrator)

Please upgrade your mysql.. it will take less of your time than I'll end up wasting with these reports going back and forth.

~0001222

Fran (reporter)

Sorry caseydk. I understand you and fully thank you for all the support. The thing is that in cases like mine, in which people doesn't have access to the remote MySql version in hosted solutions, this is an issue that makes the application quite useless and most of my users tend to reject their implementation.

I just let those errors here in order to help the community with the little thing I can contribute, not to make you waste your time or anybody's time. If I could I would help you all in other ways. Right now I'm trying to promote the use of the app in several Departments in the University I work for, to manage R+D projects but, this is the error I'm finding and so I'm reporting.

If there is some problems with the MySql version, we all know or guess now, but is always more accurate reporting back and forth than stating that the issue is "resolved" when I'm experiencing that is not.

Cheers and thank again.

~0001223

caseydk (administrator)

Fran: Sorry for my tone. I'm not criticizing you or your efforts, they're appreciated.

Unfortunately, it's an *old* version of mysql that they don't even support anymore. This is a problem with the hosting companies not bothering to upgrade.

~0001224

Fran (reporter)

Hi caseydk.

No problem with that ;) I understood you... don't worry!

Right after posting here I contacted the host company to see what they can do about it, but as they are a reseller too, I don't have high hopes to see the upgrade done...that's why I hadn't done before actually. I'm crossing my fingers.

Thanks and keep up the good work!!

~0001410

caseydk (administrator)

This was resolved in r1515-1517, will be in the v2.2 release

~0001460

caseydk (administrator)

In v2.2 release.
+Notes

-Issue History
Date Modified Username Field Change
2010-07-22 13:54 Fran New Issue
2010-07-22 18:24 caseydk Note Added: 0001140
2010-07-22 18:24 caseydk Status new => feedback
2010-07-23 07:06 Fran Note Added: 0001146
2010-07-23 07:07 Fran Note Edited: 0001146
2010-07-27 13:52 Fran Note Added: 0001148
2010-07-27 20:44 zbyszek Note Added: 0001149
2010-07-31 17:07 caseydk Note Added: 0001155
2010-07-31 17:07 caseydk Status feedback => resolved
2010-07-31 17:07 caseydk Resolution open => fixed
2010-07-31 17:07 caseydk Assigned To => caseydk
2010-08-01 14:34 Fran Note Added: 0001162
2010-08-01 14:34 Fran Status resolved => feedback
2010-08-01 14:34 Fran Resolution fixed => reopened
2010-08-01 15:21 caseydk Note Added: 0001163
2010-08-01 15:29 Fran Note Added: 0001164
2010-08-02 05:59 caseydk Note Added: 0001165
2010-08-02 05:59 caseydk Status feedback => resolved
2010-08-02 05:59 caseydk Resolution reopened => fixed
2010-08-18 01:39 Fran Note Added: 0001211
2010-08-18 01:39 Fran Status resolved => feedback
2010-08-18 01:39 Fran Resolution fixed => reopened
2010-08-20 23:12 caseydk Note Added: 0001215
2010-08-20 23:12 caseydk Status feedback => resolved
2010-08-20 23:12 caseydk Resolution reopened => fixed
2010-08-22 21:33 Fran Note Added: 0001218
2010-08-22 21:33 Fran Status resolved => feedback
2010-08-22 21:33 Fran Resolution fixed => reopened
2010-08-22 21:34 Fran Note Edited: 0001218
2010-08-22 21:42 Fran Note Added: 0001219
2010-08-22 21:46 Fran Note Added: 0001220
2010-08-23 05:25 caseydk Note Added: 0001221
2010-08-23 06:03 Fran Note Added: 0001222
2010-08-23 09:06 caseydk Note Added: 0001223
2010-08-23 09:23 Fran Note Added: 0001224
2010-08-24 22:28 caseydk Project v2.0 Release (Closed) => Pending Requests
2010-12-07 10:02 caseydk Project Pending Requests => v2.2 Release (Closed)
2010-12-07 10:03 caseydk Note Added: 0001410
2010-12-07 10:03 caseydk Status feedback => resolved
2010-12-07 10:03 caseydk Resolution reopened => fixed
2010-12-19 13:22 caseydk Note Added: 0001460
2010-12-19 13:22 caseydk Status resolved => closed
2010-12-19 13:22 caseydk Fixed in Version => 2.2
+Issue History