We examine a mixed type equation with the Lavrent ev-Bitsadze operator and an unknown right-hand side in a rectangle and study a nonlocal boundary value problem in which the values of the stream function on the lateral sides of the rectangle are equal. The solution is given as a sum of a biorthogonal series. The uniqueness criterion and stability of solutions with respect to the boundary data are established.