Filtering GetGroupsForUser - InfoPath Dev
in

InfoPath Dev

Filtering GetGroupsForUser

Last post 10-03-2011 01:05 PM by mennis. 3 replies.
Page 1 of 1 (4 items)
Sort Posts: Previous Next
  • 10-03-2011 08:51 AM

    • mennis
    • Not Ranked
    • Joined on 06-06-2011
    • Posts 3

    Filtering GetGroupsForUser

    Hi --

    I'm using the GetGroupsForUser command.  I'd like to copy over that data (filtered) to the main data source. 

    Since it does not appear that I can filter the actual GetGroupsForUser information (please let me know if I'm wrong on this) I tried both CopyTable and Insert.

    CopyTable brings over all the information.  I tried using the Delete command afterwards, but coudn't get that to work selectively.

    I got stuck using the Insert command - I was able to create the requisite number of rows, but then since there is no ID field in the GetGroupsForUser information I could not loop through the data (I've was using the "Copy SQL Values to Infopath . . . " as my model before, but need to have an ID field in the source table).

    Thanks for any ideas.

    -- Maura

  • 10-03-2011 10:56 AM In reply to

    Re: Filtering GetGroupsForUser

    Hi - I'd copy using CopyTable, then use Delete - what does this mean:

    mennis:
    I tried using the Delete command afterwards, but coudn't get that to work selectively.

    You added an XPath filter to your Delete command and it failed? What was the error message? What did your command look like?

    Hilary Stoupa

  • 10-03-2011 01:02 PM In reply to

    • mennis
    • Not Ranked
    • Joined on 06-06-2011
    • Posts 3

    Re: Filtering GetGroupsForUser

    Since you indicated this should work, I kept at it and I'm closer.  Using the following, I can delete the Value field of the records I want to delete:

     Delete /xpath=my:GridInfo/my:InitiatorInfo/my:InitiatorADGroups[not(starts-with(@my:Value, concat("SP-", ../my:ServicePrefix, "-Grid")))]/@my:Value

    Now I just need to remove the whole row instead of the the field.

    Thanks for your help!

  • 10-03-2011 01:05 PM In reply to

    • mennis
    • Not Ranked
    • Joined on 06-06-2011
    • Posts 3

    Re: Filtering GetGroupsForUser

    I finally got the desired result by leaving off the trailing @value. 

Page 1 of 1 (4 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.