One to many Filter on Sharepoint list - InfoPath Dev
in

InfoPath Dev

One to many Filter on Sharepoint list

Last post 02-09-2011 02:16 PM by Hilary Stoupa. 3 replies.
Page 1 of 1 (4 items)
Sort Posts: Previous Next
  • 02-09-2011 09:15 AM

    One to many Filter on Sharepoint list

    Hi,

     Okay I am following a qRules procedure and am a little confused.....  The procedure is called "Filter A Sharepoint List on the Server". 

     Scenario:

    I have a Sharepoint list with two columns. 

    Column 1 = Events

    Column 2 = Crop

    There are only 4 crops (Cotton, Corn, Soybean,....)  

    Cotton
    Cotton
    Cotton
    Cotton
    Cotton
    Cotton
    Cotton
    Cotton
    Cotton
    Cotton
    Cotton
    Cotton
    Cotton
    Cotton
    Corn
    Corn
    Corn
    Corn
    Corn
    Corn
    Corn
    Corn
    Corn
    Corn
    Corn
    Soybean
    Soybean
    Soybean
    Soybean
    Soybean
    Soybean
    Soybean
    Soybean
    Corn
    Soybean
    Soybean
    Soybean
    Soybean

    So I created a drop down field on my form called "Crop".  Following the procedure, my dropdown field would have multiple crops.  I setup the list so that each event could be identifiable with the crop.  I dont see know other way to do this.   My question is, is this the best approach?  Because in turn, if i chose, for example one of multiple "cottons", I am selecting basically one entry versus my desired multiple events per crop choice.  Seems this filter procedure is for one to one????

     Chris

  • 02-09-2011 01:35 PM In reply to

    Re: One to many Filter on Sharepoint list

    as i have been thinking about this all day, it think what i am asking is for:

     

    1.) a drop down field called "Crop" with (Cotton, Corn, Soybean, Canola)

    2.) Sharepoint list with Crops in them (multiple entries per Cotton, Corn, Soybean, Canola)

     

    Dropdown field "Crop" = Sharepoint list column "Crop"  THEN populate crop related "Event" only in Repeated Field.........

  • 02-09-2011 02:05 PM In reply to

    Re: One to many Filter on Sharepoint list

    Hi-

    I'm not sure that I understand the question. The scenario you're describing is precisely what the command was created for. The example on page 7 of the tutorial shows what you describe: the user makes a selection in the first dropdown and then options are loaded into the second dropdown. Of course, you wouldn't need to display the repeating data as a dropdown.

    Are you stuck in a specific step of the tutorial? Let us know and we'll help. Thanks.

    Ernesto Machado
    Qdabra® Software/ InfoPathDev.com
    The InfoPath Experts – Streamline data gathering to turn process into knowledge.™


  • 02-09-2011 02:16 PM In reply to

    Re: One to many Filter on Sharepoint list

    Wouldn't you set your Crop dropdown to only display unique items?

    Then, you'd use FilterOwssvr qRules command to return only the Events that are associated with the selected crop, binding your Events drop down to the data source you are applying FilterOwssvr to?

    So, you'd create a regular SharePoint list connection to your list, and only select the "Crop" column. Use that data source for your Crop drop down.

    Then, on the field bound to the Crop drop down, you'd set a rule. That rule would run the qRules FilterOwssvr command, setting the filter field to your Crop column in your ShP list, and the value to the selected value from your field bound to the Crop drop down.

    Hilary Stoupa

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