Unsure. I think that class handles a single query with a single parameter. That's what the method PartialWhereClause looks like to me.
Also I believe the class only handles a single row response which might not work for him if he's doing a union. Minimally he'd have to use MultiRowJdbcPersonAttributeDao, but that assumes the table data has attribute names and values in the table; see docs for MultiRowJdbcPersonAttributeDao. What is a,b,c,d in this case? Would NamedParameterJdbcPersonAttributeDao work for him? James Wennmacher - Unicon 480.558.2420 On 08/19/2015 01:42 PM, Misagh Moayyed wrote: > > Fellow developers, > > Those of you familiar enough with person directory: could you please > see the post below and tell me if this is a configuration issue, or > the DAO isn’t actually taking into account all parameters? > > Thanks, > > *From:*Manfredo Hopp [mailto:[email protected]] > *Sent:* Wednesday, August 19, 2015 11:26 AM > *To:* [email protected] > *Subject:* [cas-user] Resolving attirbutes dao results in "no value > specified for parameter 2" > > Hello I am using singleRowJdbcPersonAttributeDao to resolve principal > attributes defined as: > > singleRowJdbcPersonAttributeDao > > class="org.jasig.services.persondir.support.jdbc.SingleRowJdbcPersonAttributeDao"> > > <constructor-arg index="0" ref="dataSourceA" /> > > <constructor-arg index="1" > > value="(SELECT a, b, c , d > > FROM u WHERE {0} > > UNION > > (SELECT a, b ,c d > > FROM r WHERE {0})" /> > > <property name="queryAttributeMapping"> > > <map> > > <entry key="username" value="id" /> > > </map> > > </property> > > And get SQLException->No value specified for parameter 2 > > NO replacement for second {0}, so I am not able to use this query. > > Is there any reason for the behaviour of this implementation? > > Regards Manfredo > > > -- > You are currently subscribed [email protected] > <mailto:[email protected]> as:[email protected] > <mailto:[email protected]> > To unsubscribe, change settings or access archives, > seehttp://www.ja-sig.org/wiki/display/JSG/cas-user > -- > > You are currently subscribed to [email protected] as: > [email protected] > To unsubscribe, change settings or access archives, see > http://www.ja-sig.org/wiki/display/JSG/uportal-dev -- You are currently subscribed to [email protected] as: [email protected] To unsubscribe, change settings or access archives, see http://www.ja-sig.org/wiki/display/JSG/uportal-dev
