Click here to Skip to main content
15,897,371 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I work with Sedna and I added XML file to it, but any thing I insert it I can't find it in XML file!

This's my code:


string sQuery = "update insert <Tutors TutorID='" + Guid.NewGuid().ToString() + "'>" +
"<FirstName>" + TxtFirstName.Text + "</FirstName>" +
"<LastName>" + TxtLastName.Text + "</LastName>" +
"<NickName>" + TxtNickName.Text + "</NickName>" +
"<Gender>" + sGender + "</Gender>" +
"<BirthDate>" + txtBirthDate.Text + "</BirthDate>" +
"<HomeCity>" + txtHomeCity.Text + "</HomeCity>" +
"<Address>" + TxtAddress.Text + "</Address>" +
"<Mobile>" + TxtMobile.Text + "</Mobile>" +
"<Email>" + TxtEmail.Text + "</Email>" +
"<Class>" + txtClass.Text + "</Class>" +
"<Subject>" + txtSubject.Text + "</Subject> </Tutors>" +
"into document('StudentSystem')/Users";


SednaSession sSession = new SednaSession();

sSession.Start("localhost", SednaSession.DEFAULT_SERVER_PORT, "StudentSystem", "SYSTEM", "MANAGER");

SednaQueryResults sqResult = sSession.Execute(sQuery);

if (sSession.HasTransaction)
{
sSession.CommitTransaction();

lblStatus.Text = "Tutor has been added successfully";
sSession.Close();
pnlManageTutors.Visible = false;
}
else
{
lblStatus.Text = "error!";
sSession.Close();

}
Sedna saves the changes in its Database.
How can I save the changes in the xml file ?

This's XML File:




<StudentsSystem>
<Students StudentId="">
<FirstName></FirstName>
<LastName></LastName>
<Gender></Gender>
<BirthDate></BirthDate>
<HomeCity></HomeCity>
<Address></Address>
<Class></Class>
<Section></Section>
</Students>

<Tutors TutorID="">
<FirstName></FirstName>
<LastName></LastName>
<NickName></NickName>
<Gender></Gender>
<BirthDate></BirthDate>
<HomeCity></HomeCity>
<Address></Address>
<Mobile></Mobile>
<Email></Email>
<Class></Class>
<Subject></Subject>
</Tutors>




<StudentsSystem>
Posted
Updated 18-Jun-15 22:03pm
v6
Comments
CHill60 19-Jun-15 6:41am    
You might get better results using the appropriate support - http://www.sedna.org/#support[^]

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900