SAP to pay $400 million for TopTier