Unix Technical Forum

left join , Unknown column 't1.itemid' in 'on clause'

This is a discussion on left join , Unknown column 't1.itemid' in 'on clause' within the MySQL General forum forums, part of the MySQL category; --> Hi, select * from t1,t2 left join t3 on t3.itemid=t1.itemid mysql4.1 works, but mysql5.0 shows Unknown column 't1.itemid' in ...


Go Back   Unix Technical Forum > Database Server Software > MySQL > MySQL General forum

Register FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 02-28-2008, 05:08 AM
wang shuming
 
Posts: n/a
Default left join , Unknown column 't1.itemid' in 'on clause'

Hi,
select * from t1,t2
left join t3 on t3.itemid=t1.itemid

mysql4.1 works, but mysql5.0 shows Unknown column 't1.itemid' in 'on clause'

If change into
select * from t2,t1
left join t3 on t3.itemid=t1.itemid

mysql5.0 works

ShumingˇˇWang
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 02-28-2008, 05:08 AM
Rolando Edwards
 
Posts: n/a
Default Re: left join , Unknown column 't1.itemid' in 'on clause'

This is makes more sense because it causes a SQL developer
to group the joined tables in a logical manner.

----- Original Message -----
From: wang shuming <wangshuming01@gmail.com>
To: mysql@lists.mysql.com
Sent: Friday, November 3, 2006 8:04:20 PM GMT-0500 US/Eastern
Subject: left join , Unknown column 't1.itemid' in 'on clause'

Hi,
select * from t1,t2
left join t3 on t3.itemid=t1.itemid

mysql4.1 works, but mysql5.0 shows Unknown column 't1.itemid' in 'on clause'

If change into
select * from t2,t1
left join t3 on t3.itemid=t1.itemid

mysql5.0 works

Shuming Wang

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 05:25 PM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0
www.UnixAdminTalk.com