Answered
Use Query Results as XML?
Hey all, I searched the forums but didn't find anything that
quite fit this particular issue, I'm hoping someone can help me
out.
I am storing a string of text in a database field. It's an XML string (not technically, but it's formatted to BE xml).
I am pulling this from the database in ColdFusion and trying to use it as XML, but having no luck. I can get as far as pulling it and dumping the data and I get this:
<root><Booleanval>on</Booleanval><SuperDooperSelector>1</SuperDooperSelector><ContentBody>words</ContentBody><ContentTitle>AWESOME</ContentTitle><DocumentName>Content 1</DocumentName></root>
It's a test so the values are a bit goofy but it appears as it should nonetheless. I am wondering if there is a way I can parse this into actual XML and access these attributes the same way I normally would in ColdFusion. It won't let me use XMLParse(#myvar#) because it is technically a query.
Does anyone know how I can use this data as XML in ColdFusion?
I am storing a string of text in a database field. It's an XML string (not technically, but it's formatted to BE xml).
I am pulling this from the database in ColdFusion and trying to use it as XML, but having no luck. I can get as far as pulling it and dumping the data and I get this:
<root><Booleanval>on</Booleanval><SuperDooperSelector>1</SuperDooperSelector><ContentBody>words</ContentBody><ContentTitle>AWESOME</ContentTitle><DocumentName>Content 1</DocumentName></root>
It's a test so the values are a bit goofy but it appears as it should nonetheless. I am wondering if there is a way I can parse this into actual XML and access these attributes the same way I normally would in ColdFusion. It won't let me use XMLParse(#myvar#) because it is technically a query.
Does anyone know how I can use this data as XML in ColdFusion?