The Shulhan Aruch (Orah Haim 202:12) rules that the blessing over a fruit which is customarily eaten both raw and cooked, such as an apple, is “Bore Peri Ha’Etz” in both states. If the fruit is normally eaten only when cooked, the Shulhan Aruch continues, one would recite “Shehakol” if eaten raw, and “Ha’Etz” is eaten cooked. Finally, if the fruit is normally only eaten raw, such as grapes, its blessing would be relegated to “Bore Peri Ha’Adama” in the cooked state.
This Halacha is pertinent to the practice of cooking the Etrogim used during Sukkot in order to make jam. Rabbi Shalom Messas (Shemesh Umagen, vol. III, § 89:5) and Rabbi Baruch Toledano (Kitzur Shulhan Aruch, § 199:24) both rule that, despite a disagreement among rabbis, the Moroccan custom is to recite “Bore Peri Ha’Etz” over Etrog jam. Although the Etrog is broken down and mixed with sugar, the resultant jam contains noticeable pieces of Etrog which retain their form, and therefore would retain its original blessing. Even if there are no visible pieces, the blessing is still “Ha’Etz” as this is the conventional way of consuming an Etrog.
Additionally, the Shulhan Aruch (Orah Haim 205:2) writes that the blessing over water in which vegetables are cooked is the same blessing as the vegetable. For example, one who cooks lentils to make soup but wishes to only drink the broth, would recite “Bore Peri Ha’Adama”. Even though a previous DailyHalacha discussed the blessing changing to “Shehakol” when a vegetable’s form is altered, in this case, the water retains the taste of the vegetable and is thus an extension of the vegetable. This stands in contrast to fruit which are expressly squeezed for their juice, such as apple juice, in which case the blessing would be “Shehakol”. The exceptions to this latter rule are grapes and olives, whose juices the Torah attributes the special names “Tirosh” and “Yitzhar”, respectively. As such, the blessing over grape juice (and wine) is not “Shehakol”, but is rather elevated to “Bore Peri HaGefen”. Similarly, olive oil, if rendered palatable, would not be relegated to “Shehakol”, but would remain “Bore Peri Ha’Etz”.
One area of doubt is orange juice. On one hand, it is primarily consumed as a drink and the juice is certainly an extension of the fruit. Therefore, an argument could be made to recite “Ha’Etz”. On the other hand, oranges do not have the special status of Tirosh or Yitzhar, and therefore its juice should be similar to apples, etc. and have a blessing of “Shehakol”. Practically speaking, one should recite “Shehakol” on orange juice as there is doubt to its blessing. Interestingly, one practical implication of this is if one were to consume an apple, followed by some orange juice. Some opinions posit that, even though on its own orange juice is “Shehakol”, it could be exempted by the “Ha’Etz” that was recited on the apple that preceded it. In such a case, however, it is preferable to first recite “Shehakol” and drink the orange juice, and to make a separate blessing of “Ha’Etz” over the apple.
Summary: The blessing over Etrog jam is “Ha’Etz”. The blessing over vegetable broth is “Ha’Adama”. The blessing over orange juice is “Shehakol”. Please read above for the Halachic details.