added lend query