我有一个像这样的基于sql的viewObject(比这里更多的列)和LOV,我想查询
SELECT
SAS_MARKS_NEW_V.MARK MARK,
SAS_MARKS_NEW_V.PASS PASS,
SAS_MARKS_NEW_V.SEAS_ID SEAS_ID,
SAS_MARKS_NEW_V.STUD_ID STUD_ID,
FROM
SAS_MARKS_NEW_V
以_ID结尾的字段未显示在UI中,并且附有值列表。视图访问器是精心设计的(我不使用共享的AM实例,但设置RowLevelBinds为false,SharedVOInstance为true)。到了我丢弃的页面:用表查询。这个页面加载得很好(只有很少的selectOneChoice和ComboWithLov),但是当我从lov中选择一些值并点击搜索时,需要一段时间。使用最好的级别的记录器我看到搜索(即使没有找到行),执行多个LOV选择查询:
<ADFLogger> <begin> Get LOV list
<ADFLogger> <begin> Get LOV list
<ADFLogger> <addContextData> Get LOV list
<ADFLogger> <addContextData> Get LOV list
<ADFLogger> <end> Get LOV list
<ADFLogger> <end> Get LOV list
<ViewRowSetImpl> <execute> [2416] _LOCAL_VIEW_USAGE_internal_vcival_def_GrouTypeLOVVO1 ViewRowSetImpl.execute caused params to be "un"changed
<ViewRowSetImpl> <execute> [2416] _LOCAL_VIEW_USAGE_internal_vcival_def_GrouTypeLOVVO1 ViewRowSetImpl.execute caused params to be "un"changed
<ViewRowSetImpl> <initQueryCollection> [2417] Carrying over CappedRowCount:-1for ViewRowSet:_LOCAL_VIEW_USAGE_internal_vcival_def_GrouTypeLOVVO1
<ViewRowSetImpl> <initQueryCollection> [2417] Carrying over CappedRowCount:-1for ViewRowSet:_LOCAL_VIEW_USAGE_internal_vcival_def_GrouTypeLOVVO1
<QueryCollection> <createColumnList> [2418] Column count: 3
<QueryCollection> <createColumnList> [2418] Column count: 3
<ViewRowSetImpl> <execute> [2419] executeQueryForCollection ViewObject:_LOCAL_VIEW_USAGE_internal_vcival_def_GrouTypeLOVVO1, RowSet:_LOCAL_VIEW_USAGE_internal_vcival_def_GrouTypeLOVVO1
<ViewRowSetImpl> <execute> [2419] executeQueryForCollection ViewObject:_LOCAL_VIEW_USAGE_internal_vcival_def_GrouTypeLOVVO1, RowSet:_LOCAL_VIEW_USAGE_internal_vcival_def_GrouTypeLOVVO1
<ADFLogger> <begin> Execute query
<ADFLogger> <begin> Execute query
<ViewObjectImpl> <buildQuery> [2420] _LOCAL_VIEW_USAGE_internal_vcival_def_GrouTypeLOVVO1>#q old SQLStmtBufLen: 165, actual=135, storing=165
<ViewObjectImpl> <buildQuery> [2420] _LOCAL_VIEW_USAGE_internal_vcival_def_GrouTypeLOVVO1>#q old SQLStmtBufLen: 165, actual=135, storing=165
<ViewObjectImpl> <buildQuery> [2421] SELECT
GROU_TYPE_V.CLVA_ID CLVA_ID,
GROU_TYPE_V.CODE CODE,
GROU_TYPE_V.TITLE TITLE
FROM
CL_GROU_TYPE_V GROU_TYPE_V
<ViewObjectImpl> <buildQuery> [2421] SELECT
GROU_TYPE_V.CLVA_ID CLVA_ID,
GROU_TYPE_V.CODE CODE,
GROU_TYPE_V.TITLE TITLE
FROM
CL_GROU_TYPE_V GROU_TYPE_V
<ViewObjectImpl> <getStatementFromCache> [2422] ViewObject: [com.innodea.sas.model.lovs.views.GrouTypeLOVVO]MarksAM._LOCAL_VIEW_USAGE_internal_vcival_def_GrouTypeLOVVO1 Reusing defined prepared Statement
<ViewObjectImpl> <getStatementFromCache> [2422] ViewObject: [com.innodea.sas.model.lovs.views.GrouTypeLOVVO]MarksAM._LOCAL_VIEW_USAGE_internal_vcival_def_GrouTypeLOVVO1 Reusing defined prepared Statement
<ViewObjectImpl> <bindParametersForCollection> [2423] Bind params for ViewObject: [com.innodea.sas.model.lovs.views.GrouTypeLOVVO]MarksAM._LOCAL_VIEW_USAGE_internal_vcival_def_GrouTypeLOVVO1
<ViewObjectImpl> <bindParametersForCollection> [2423] Bind params for ViewObject: [com.innodea.sas.model.lovs.views.GrouTypeLOVVO]MarksAM._LOCAL_VIEW_USAGE_internal_vcival_def_GrouTypeLOVVO1
<ADFLogger> <addContextData> Execute query
<ADFLogger> <addContextData> Execute query
<ADFLogger> <addContextData> Execute query
<ADFLogger> <addContextData> Execute query
<ADFLogger> <end> Execute query
<ADFLogger> <end> Execute query
这是否意味着对于每个返回的行都会发出一个lov sql来设置viewAccessors? 我可以以某种方式加快查询速度吗? 具有lov值的DoviewObjects无法在默认af:query中有效使用?
答案 0 :(得分:0)
我正在使用来自应用程序模块外部的视图对象,它们未包含在共享应用程序模块中。这导致每行的新行集。详细信息如下:http://withice.blogspot.com/2014/06/tiuning-list-of-values-in-viewobject.html