Community Spring Cleaning week is here! Join your fellow Maveryx in digging through your old posts and marking comments on them as solved. Learn more here!
The Product Idea boards have gotten an update to better integrate them within our Product team's idea cycle! However this update does have a few unique behaviors, if you have any questions about them check out our FAQ.

Alteryx Designer Desktop Ideas

Share your Designer Desktop product ideas - we're listening!
Submitting an Idea?

Be sure to review our Idea Submission Guidelines for more information!

Submission Guidelines

XML Capability: Validate XML text

In order to validate if an XML file meets the basic requirements for XML; or if it meets a given XML schema file - it would be very useful to have an XML tool that allows any given XML string to be validated against a specific XSD specification, or against the basic XML spec.

7 Comments
Hiblet
10 - Fireball

Hi @SeanAdams,

 

I have a similar requirement.  I have an XML schema to follow, and have to prepare data to upload.  I need a tool that will take a text field full of XML, and apply a schema to it, and tell me if the XML satisfies the schema rules.  This suggests two input fields (XML and Schema) and maybe two output fields (Valid:[bool; true/false] and Errors:[string; Empty for valid/else relevant error])

 

Is that similar to your requirement?  Have you got any feedback on this yet? 

 

There is some very nice C# library code for this type of task, so knocking out a tool would not be an immense problem.

 

 

SeanAdams
17 - Castor
17 - Castor

@Hiblet:-) you're on exactly my line of thought!

Hiblet
10 - Fireball

Hi @SeanAdams,

 

I have knocked up a C# plug-in tool for XML validation against Schema files.  This is a link to the source code...

 

https://github.com/Hiblet/ContinuumXmlValidator

 

The tool effectively just wraps some C# calls.  All the details are on the GitHub info page.  This is very much a 1.0 version, as I have only just written it, but there is little logic in there that is down to me.  It is mostly just throwing the inputs at the C# functions, and plopping out the results.

 

Are you OK compiling this?  If not, let me know how you would like to receive the compiled DLL/PDB/INI files.  I would be interested to know what you think.

 

Cheers,

 

Steve of Continuum Jersey

SeanAdams
17 - Castor
17 - Castor

Hey Steve ( @Hiblet)

@JoshKushner

 

This really is great - let me take a look over the weekend!   I do have visual studio on my home machine, so let's see how the compile goes (C# projects can be a bit funny sometimes).

 

Copied Josh 'cause he's also an active & keen developer of addins and such - I'm sure he's also gonna be keen to take a look!

 

 

Hiblet
10 - Fireball

No problem, if you find issues or have questions, let me know.  The code has no robustness yet, it will throw if the schemas are invalid or the paths are wrong etc.  In some ways this is good, as the exceptions are visible in the tool feedback in Alteryx, and code is very short and easy to follow (I hope).

JoshKushner
12 - Quasar

My thoughts are to build with the below attributes:

 

Type:

Iterative Macro

 

Inputs:

-XML

-DTD Schema (Optional)

(Will override DTD file referenced in XML code)

-XML Schema (Optional)

(Will override XML Schema file referenced in XML code)

 

Outputs:

-Well Formed & Valid (Boolean)

-Error Message (String)

(if the XML isn't well formed the error message will only cover syntax as no validation could occur)

 

Interface Options:

-DTD Validation (default: yes)

-XML Schema Validation (default: yes)

(If both are unchecked only syntax validation will occur)

AlteryxCommunityTeam
Alteryx Community Team
Alteryx Community Team
Status changed to: Accepting Votes