The well-known Cameron–Martin formula allows us to calculate the mathematical expectation where Ws is a Wiener process. This paper extends this result to the case of piecewise continuous martingales. As a particular case the mathematical expectations of a functional of generalized Ornstein– Uhlenbeck processes and pure jump processes are calculated.