IVAN.Z 2 Опубликовано 13 декабря, 2019 Жалоба Share Опубликовано 13 декабря, 2019 Добрый день, хотелось бы узнать какой нужен запрос для заноса товара в базу данных с помощью sql команды, в парсере datacool есть способ импортировать в базу данных спарсенный товар через sql запрос на joomla он выглядел так ( для материала ) а как сформировать для shopos? INSERT INTO `jos_assets` SET `parent_id` = '55', `lft` = 21, `rgt` = 22, `level` = 3, `name` = 'com_content.article.1'+FLOOR(RAND()*(200000)), `title` = 'title' , `rules` = '{"core.admin":{"7":1},"core.manage":{"6":1},"core.create":{"3":1},"core.delete":[],"core.edit":{"4":1},"core.edit.state":{"5":1},"core.edit.own":[]}'; INSERT INTO `jos_content` (`asset_id`, `title`, `alias`, `introtext`, `fulltext`, `state`, `catid`, `created`, `created_by`, `created_by_alias`, `modified`, `modified_by`, `checked_out`, `checked_out_time`, `publish_up`, `publish_down`, `images`, `urls`, `attribs`, `version`, `ordering`, `metakey`, `metadesc`, `access`, `hits`, `metadata`, `featured`, `language`, `xreference`) VALUES ( last_insert_id(), '%title%' , '', '%introtext%' , '', 1, 8, DATE_ADD(NOW(), INTERVAL -4 HOUR), 62, '', DATE_ADD(NOW(), INTERVAL -4 HOUR), 62, 62, DATE_ADD(NOW(), INTERVAL -4 HOUR), DATE_ADD(NOW(), INTERVAL -4 HOUR), '0000-00-00 00:00:00', '{"image_intro":"","float_intro":"","image_intro_alt":"","image_intro_caption":"","image_fulltext":"","float_fulltext":"","image_fulltext_alt":"","image_fulltext_caption":""}', '{"urla":false,"urlatext":"","targeta":"","urlb":false,"urlbtext":"","targetb":"","urlc":false,"urlctext":"","targetc":""}', '{"show_title":"","link_titles":"","show_tags":"","show_intro":"","info_block_position":"","show_category":"","link_category":"","show_parent_category":"","link_parent_category":"","show_author":"","link_author":"","show_create_date":"","show_modify_date":"","show_publish_date":"","show_item_navigation":"","show_icons":"","show_print_icon":"","show_email_icon":"","show_vote":"","show_hits":"","show_noauth":"","urls_position":"","alternative_readmore":"","article_layout":"","show_publishing_options":"","show_article_options":"","show_urls_images_backend":"","show_urls_images_frontend":""}', 2, 0, '', '', 1, 1, '{"robots":"","author":"","rights":"","xreference":""}', 0, '*', '' ) Ссылка на сообщение Поделиться на другие сайты
support 447 Опубликовано 13 декабря, 2019 Жалоба Share Опубликовано 13 декабря, 2019 1 час назад, ZM сказал: Добрый день, хотелось бы узнать какой нужен запрос для заноса товара в базу данных с помощью sql команды, в парсере datacool есть способ импортировать в базу данных спарсенный товар через sql запрос на joomla он выглядел так ( для материала ) а как сформировать для shopos? INSERT INTO `jos_assets` SET `parent_id` = '55', `lft` = 21, `rgt` = 22, `level` = 3, `name` = 'com_content.article.1'+FLOOR(RAND()*(200000)), `title` = 'title' , `rules` = '{"core.admin":{"7":1},"core.manage":{"6":1},"core.create":{"3":1},"core.delete":[],"core.edit":{"4":1},"core.edit.state":{"5":1},"core.edit.own":[]}'; INSERT INTO `jos_content` (`asset_id`, `title`, `alias`, `introtext`, `fulltext`, `state`, `catid`, `created`, `created_by`, `created_by_alias`, `modified`, `modified_by`, `checked_out`, `checked_out_time`, `publish_up`, `publish_down`, `images`, `urls`, `attribs`, `version`, `ordering`, `metakey`, `metadesc`, `access`, `hits`, `metadata`, `featured`, `language`, `xreference`) VALUES ( last_insert_id(), '%title%' , '', '%introtext%' , '', 1, 8, DATE_ADD(NOW(), INTERVAL -4 HOUR), 62, '', DATE_ADD(NOW(), INTERVAL -4 HOUR), 62, 62, DATE_ADD(NOW(), INTERVAL -4 HOUR), DATE_ADD(NOW(), INTERVAL -4 HOUR), '0000-00-00 00:00:00', '{"image_intro":"","float_intro":"","image_intro_alt":"","image_intro_caption":"","image_fulltext":"","float_fulltext":"","image_fulltext_alt":"","image_fulltext_caption":""}', '{"urla":false,"urlatext":"","targeta":"","urlb":false,"urlbtext":"","targetb":"","urlc":false,"urlctext":"","targetc":""}', '{"show_title":"","link_titles":"","show_tags":"","show_intro":"","info_block_position":"","show_category":"","link_category":"","show_parent_category":"","link_parent_category":"","show_author":"","link_author":"","show_create_date":"","show_modify_date":"","show_publish_date":"","show_item_navigation":"","show_icons":"","show_print_icon":"","show_email_icon":"","show_vote":"","show_hits":"","show_noauth":"","urls_position":"","alternative_readmore":"","article_layout":"","show_publishing_options":"","show_article_options":"","show_urls_images_backend":"","show_urls_images_frontend":""}', 2, 0, '', '', 1, 1, '{"robots":"","author":"","rights":"","xreference":""}', 0, '*', '' ) Смотрите структуру таблиц products , products_dscription в phpMyAdmin и для них пишите запрос. т.е. insert into products ... Ссылка на сообщение Поделиться на другие сайты
Рекомендуемые сообщения