As mustaccio points out, you need to change your statement terminator. In DBeaver you can do that by:
Right-click on the data source and choose "Edit connection"
In the leftmost frame at the bottom, there is SQL Processing
Check the Datasource checkbox
Now you can alter the statement delimiter