How to read this XML Structure

Welcome Forums General PowerShell Q&A How to read this XML Structure

This topic contains 2 replies, has 3 voices, and was last updated by

 
Senior Moderator
1 month ago.

  • Author
    Posts
  • #171133

    Participant
    Topics: 1
    Replies: 0
    Points: 14
    Rank: Member

    Hi,

    i got an XML File which have this Structure:




    some-string
    Mail0
    CN=mail0,OU=1,OU=2,DC=dom,tld=de
    mail0@dom.tld
    mail0@dom.tld
    UserMailbox
    SharedMailbox




    mail1@dom.tld
    mail2@dom.tld




    If there are no value under e.g. SendAsPermissions the node looks like:


    This Schema continue again and again in a single file on over 71.000 Lines at all. MS Excel didnt read this Format well, so i cant use it as it is. My aim is to convert it to a .csv or better xml to create a readable Excelformat. My first idea was to create a new .csv file, read line by line, evaluate each node and append it to the file. But i think there are some better options and thats why i ask you for advise.

    Thx

    TasteIT

  • #171235

    Participant
    Topics: 1
    Replies: 17
    Points: 59
    Rank: Member

    Your post didn't display too well.  Could you create a gist and paste that url in or at least put the xml between pre tags ?  I can't see any way we can help without clear information.

    What are you using to generate the xml output?  Could you give us an idea what the commandline you used is to see if we can obtain similar data?

  • #171253

    Senior Moderator
    Topics: 8
    Replies: 1041
    Points: 3,438
    Helping Hand
    Rank: Community Hero

    @tasteit If you have an XML, posting it in github.gist.com and pasting the link here will be helpful.

You must be logged in to reply to this topic.