But, in the final minute, Steve Shingler bisected the posts with a 48-metre penalty to see Scarlets to a fifth straight win.
"It is a feeling of relief to snatch that victory and I'm very pleased to get the points," said Pivac.
"We talked about this game going down to the wire last season, so it is satisfying to hang on and to weather the storm and to claw our way back.
"The stats were terrible, something like 33 per cent territory and possession in the first half. We were our own worst enemy.
"At half-time we talked about flushing out that first-half performance, there were too many errors in the conditions. We played at the wrong end of the field and we were behind on the scoreboard.
"We were very happy with the way we started the second half, we came out strongly, we got ourselves back into the game, but again, we got the wrong side of the referee in terms of the discipline and we will have to go away and look at that."
To buy tickets for the GUINNESS PRO12 Grand Final click here. Also follow us on Facebook, join the conversation on Twitter, sign up to our YouTube channel for extensive match highlights and sign up for our newsletter for regular updates on the GUINNESS PRO12.