The problem is that the regex in the database already uses XML escaping, and when copying it into the XML file, you have added another layer of escaping, so '
has become '
.
There are two ways of escaping special characters, you can turn &
into &
as done here, or you can wrap it in CDATA. In this case you don't want to do either, because it is already escaped.
I'm not familiar with link-to-xml so I don't know how to do this correctly in that environment.