public static function SocialContent::getLastImportedExternalID in Social Content 7.2
Utility static function to get last imported external id.
Parameters
array $instance_id: The id of the instance to restrict the search to.
Return value
mixed Last external id.
1 call to SocialContent::getLastImportedExternalID()
- SocialContent::import in ./
social_content.class.inc - Do the import.
File
- ./
social_content.class.inc, line 1007 - Social Content class.
Class
- SocialContent
- TODO: Table names should be a property for ease of change Separate this class into smaller classes.
Code
public static function getLastImportedExternalID($instance_id) {
return db_select('social_content_history', 'history')
->fields('history', array(
'external_id',
))
->condition('instance', $instance_id)
->orderBy('stamp', 'DESC')
->range(0, 1)
->execute()
->fetchField();
}