{"id":1903,"date":"2009-11-10T13:20:24","date_gmt":"2009-11-10T21:20:24","guid":{"rendered":"http:\/\/www.xorph.com\/nfd\/?p=1903"},"modified":"2009-11-10T13:21:34","modified_gmt":"2009-11-10T21:21:34","slug":"searchblort","status":"publish","type":"post","link":"https:\/\/www.xorph.com\/nfd\/2009\/11\/10\/searchblort\/","title":{"rendered":"Searchblort"},"content":{"rendered":"<p>If you are a regular reader of this blog, or indeed any reader of this blog, it is extremely likely that you will have no idea what the following few sentences mean.  Don&#8217;t worry about it.  I&#8217;m just dumping this into Google because I&#8217;ve spent the last four hours clawing at my head trying to solve a problem that is, to the best of my searching ability, undocumented anywhere else.<\/p>\n<p>If you are trying to use the Magento XML-RPC (or SOAP) API to import new product data and keep getting the following error:<\/p>\n<blockquote style=\"font-family: Courier New, Courier, fixed-width;\"><p>SQLSTATE[23000]: Integrity constraint violation: 1452 Cannot add or update a child row: a foreign key constraint fails<\/p><\/blockquote>\n<p>Then it may help you to know that the catalog_product.create function takes an <i>integer<\/i> for its product attribute set ID, and that the key for the &#8216;Default&#8217; set (as of Magento 1.3.2.4) is 4.<\/p>\n<p>(If that doesn&#8217;t work and you recently upgraded, the most popular suggestion is to ensure that all your MySQL tables are InnoDB, but that wasn&#8217;t my problem.)<\/p>\n","protected":false},"excerpt":{"rendered":"<p>If you are a regular reader of this blog, or indeed any reader of this blog, it is extremely likely that you will have no idea what the following few sentences mean. Don&#8217;t worry about it. I&#8217;m just dumping this into Google because I&#8217;ve spent the last four hours clawing at my head trying to [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-1903","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"_links":{"self":[{"href":"https:\/\/www.xorph.com\/nfd\/wp-json\/wp\/v2\/posts\/1903","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.xorph.com\/nfd\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.xorph.com\/nfd\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.xorph.com\/nfd\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.xorph.com\/nfd\/wp-json\/wp\/v2\/comments?post=1903"}],"version-history":[{"count":2,"href":"https:\/\/www.xorph.com\/nfd\/wp-json\/wp\/v2\/posts\/1903\/revisions"}],"predecessor-version":[{"id":1905,"href":"https:\/\/www.xorph.com\/nfd\/wp-json\/wp\/v2\/posts\/1903\/revisions\/1905"}],"wp:attachment":[{"href":"https:\/\/www.xorph.com\/nfd\/wp-json\/wp\/v2\/media?parent=1903"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.xorph.com\/nfd\/wp-json\/wp\/v2\/categories?post=1903"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.xorph.com\/nfd\/wp-json\/wp\/v2\/tags?post=1903"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}