I have a method that is taking vales directly from the database, building a string of xml and then writing the xml to a file.
This is fine until I get special characters eg "'", "<", "&" etc.
Does anyone know of something in Sql Server that would allow me to encode the values as i select them; for example;
select encode(service_status) from myTable
Thanks.