select
din, driv_height, city, Driver_Addres_Posta_Code, DRIV_GENDER_ID
from
driv_testing
if DRIV_GENDER_ID IN ('M', 'F')
begin
insert into driv_success
end
else DRIV_GENDER_ID not in ('M', 'F')
begin
insert into error_logs (error_description)
values ('Gender fails')
end
I have one source table driv_testing
and sink table driv_success
and error_logs
table to log bad records.
If DRIV_GENDER_ID IN ('M', 'F')
then I want to insert into driv_success
otherwise insert into error_logs
table..
But I am getting error for the above query.