Skip to content
Advertisement

On delete Error: SQL Error: ORA-00933: SQL command not properly ended

I’m trying to delete a student record from the database using the below query. But I face this error.

Error report – SQL Error: ORA-00933: SQL command not properly ended 00933. 00000 – “SQL command not properly ended”

Advertisement

Answer

Give this a shot to delete student record for which there exists an enrollment.

If you are interested in deleting a student record from both student table and enrollment table, run 2 queries:

If you want to automatically delete enrollment record when you delete a student, you may want to look into triggers.

User contributions licensed under: CC BY-SA
3 People found this is helpful
Advertisement