Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
XMLToCursor Problem?
Message
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00668798
Message ID:
00668846
Vues:
16
Thank's a lot. It works, the schema was the answer.
About tags, was a cool thing to mark reverserd words :)


>There's no info about element types in the XML created by CursortoXML with parameters you specify. CursortoXML "guesses" the type based on item values. For example, if you add third row into cursor

>INSERT INTO Foo VALUES ('A')

>than field type will be character in NewFoo. You can add inline schema to the XML CursortoXML which includes item type info.

>CursortoXML("Foo","lcXMLData", 1,0,0, "1")

>BTW, it's enough to use just < pre > and < /pre > tags for a code.


>>Hi Everybody, I'm using the functions XMLToCursor() y CursorToXML() to generate a COM Component, but I found a little problem with them:
>>
>>


>> CREATE CURSOR Foo (LeadingZero c(13))
>> INSERT INTO Foo VALUES('0090810490000')
>> INSERT INTO Foo VALUES ('0010200520001')
>>
>> ?VARTYPE(foo.leadingzero)
>> CursortoXML("Foo","lcXMLData")
>>
>> USE IN "Foo"
>>
>> XMLtoCursor(lcXMLData,"NewFoo")
>> ?VARTYPE(newfoo.leadingzero)
>>

>>


>> *** As u can see, the LeadingZero field now is a Numeric type.
>>
>>I can use PADL() to get back the field as a string (keeping the leading zeros), but I think there shoud be another way to get what I want, wich is, no conversion in field types. My question is: What am I doing wrong?,


>Sergey Berezniker
>Visual FoxPro MVP

>A positive attitude may not solve all your problems, but it will annoy enough people to make it worth the effort.

>Herm Albright
Apoya a Visual FoxPro usandolo legalmente
--
¸,ø¤º°`°º¤ø,¸¸,ø¤º°`°º¤ø,¸¸,ø¤º°`°º¤ø,¸¸,ø¤º°`°º
Espartaco Palma Martínez
SysOp PortalFox
http://www.portalfox.com
esparta@portalfox.com
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform