for zjd logic