Mieszko Bolesławowic was facilitated by a deal between Ladislaus I of Hungary and Władysław I Herman. Another version, publicized by a Hungarian chronicler, claims that in 1086 Ladislaus I of Hungary invaded the Kingdom of Poland, took control of Cracow, and installed Mieszko as its ruler. Though there is no direct primary source evidence for this, notes in Cracow almanacs strongly suggest that during the years 1086 - 1089 Mieszko was prince of Cracow. However, sometime during this time he accepted over-lordship of his uncle Wladyslaw I Herman, and gave up his hereditary claim to the crown of Poland in exchange for
Mieszko II Lambert to Hungary because during his travel he was stopped by Rus' troops. King Stephen I of Hungary wasn't favorable to accepting him in his country. Without alternatives, Mieszko II went to Bohemia. Duke Oldřich once again imprisoned him. This time the King wasn't counting with the Imperial support. Mieszko II was not only imprisoned but also castrated, which was to be a punishment to Bolesław I the Brave, who blinded Duke Boleslaus III the Red (Oldřich's brother) thirty years before. Mieszko II and his wife never reunited again; according to some sources they were either officially divorced or only separated.