Products are not adding to cart after we migrated the drupal 7, unless if you are not logged in user. So after spending some time in reasearch I got this solved.
Unless you are not a logged in to user the products are not adding to cart
- Try checking your “users” table in the database and see if the anonymous user uid is SET to zero, if not then make it zero . If you are not seeing any records without name and details add one new row to table as per the followsFor Drupal 7
INSERT INTO users (name, pass, mail, theme, signature, language, init, timezone) VALUES ('', '', '', '', '', '', '', '');
UPDATE users SET uid = 0 WHERE name = '';
This will insert a new row getting a random UID and then the update query fixes to get the right uid for the user.
- Another solution try to clear the session table