Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Works in mysql 4 not in mysql 3

Status
Not open for further replies.

CassidyHunt

IS-IT--Management
Jan 7, 2004
688
US
This is about as straight forward of query as it get and I do not understand why it doesn't work in 3.

Code:
select b.miva_code,
a.pc_make,
a.year,
a.category,
c.description as "make_desc",
a.subcategory,
b.condition_code,
a.record_id,
b.product_cost,
b.product_price,
a.product_name,
b.composite_description,
a.prestige,
a.hue_code,
d.description as "cat_desc",
e.sub_desc as "sub_desc",
a.filename_tn,a.filename_fs 
from mastercatalog a, productdetails b, makes c, categories d, subcategories e where a.record_id = b.record_id and c.pc_make = a.pc_make and d.cat_code = a.category and e.sub_code = a.subcategory
 
Could you please be a tad more elaborate as to what "doesn't work" means?
 
You should either remove the double-quotes from around the aliases or replace them with back-ticks:[tt] as `make_desc`[/tt]

Double-quotes are only used to enclose constant strings. Backticks can be used to enclose user-defined names, but are only needed if a name would otherwise be illegal.
 
Turned out to be a problem with the host not loading Mysql correctly. After they reloaded it everything worked fine.

Thanks for the input.

Cassidy
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top