You are here

function amazon_media_amazon_item_delete in Amazon Product Advertisement API 6

Same name and namespace in other branches
  1. 7.2 amazon_media/amazon_media.module \amazon_media_amazon_item_delete()
  2. 7 amazon_media/amazon_media.module \amazon_media_amazon_item_delete()

File

amazon_media/amazon_media.module, line 119

Code

function amazon_media_amazon_item_delete($asin) {

  // This is pretty inefficient; we're going to thrash these tables
  // every time a product gets deleted or updated. We'll solve it later.
  db_query("DELETE FROM {amazon_book} WHERE asin = '%s'", $asin);
  db_query("DELETE FROM {amazon_dvd} WHERE asin = '%s'", $asin);
  db_query("DELETE FROM {amazon_music} WHERE asin = '%s'", $asin);
  db_query("DELETE FROM {amazon_software} WHERE asin = '%s'", $asin);
}