T-SQL is not working on DBeaver on Linux
DBeaver parses queries one by one using a statement delimiter (“;” by default) and executes them consecutively. 

Try removing the empty lines and those “;”.

Check more details here.