i want reindex for some products by id i tried following code but it take all indexing to reindex required i am using magento 1.9.2.
$product = Mage::getModel('catalog/product')->load('84494'); // Product Id
$event = Mage::getSingleton('index/indexer')->logEvent( $product,$product->getResource()->getType(), Mage_Index_Model_Event::TYPE_SAVE,true );
Mage::getSingleton('index/indexer')
->getProcessByCode('catalog_url') // Adjust the indexer process code as needed
->setMode(Mage_Index_Model_Process::MODE_REAL_TIME)
->processEvent($event);