Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Error Message on Products ver 2.2


rak1

Recommended Posts

Posted

Hi, Im running ver 2.2 Osc

Im getting this error when I make a Cat or add a Product???

 

Anyone had this or can Help with this and tell me how to fix it Please?

 

1054 - Unknown column 'p.products_id' in 'on clause'

 

select count(p.products_id) as total from products_description pd, products p left join manufacturers m on p.manufacturers_id = m.manufacturers_id, products_to_categories p2c left join specials s on p.products_id = s.products_id where p.products_status = '1' and p.products_id = p2c.products_id and pd.products_id = p2c.products_id and pd.language_id = '1' and p2c.categories_id = '22'

 

[TEP STOP]

 

====================================================================================================

 

Im Also getting this :

[ Warning: I am able to write to the configuration file: /home/jerdad/public_html/includes/configure.php. This is a potential security risk - please set the right user permissions on this file. ]

 

I have tried setting it to 644 and 444 ???

 

Thanks for all help

Posted

@@rak1

 

What release of 2.2 ? Is that MS2, Rc1 or Rc2a ?

 

 

More than likely, your server software has been updated and your site now needs to be updated to continue working.

 

 

 

Chris

Posted

@@rak1

 

No, actually. I recommend you create a new cart using v2.3.3. You are currently 5 versions behind.

 

 

 

Chris

Posted
1054 - Unknown column 'p.products_id' in 'on clause'

 

select count(p.products_id) as total from products_description pd, products p left join manufacturers m on
p.manufacturers_id = m.manufacturers_id, products_to_categories p2c left join specials s on p.products_id = s.products_id
where p.products_status = '1' and p.products_id = p2c.products_id and pd.products_id = p2c.products_id and
pd.language_id = '1' and p2c.categories_id = '22'

It sounds like your host has upgraded to MySQL 5, and your old osC needs updating to work with it. MySQL 5 changed some operator precedence (LEFT JOIN is now higher than COMMA). In this particular query, it would become

 

select count(p.products_id) as total from ((products_description pd, products p) left join manufacturers m on
p.manufacturers_id = m.manufacturers_id, products_to_categories p2c) left join specials s on p.products_id = s.products_id
where p.products_status = '1' and p.products_id = p2c.products_id and pd.products_id = p2c.products_id and
pd.language_id = '1' and p2c.categories_id = '22'

Similar changes would be needed in several other places (and obviously, in the .php source) -- do a search on this forum to find discussion on them.

Posted

Thanks, the reason I was using this version is because I wanted to use a 2.x jewelry template I found, Is there a Fix for this ?

Or a another decent jewelry template around anywhere?

Thanks again

Posted

Also, If not is there any Free jewlery templates that work that anyone knows of for any lastest vesion?

Thanks

Posted

@@rak1

 

What release of 2.2 ? Is that MS2, Rc1 or Rc2a ?

 

 

More than likely, your server software has been updated and your site now needs to be updated to continue working.

 

 

 

Chris

 

Hi Chris, If i update the cart will the template still work?

Thanks

Posted

select count(p.products_id) as total from products_description pd, products p left join manufacturers m on
p.manufacturers_id = m.manufacturers_id, products_to_categories p2c left join specials s on p.products_id = s.products_id
where p.products_status = '1' and p.products_id = p2c.products_id and pd.products_id = p2c.products_id and
pd.language_id = '1' and p2c.categories_id = '22'

It sounds like your host has upgraded to MySQL 5, and your old osC needs updating to work with it. MySQL 5 changed some operator precedence (LEFT JOIN is now higher than COMMA). In this particular query, it would become

 

select count(p.products_id) as total from ((products_description pd, products p) left join manufacturers m on
p.manufacturers_id = m.manufacturers_id, products_to_categories p2c) left join specials s on p.products_id = s.products_id
where p.products_status = '1' and p.products_id = p2c.products_id and pd.products_id = p2c.products_id and
pd.language_id = '1' and p2c.categories_id = '22'

Similar changes would be needed in several other places (and obviously, in the .php source) -- do a search on this forum to find discussion on them.

 

Which is php file would this be in so I can change it?

Posted

I no longer have 2.2 MS2, so I can't tell you. There have been many discussions on this, and there even may be a tool somewhere (possibly in the add-ons library) to do most of it for you.

Posted

Thanks MrPhil, Any idea where I could find this tool (the name) , or would newer version of osc 2.? work with a 2.x template?

Posted

This is quite old, but may be enough for you: http://addons.oscommerce.com/info/3727

 

Really, you'd be better off installing 2.3.3 and moving your database content over. You're way behind the times, but if your site is heavily modified you might not want to risk losing features you depend on (if they're not available for 2.3.3). Anyway, it doesn't hurt to install a test version of 2.3.3 and database, and give it a try. There are probably templates now that support 2.3.3 -- be sure to check with the author or supplier. However, with "themeroller" you can easily change a lot of stuff in the 2.3.3 theme to make your site look the way you want, without going through the hassle of installing a "template" (which brings with it all sorts of problems).

Archived

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

×
×
  • Create New...