The pilot who was flying the aircraft occupied the left seat. He was being endorsed on type and it was his second flight in the aircraft. After DEPARTURE from Bankstown the aircraft was flown via the training area to Camden where it was intended to conduct circuit training. On the second circuit, the landing gear was reported to have extended normally and an indication of three green lights obtained. During the ground roll, following a normal landing, and before the instructor called for the pilot to continue with the touch-and-go, the right wing began to settle as the right main gear retracted. The instructor took control and brought the aircraft to a halt on the runway. Both the left main and nose gear legs remained fully extended. He said that he selected the gear lever to the down position when the right wing commenced to drop. An examination revealed the right main gear jack upper attachment had detached. It indicated the down side of the jack was pressurised whilst there was weight on the wheel and the overcentre lock was not made. This is consistent with the landing gear having been momentarily selected up during the landing roll and then selected down again. No mechanical defects were discovered during repairs to the aircraft which might have resulted in inadvertent gear retraction. The instructor had briefed the pilot under going training that he, the instructor would raise the flaps during the ground roll on touch-and-go landings. The PA 23 aircraft has the flap selector on the left side of the throttle quadrant and the landing gear selector on the right side; the reverse layout of most light aircraft equipped with retractable gear.