how do you update a record if doesnt exist? without update taking place trigger wont be called at all. So whatever you're asking for makes no sense to me As a sidenote the above trigger logic is not correct. You cant store values in variables like this from inserted table. It may contain more than 1 record (batch updates) so you should be using table variable instead to store intermediate values.