I'm posting this on the off chance it might support troubleshooting of another post I just made (
http://forums.smartclient.com/showth...446#post113446 )
I noticed some Velocity oddness this morning, thought you'd want to know.
I have these two OperationBindings, the second one created recently:
I have some client code that calls the first OperationBinding:
This generates a SQL query that takes elements from BOTH OperationBindings:
- The OperationID is from the first OperationBinding ("filterItem_Names")
- but the SQL query is derived from the second ("SELECT distinct org_id")
Eclipse does not indicate any XML errors, nor can I see any.
As it happens, I don't really need the second OperationBinding, so I remarked it out, and the error goes away.
But I thought you'd want to know.
---------------------------------------
SmartClient Version: v9.0p_2013-12-01/PowerEdition Deployment (built 2013-12-01)
IE 8
http://forums.smartclient.com/showth...446#post113446 )
I noticed some Velocity oddness this morning, thought you'd want to know.
I have these two OperationBindings, the second one created recently:
Code:
<operationBinding appScreen="Review" operationType="fetch" operationid="filterItem_Names"> <selectClause>distinct name</selectClause> <!-- <selectClause>distinct employee.name</selectClause> // tried this, fails the same --> <tableClause>${defaultTableClause}</tableClause> <whereClause>${defaultWhereClause}</whereClause> </operationBinding> <operationBinding appScreen="Review" operationType="fetch" operationid="filterItem_OrgId"> <selectClause>distinct org_id</selectClause> <tableClause>${defaultTableClause}</tableClause> <whereClause>${defaultWhereClause}</whereClause> </operationBinding>
Code:
private ListGridField make_ListGridField_Name() { // Column for EMPLOYEE.NAME ListGridField lgf_Name = new ListGridField("NAME", "Requestor") { { setOptionDataSource(ds_Employee); setWidth("130px"); setAlign(Alignment.CENTER); setCellAlign(Alignment.LEFT); setFilterEditorProperties(new SelectItem() { { setOptionDataSource(ds_Employee); setOptionOperationId("filterItem_Names"); setSortField("NAME"); setMultiple(true); setMultipleAppearance(MultipleAppearance.PICKLIST); setAllowEmptyValue(true); } }); } }; return lgf_Name; }// make_ListGridField_Name
- The OperationID is from the first OperationBinding ("filterItem_Names")
- but the SQL query is derived from the second ("SELECT distinct org_id")
Code:
=== 2013-12-06 09:46:44,063 [0-26] INFO SQLDriver - [builtinApplication.filterItem_Names] Executing SQL query on 'MyDatabase': SELECT distinct org_id FROM absence_dev.EMPLOYEE WHERE ('1'='1') ORDER BY EMPLOYEE.NAME === 2013-12-06 09:46:44,063 [0-26] WARN RequestContext - dsRequest.execute() failed: java.sql.SQLException: ORA-01791: not a SELECTed expression at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:113) at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:331) at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:288) at oracle.jdbc.driver.T4C8Oall.receive(T4C8Oall.java:754) at oracle.jdbc.driver.T4CStatement.doOall8(T4CStatement.java:210) at oracle.jdbc.driver.T4CStatement.executeForDescribe(T4CStatement.java:804) at oracle.jdbc.driver.OracleStatement.executeMaybeDescribe(OracleStatement.java:1051) at oracle.jdbc.driver.T4CStatement.executeMaybeDescribe(T4CStatement.java:845) at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1156) at oracle.jdbc.driver.OracleStatement.executeQuery(OracleStatement.java:1315) at org.apache.commons.dbcp.DelegatingStatement.executeQuery(DelegatingStatement.java:208) at com.isomorphic.sql.SQLDriver.getTransformedResults(SQLDriver.java:604) at com.isomorphic.sql.SQLDriver.executeQuery(SQLDriver.java:917) at com.isomorphic.sql.SQLDataSource.executeNativeQuery(SQLDataSource.java:523) at com.isomorphic.sql.SQLDataSource.executeNativeQuery(SQLDataSource.java:517) at com.isomorphic.sql.SQLDataSource.SQLExecute(SQLDataSource.java:1548) at com.isomorphic.sql.SQLDataSource.processRequest(SQLDataSource.java:408) at com.isomorphic.sql.SQLDataSource.executeFetch(SQLDataSource.java:352) at com.isomorphic.datasource.DataSource.execute(DataSource.java:1447) at com.isomorphic.application.AppBase.executeDefaultDSOperation(AppBase.java:723) at com.isomorphic.application.AppBase.executeAppOperation(AppBase.java:658) at com.isomorphic.application.AppBase.execute(AppBase.java:491) at com.isomorphic.datasource.DSRequest.execute(DSRequest.java:2431) at com.isomorphic.servlet.IDACall.handleDSRequest(IDACall.java:215) at com.isomorphic.servlet.IDACall.processRPCTransaction(IDACall.java:172) at com.isomorphic.servlet.IDACall.processRequest(IDACall.java:137) at com.isomorphic.servlet.IDACall.doPost(IDACall.java:73) at javax.servlet.http.HttpServlet.service(HttpServlet.java:637) at com.isomorphic.servlet.BaseServlet.service(BaseServlet.java:152) at javax.servlet.http.HttpServlet.service(HttpServlet.java:717) at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:487) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1097) at com.isomorphic.servlet.CompressionFilter.doFilter(CompressionFilter.java:260) at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1088) at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:360) at org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216) at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:181) at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:729) at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:405) at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152) at org.mortbay.jetty.handler.RequestLogHandler.handle(RequestLogHandler.java:49) at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152) at org.mortbay.jetty.Server.handle(Server.java:324) at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:505) at org.mortbay.jetty.HttpConnection$RequestHandler.content(HttpConnection.java:843) at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:647) at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:205) at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:380) at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:395) at org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThreadPool.java:488)
As it happens, I don't really need the second OperationBinding, so I remarked it out, and the error goes away.
But I thought you'd want to know.
---------------------------------------
SmartClient Version: v9.0p_2013-12-01/PowerEdition Deployment (built 2013-12-01)
IE 8
Comment