Parent tag ID %1!d! is not among the open tags. FOR XML EXPLICIT requires parent tags to be opened first. Check the ordering ...