dataset WriteXML question

G

Guest

I'm running SQLXMLBulkLoad from a vb.NET app supplying both and xml file and
a schema (xsd) file. I'm moving data from a table in one database to a
table in another database and expect the data in the destination table to be
exactly as the source table. I want to preserve Nulls, Empty
strings AND Blank Spaces.

The data is getting loaded into the table except for
columns that contain spaces or empty strings. These columns are being
populated with NULLS.

The XML input was created from a dataset (WriteXml) . I expected that
column tags that are missing from the xml file would be loaded as nulls but
columns such as <tag1></tag2> would load as an empty string.

Is there anyway to instruct a dataset or WriteXML to use CDATA sections for
all the character type fields so that empty strings and Blanks are preserved
or is there another way to do this?
 
V

Val Mazur \(MVP\)

Hi,

No, you need to specify an empty tag in XML or define in a schema that
column has to have value (mandatory field).
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top