Trying to get this MySQL Trigger working
The way of declaring VARCHAR is correct 
The error is that you have to specify the table, and the action. i.e. ON worker1 BEFORE {INSERT|UPDATE|DELETE}
"if inserting or updating Worker1 then" I think you need two triggers if you want the action to be performed BEFORE INERT and BEFORE UPDATE
Change the delimiter, and end your trigger with it. 
If the provided code is not meant to be pseudopod, I recommend reading about MySQL triggers before start coding them.