This sounded like a good try. I couldn't get it to work though. So I created
2 separate views in SQL, 1 with group & the other with group & supervisor.
In infopath I created a group field in which I look up values from a
database connection, in which I created a database connection (Connection 1)
to view 1. This field works fine.
In infopath I created a supervisor field in which I look up values from a
database connection, in which I created a database connection (Connection 2)
to view 2. This field works fine & returns supervisors, as is.
Now I want to limit the supervisors shown in the supervisor field according
to the group chosen in the group field. On the supervisor field properties, I
choose the Entries x-path button & choose the Filter Data button. I choose
the group field from the Connection 2 data source, (which also supplies the
supervisor field) is equal to Connection 1 data source group field. I get the
full list
of supervisors, still not filtered.
Now My Entries field looks like this:
/dfs:myFields/dfs:dataFields/d:InfoPathGroupsSupervisor/@Supervisor[../@Group
= xdXDocument:GetDOM "InfoPathGroups")
/dfs:myFields/dfs:dataFields/d:InfoPathGroups/@Group]
According to your descriptions, your filter looks correct. But I might be missing something...
One question I must ask, regardless of how silly it may seem, is whether your Connection2 supervisors have all the same group associated with them, or have different groups associated with them. If all the same group, then what you are experiencing would be expected.

Signature
Greg Collins [InfoPath MVP]
Visit http://www.InfoPathDev.com
This sounded like a good try. I couldn't get it to work though. So I created
2 separate views in SQL, 1 with group & the other with group & supervisor.
In infopath I created a group field in which I look up values from a
database connection, in which I created a database connection (Connection 1)
to view 1. This field works fine.
In infopath I created a supervisor field in which I look up values from a
database connection, in which I created a database connection (Connection 2)
to view 2. This field works fine & returns supervisors, as is.
Now I want to limit the supervisors shown in the supervisor field according
to the group chosen in the group field. On the supervisor field properties, I
choose the Entries x-path button & choose the Filter Data button. I choose
the group field from the Connection 2 data source, (which also supplies the
supervisor field) is equal to Connection 1 data source group field. I get the
full list
of supervisors, still not filtered.
Now My Entries field looks like this:
/dfs:myFields/dfs:dataFields/d:InfoPathGroupsSupervisor/@Supervisor[../@Group
= xdXDocument:GetDOM "InfoPathGroups")
/dfs:myFields/dfs:dataFields/d:InfoPathGroups/@Group]
"Greg Collins [InfoPath MVP]" wrote:
> If the following is what you are using:
>
[quoted text clipped - 4 lines]
>
> You mentioned two data connections... the filter should be comparing @Group against the other data connection. When you select your field (the second @Group), make sure you are selecting it from the second data connection, and not from the same data connection.
JDArsenault - 30 Jan 2006 20:47 GMT
No Sir, they don't. One group may have multiple people listed as supervisors,
but supervisors are not associated with multiple groups.
> According to your descriptions, your filter looks correct. But I might be missing something...
>
[quoted text clipped - 34 lines]
> >
> > You mentioned two data connections... the filter should be comparing @Group against the other data connection. When you select your field (the second @Group), make sure you are selecting it from the second data connection, and not from the same data connection.