我在 SQL Server 中有两个表,Appointment并且AppointmentDetails.
Appointment表有两列AppId和CusId。
AppointmentDetail表有AppId, ApDay, Intime, OutTime, EmpId.
Appointment表AppId作为它的主键,它被设置为自动递增。
AppointmentDetails表有主键(AppId, ApDay)。
当我将数据插入表时,我的问题是如何获取Appointment表的主键并将其插入到表中???AppointmentDetailsAppointment