Jump to content

[SOLVED] Create a product in Prestashop from database


luiskar

Recommended Posts

I'm trying to create a product in prestashop from the database. I have created the most simplest product in Prestashop (only name, price and category) with id_product x and I have looked for in the database what tables have that value in id_product, and create the same row with id_product x+1, but it doesn't show in Prestashop Panel. The tables I write are the following:


ps_category_product ps_layered_price_index ps_product ps_product_lang ps_product_shop ps_specific_price ps_stock_available


Any ideas what am I missing?


 


EDIT: I used the Prestashop API 


Edited by luiskar (see edit history)
Link to comment
Share on other sites

Why directly in database? You should use PHP code to create a new Product object and then save it, you'll make sure everything is properly saved.

I will create a program in c# to create a product taking information from other database. In order to do that I need to know in what tables  I need to create the rows

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...