Yesterday, I was able to run some script upload and update MMS type columns via script.
Today, the same script unable to get hold of the taxonomy store. I can see the whole tree from any site collection (site setting > term store mgmt). Why then following ps not working? REALLY FRUSTRATED WITH SHAREPOINT LACK OF DOCUMENTATION.
$site = "http://portal.company.com/legal"
$session = get-sptaxonomysession -site $site
if ($session.TermStores.Count > 0)
{
$ts = $session.TermStores[0]
}
else
{
Write-Host "Term Stores not found"
}