Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 4610936
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 22, 20262026-05-22T01:12:02+00:00 2026-05-22T01:12:02+00:00

I have an application that reads records from the database and exports it out

  • 0

I have an application that reads records from the database and exports it out to an xml file. There is a xsd in place that draws out the schema of the xml file. I am using the xsd proxy classes to then serialize the data to xml file.

This is how I am serializing the data to xml:

XmlSerializer serializer = new XmlSerializer(_report.GetType());
StringBuilder xmlString = new StringBuilder();
StringWriter writer = new StringWriter(xmlString);
serializer.Serialize(writer, _report);
XmlDocument doc = new XmlDocument();
doc.LoadXml(xmlString.ToString());
doc.Save(_outputFile.FullName);

The problem I am having is that in the output file there are missing rows. I went through the debug and found out that the data is being added to the collection of the proxy objects from the database and getting passed to the serializer via the ‘_report’ object.

So to isolated the issue of data or app, I hand coded a few of the missing records into a csv file and imported the data into my app. Those records were now appearing in the xml file. So, now I know that this is a data issue. The app is using informix database as the backend.

What I don’t understand is that why some of the rows from the same table in the informix database be present and other not? I have spent almost 2-3 days on this looking around on the INTERNET without any success. So, I figured its time to turn it up a notch.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-22T01:12:03+00:00Added an answer on May 22, 2026 at 1:12 am

    I had a similar problem 2 day ago.

    try adding

     writer.Flush();
    

    before you call

     xmlString.ToString());
    

    That was the solution that solved my problem.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a Silverlight application that reads its content from an XML file. The
I have a windows forms application that reads and updates an XML file with
I have a VB web application that reads from a CSV file which contains
I have an iPhone application that reads RSS feeds from a YouTube channel. However,
I have an service application that reads a config file containing a list of
I have a Qt application, that reads a special text file, parses it and
Problem in words: For my application, I have a class that reads from a
I have created an application that creates bar graph based on inputs read from
I have an ASP.NET application that does a large database read. It loads up
I have a silverlight 3 application, that fetches some simple data from a ms-sql-server

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.