Link to home
Start Free TrialLog in
Avatar of lankapala
lankapala

asked on

CTE EROOR MESSAGE -DELETE 2 TABLE RECORDS

hi experts,
I'm getting error message

error
Msg 208, Level 16, State 1, Line 20
Invalid object name 'withdelte'.

;withdelte
as
(
select a.ID
from a
inner join b on a.id=b.id

)

delete from c where ID IN( select ID from withdelte)

delete from d where ID IN( select ID from withdelte)
delete from f where ID IN( select ID from withdelte)

Open in new window


its working first delete but not others,any idea appriciated
ASKER CERTIFIED SOLUTION
Avatar of Mark Wills
Mark Wills
Flag of Australia image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of lankapala
lankapala

ASKER

Thanks
Great
Glad you liked it, and my pleasure in being able to help :)