Sometimes, it is necessary to retrieve an item given its ID (unique identifier). There is always the SPWeb.GetFile(Guid itemGuid) method, but that does not return an item if that item exists in a sub site. The sub site may be a level down or two or ‘n’ levels down.
Using SPWeb.GetSiteData, it is much easier to query for the Item anywhere from your root web.
Below is the code snippet: