From: Scott W. <sco...@oc...> - 2007-06-25 06:52:44
|
Hi, Based on tips from Wolfgang to avoid corrupting my database I am trying = to avoid creating a temporary fragment. In the past I had code in like below let $data :=3D request:get-data() let $id :=3D $data/Quote/@id let $temp :=3D xmldb:store("/db/quote", concat($id, '.xml') , $data) unfortunately the third line ($data/Quote/@id) causes a temporary = fragment to be created. I have avoided this by using the following code let $data :=3D request:get-data() let $id :=3D request:get-parameter("id", "") =20 let $temp :=3D xmldb:store("/db/quote", concat($id, '.xml') , $data) Unfortunately the No matter what is in $data will be saved in the = document. I need to ensure that the document's root element is at the least a = "Quote" element. Does anyone know how I can do this? I need to avoid a temporary fragment = at all costs as this is leading to corruptions of my database. Your help is much appreciated. Regards =A0 =A0 Scott Warren Ocom Software ... Exceeding Quality..... |