Jump to content

[SOLVED] SELECTing from a JOINed table.


Bakes

Recommended Posts

SELECT user.data1, user.data2, subgroup.name 
  JOIN subgroup ON
  (subgroup.id = user.subgroup) 
  JOIN group ON
  (group.id = subgroup.group)
WHERE user.level = 30 AND group.rank = 20

 

gives me error #1064.

I know the problem is that I am querying a joined table, but I am unsure how to fix it, so thought I'd post here.

Can anyone show me what my problem is?

Link to comment
https://forums.phpfreaks.com/topic/149503-solved-selecting-from-a-joined-table/
Share on other sites

sorry, I didn't say that I renamed the tables, because the guy who i'm doing this for wants me to release as little as possible (I've done this, for the most part, in Python, but I'm having some trouble with the web interface, and the SQL.)

 

it's actually something more along the lines of pho34_ugroup

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.