problem w/paged attribute sql & WDK 2.2

3 views
Skip to first unread message

Emily Greenfest-Allen

unread,
Oct 3, 2011, 10:37:31 PM10/3/11
to strategies...@googlegroups.com
Hi all-

Sorry to bother you again, but after switching to WDK 2.2 from WDK 2.1
I've been having a problem on the result page; the table in the paged
results pane is no longer being populated. I have made no changes to the
attribute queries since switching. As an example for a question that
has an answer with 11 records, I get the following error in my log:

2011-10-03 22:21:31,434 [http-8103-9] ERROR
org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/gbco-allenem].[GBCO]-
Servlet.service() for servlet GBCO threw exception
org.gusdb.wdk.model.WdkModelException: Paged attribute query
[GeneAttributes.BasicAttributes] returns rows that doesn't match the
paged records. (source_id = 37053260, project_id = GenomicsBC, ).

The error trace then gives me the Paged Attribute SQL and the Paged ID SQL

And then continues

at
org.gusdb.wdk.model.AnswerValue.integrateAttributesQuery(AnswerValue.java:565)
at
org.gusdb.wdk.model.RecordInstance.fillColumnAttributeValues(RecordInstance.java:122)
at
org.gusdb.wdk.model.AttributeValueContainer.getAttributeValue(AttributeValueContainer.java:69)
at
org.gusdb.wdk.model.jspwrap.RecordBean$AttributeValueMap.get(RecordBean.java:298)
at
org.gusdb.wdk.model.jspwrap.RecordBean$AttributeValueMap.get(RecordBean.java:186)
at javax.el.MapELResolver.getValue(MapELResolver.java:51)
at
javax.el.CompositeELResolver.getValue(CompositeELResolver.java:54)
at org.apache.el.parser.AstValue.getValue(AstValue.java:123)
at
org.apache.el.ValueExpressionImpl.getValue(ValueExpressionImpl.java:186)
at
org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate(PageContextImpl.java:935)
at
org.apache.jsp.tag.web.wdk.results_tag._jspx_meth_c_005fset_005f48(results_tag.java:3787)
...

The provided Paged Attribute SQL gives me the following list of records
and attributes when executed in SqlDeveloper:

PROJECT_ID SOURCE_ID GENE_SYMBOL ENTREZ_GENE_ID
DESCRIPTION ORGANISM
GenomicsBC 37053260 STAT5A 6776 signal transducer and
activator of transcription 5A Homo sapiens
GenomicsBC 37053261 STAT5B 6777 signal transducer and
activator of transcription 5B Homo sapiens
GenomicsBC 37119374 Stat5a 20850 signal transducer and
activator of transcription 5A Mus musculus
GenomicsBC 37119375 Stat5b 20851 signal transducer and
activator of transcription 5B Mus musculus
GenomicsBC 37166530 Mstat5ab 100036299 modifier of signal
transducer and activator of transcription 5ab Mus musculus
GenomicsBC 37208546 Stat5a 24918 signal transducer and
activator of transcription 5A Rattus norvegicus
GenomicsBC 37208696 Stat5b 25126 signal transducer and
activator of transcription 5B Rattus norvegicus
GenomicsBC 37246313 STAT5B 397340 signal transducer and
activator of transcription 5B Sus scrofa
GenomicsBC 37246523 STAT5A 397550 signal transducer and
activator of transcription 5A Sus scrofa
GenomicsBC 37263698 stat5.1 369197 signal transducer and
activator of transcription 5.1 Danio rerio
GenomicsBC 37267245 stat5.2 445474 signal transducer and
activator of transcription 5.2 Danio rerio

And the Paged ID SQL results in:

SOURCE_ID WDK_WEIGHT PROJECT_ID ROW_INDEX
37053260 10 GenomicsBC 1
37053261 10 GenomicsBC 2
37119374 10 GenomicsBC 3
37119375 10 GenomicsBC 4
37166530 10 GenomicsBC 5
37208546 10 GenomicsBC 6
37208696 10 GenomicsBC 7
37246313 10 GenomicsBC 8
37246523 10 GenomicsBC 9
37263698 10 GenomicsBC 10
37267245 10 GenomicsBC 11

Needless to say, I am very confused over why I am getting an error,
because both result sets have an identifical list of primary_key ids,
including the record reported as not common between the two in the error
log: (source_id = 37053260, project_id = GenomicsBC).

I've taken a look at AnswerValue.java, but am just not sure why this
error is getting thrown.

If anyone has any ideas why this might be happening, I'd appreciate some
insight.

Thanks

-Emily

Jerric Gao

unread,
Oct 4, 2011, 9:12:44 AM10/4/11
to strategies...@googlegroups.com
Hi Emily,

In order to find out what went wrong, could you please put some logging into
AnswerValue.java? On line#551, put the following:
logger.info("record size: " + pageRecordInstances.size());

And let me know what it prints out. Thanks a lot,

Jerric

Emily Greenfest-Allen

unread,
Oct 4, 2011, 9:37:20 AM10/4/11
to strategies...@googlegroups.com
For this particular case, it prints:

record size: 11

-Emily

Jerric Gao

unread,
Oct 5, 2011, 11:10:35 AM10/5/11
to strategies...@googlegroups.com
Hi Emily,

I think the problem might reside in the equals() function in the
PrimaryKeyAttributeValue.java. Could you please put some logs in that function
and print out where the function returns false?

Thanks,

Emily Greenfest-Allen

unread,
Oct 7, 2011, 10:49:20 AM10/7/11
to strategies...@googlegroups.com
Jerric-

Sorry for taking so long to get back to you.

I added the debug statements to the code as you suggested; and verified
that the primary key values being compared appeared to be the same, but
the code was still flagging them as being unequal. This suggested to me
that the problem was with the typing of the values and so I went back to
our model. We have a lot of legacy queries, where for some reason the
primary keys were wrapped from numeric to varchar. This was one of
them. With the older verison of the WDK code I guess it wasn't a
problem to have the type mismatch, but now it is.

Fixing the query on our end solved this issue.

Thanks for your help,

Emily

Reply all
Reply to author
Forward
0 new messages