This is Interesting: Free Magazines for Graphics designers and webmasters  


Home > Archive > Microsoft XML > May 2004 > ADO - adPersistXML - Null Fields





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author ADO - adPersistXML - Null Fields
Kiran Math

2004-05-20, 7:34 pm

I am using VB-ADO to create a XML file from a SqlServer database.

If the value of a field in a record is null, the attribute on the z:row is
not created.

I wanted the null field to be shown in the xml.
How do I get it.

Thanks
Kiran Math



VBDude

2004-05-22, 4:28 am

Null signals the fact that an object is not set. Passing real objects in XML
is
not possible.

In VB6 you test for a non existing object using:
if xxx is Nothing then ...

In XML your should do the same:
if dom.selectsinglenode(xxx) is Nothing then ....

Hope this helps


"Kiran Math" <kiranmath@hotmail.com> wrote in message
news:O5g3vsePEHA.3348@TK2MSFTNGP09.phx.gbl...
> I am using VB-ADO to create a XML file from a SqlServer database.
>
> If the value of a field in a record is null, the attribute on the z:row is
> not created.
>
> I wanted the null field to be shown in the xml.
> How do I get it.
>
> Thanks
> Kiran Math
>
>
>



Kiran Math

2004-05-24, 12:15 pm

VBdude,
I added the missing column during XML transformation.
Thank you for help.
Kiran Math


Sponsored Links


Copyright 2003 - 2008 forum4designers.com  Software forum  Computer Hardware reviews