There is no direct transfer. A foreigner usually continues term of a TRP regularly (once per year or another period of time) while the reason of its issuance is still valid. At the same time a foreigner must have a separate reason for getting a permanent residence permit which is not the similar with TRP reasons. Exception can be a marriage with Ukrainian citizen.