Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

  • [bug] sorting grid on a binary field

    SmartClient Version: SNAPSHOT_v12.1d_2019-07-20/Enterprise Development Only (built 2019-07-20)

    Hello, please try the 'upload' sample in the showcase:
    1. upload a file
    2. click "view as list"
    3. sort the grid by the 'Image' column
    4. execute this js code: mediaListGrid.invalidateCache()

    you'll se this error:
    Code:
    === 2019-07-31 11:56:08,583 [c-12] INFO  RequestContext - URL: '/isomorphic/IDACall', User-Agent: 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/75.0.3770.142 Safari/537.36': Safari with Accept-Encoding header
    === 2019-07-31 11:56:08,596 [c-12] DEBUG XML - Parsed XML from (in memory stream): 11ms
    === 2019-07-31 11:56:08,598 [c-12] DEBUG RPCManager - Processing 1 requests.
    === 2019-07-31 11:56:08,599 [c-12] DEBUG RPCManager - Request #1 (DSRequest) payload: {
        criteria:{
        },
        operationConfig:{
            dataSource:"mediaLibrary",
            repo:null,
            operationType:"fetch",
            textMatchStyle:"substring"
        },
        startRow:0,
        endRow:75,
        sortBy:[
            "image"
        ],
        componentId:"mediaTileGrid",
        appID:"builtinApplication",
        operation:"mediaLibrary_fetch",
        oldValues:{
        }
    }
    === 2019-07-31 11:56:08,599 [c-12] INFO  IDACall - Performing 1 operation(s)
    === 2019-07-31 11:56:08,599 [c-12] DEBUG DeclarativeSecurity - Processing security checks for DataSource null, field null
    === 2019-07-31 11:56:08,599 [c-12] DEBUG DeclarativeSecurity - DataSource mediaLibrary is not in the pre-checked list, processing...
    === 2019-07-31 11:56:08,600 [c-12] DEBUG AppBase - No userTypes defined, allowing anyone access to all operations for this application
    === 2019-07-31 11:56:08,600 [c-12] DEBUG AppBase - No public zero-argument method named '_null' found, performing generic datasource operation
    === 2019-07-31 11:56:08,600 [c-12] INFO  SQLDataSource - Performing fetch operation with
        criteria: {}    values: {}
    === 2019-07-31 11:56:08,601 [c-12] INFO  SQLWhereClause - empty condition
    === 2019-07-31 11:56:08,602 [c-12] DEBUG SQLDataSource - Executing row count query: SELECT COUNT(*) FROM $defaultTableClause
    === 2019-07-31 11:56:08,602 [c-12] DEBUG SQLDataSource - Eval'd row count query: 
        SELECT
            COUNT(*) 
        FROM
            mediaLibrary
    === 2019-07-31 11:56:08,602 [c-12] DEBUG SQLConnectionManager - Borrowed connection '650579854'
    === 2019-07-31 11:56:08,603 [c-12] INFO  SQLDriver - Executing SQL query on 'HSQLDB'' using connection '650579854': 
        SELECT
            COUNT(*) 
        FROM
            mediaLibrary
    === 2019-07-31 11:56:08,603 [c-12] DEBUG SQLDataSource - Using SQL Limit query
    === 2019-07-31 11:56:08,603 [c-12] DEBUG SQLDataSource - SQL windowed select rows 0->75, result size 75. Query: 
        SELECT
            LIMIT 0 75  mediaLibrary.pk,
            mediaLibrary.title,
            mediaLibrary.image,
            mediaLibrary.image_filename,
            mediaLibrary.image_filesize,
            mediaLibrary.image_date_created 
        FROM
            mediaLibrary 
        WHERE
            (
                '1'='1'
            ) 
        ORDER BY
            mediaLibrary.image
    === 2019-07-31 11:56:08,604 [c-12] DEBUG SQLDataSource - SQL windowed select rows 0->75, result size 75. Query: 
        SELECT
            LIMIT 0 75  mediaLibrary.pk,
            mediaLibrary.title,
            mediaLibrary.image,
            mediaLibrary.image_filename,
            mediaLibrary.image_filesize,
            mediaLibrary.image_date_created 
        FROM
            mediaLibrary 
        WHERE
            (
                '1'='1'
            ) 
        ORDER BY
            mediaLibrary.image
    === 2019-07-31 11:56:08,604 [c-12] INFO  SQLDataSource - 1191: Executing  query on 'HSQLDB': 
        SELECT
            LIMIT 0 75  mediaLibrary.pk,
            mediaLibrary.title,
            mediaLibrary.image,
            mediaLibrary.image_filename,
            mediaLibrary.image_filesize,
            mediaLibrary.image_date_created 
        FROM
            mediaLibrary 
        WHERE
            (
                '1'='1'
            ) 
        ORDER BY
            mediaLibrary.image
    === 2019-07-31 11:56:08,604 [c-12] DEBUG SQLConnectionManager - About to close connection with hashcode "650579854"
    === 2019-07-31 11:56:08,604 [c-12] DEBUG PoolableSQLConnectionFactory - makeObject() created a pooled Connection '1387096200'
    === 2019-07-31 11:56:08,605 [c-12] DEBUG SQLDataSource - About to clear SQLDriver state for DS instance 1191
    === 2019-07-31 11:56:08,605 [c-12] DEBUG SQLDriver - Freeing SQLDriver dbConnection 1387096200 for SQLDriver instance 907501196
    === 2019-07-31 11:56:08,605 [c-12] DEBUG SQLConnectionManager - About to close connection with hashcode "1387096200"
    === 2019-07-31 11:56:08,605 [c-12] WARN  RequestContext - dsRequest.execute() failed: 
    java.sql.SQLSyntaxErrorException: column of LOB or ARRAY type cannot be used in operation
        at org.hsqldb.jdbc.JDBCUtil.sqlException(Unknown Source)
        at org.hsqldb.jdbc.JDBCUtil.sqlException(Unknown Source)
        at org.hsqldb.jdbc.JDBCStatement.fetchResult(Unknown Source)
        at org.hsqldb.jdbc.JDBCStatement.executeQuery(Unknown Source)
        at org.apache.commons.dbcp.DelegatingStatement.executeQuery(DelegatingStatement.java:208)
        at com.isomorphic.sql.SQLDataSource.executeWindowedSelect(SQLDataSource.java:2578)
        at com.isomorphic.sql.SQLDataSource.SQLExecute(SQLDataSource.java:1818)
        at com.isomorphic.sql.SQLDataSource.processRequest(SQLDataSource.java:440)
        at com.isomorphic.sql.SQLDataSource.executeFetch(SQLDataSource.java:385)
        at com.isomorphic.datasource.DataSource.execute(DataSource.java:2465)
        at com.isomorphic.application.AppBase.executeDefaultDSOperation(AppBase.java:653)
        at com.isomorphic.application.AppBase.executeAppOperation(AppBase.java:554)
        at com.isomorphic.application.AppBase.execute(AppBase.java:497)
        at com.isomorphic.datasource.DSRequest.execute(DSRequest.java:2949)
        at com.isomorphic.servlet.IDACall.handleDSRequest(IDACall.java:230)
        at com.isomorphic.servlet.IDACall.processRPCTransaction(IDACall.java:187)
        at com.isomorphic.servlet.IDACall.processRequest(IDACall.java:152)
        at com.isomorphic.servlet.IDACall._processRequest(IDACall.java:119)
        at com.isomorphic.servlet.IDACall.doPost(IDACall.java:79)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:660)
        at com.isomorphic.servlet.BaseServlet.service(BaseServlet.java:180)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:741)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
        at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
        at com.isomorphic.servlet.URIRegexFilter.ignore(URIRegexFilter.java:447)
        at com.isomorphic.servlet.URIRegexFilter.ignore(URIRegexFilter.java:442)
        at com.isomorphic.servlet.URIRegexFilter.matchedRule(URIRegexFilter.java:405)
        at com.isomorphic.servlet.URIRegexFilter._doFilter(URIRegexFilter.java:332)
        at com.isomorphic.servlet.BaseFilter.doFilter(BaseFilter.java:90)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
        at com.isomorphic.js.JSSyntaxScannerFilter._doFilter(JSSyntaxScannerFilter.java:262)
        at com.isomorphic.servlet.BaseFilter.doFilter(BaseFilter.java:90)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
        at com.isomorphic.servlet.CompressionFilter._doFilter(CompressionFilter.java:260)
        at com.isomorphic.servlet.BaseFilter.doFilter(BaseFilter.java:90)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
        at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:199)
        at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:96)
        at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:493)
        at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:137)
        at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:81)
        at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:87)
        at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:343)
        at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:798)
        at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66)
        at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:808)
        at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1498)
        at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
        at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
        at java.lang.Thread.run(Thread.java:745)
    Caused by: org.hsqldb.HsqlException: column of LOB or ARRAY type cannot be used in operation
        at org.hsqldb.error.Error.error(Unknown Source)
        at org.hsqldb.error.Error.error(Unknown Source)
        at org.hsqldb.SortAndSlice.setSortIndex(Unknown Source)
        at org.hsqldb.QuerySpecification.resolveTypesPartThree(Unknown Source)
        at org.hsqldb.QueryExpression.resolve(Unknown Source)
        at org.hsqldb.ParserDQL.compileCursorSpecification(Unknown Source)
        at org.hsqldb.ParserCommand.compilePart(Unknown Source)
        at org.hsqldb.ParserCommand.compileStatements(Unknown Source)
        at org.hsqldb.Session.executeDirectStatement(Unknown Source)
        at org.hsqldb.Session.execute(Unknown Source)
        ... 56 more
    === 2019-07-31 11:56:08,607 [c-12] DEBUG RPCManager - Content type for RPC transaction: text/plain; charset=UTF-8
    === 2019-07-31 11:56:08,607 [c-12] DEBUG RPCManager - non-DMI response, dropExtraFields: false
    === 2019-07-31 11:56:08,608 [c-12] DEBUG SQLDataSource - About to clear SQLDriver state for DS instance 1191
    === 2019-07-31 11:56:08,608 [c-12] DEBUG SQLDataSource - About to clear SQLDriver state for DS instance 1191
    === 2019-07-31 11:56:08,608 [c-12] DEBUG SQLDataSource - About to clear SQLDriver state for DS instance 1191
    === 2019-07-31 11:56:08,608 [c-12] INFO  Compression - /isomorphic/IDACall: 191 -> 168 bytes
    Actually I've got this problem using Oracle, so I get ORA-00932 error.

    It seems that the setting sortBinaryByFileName (true by default) is ignored.
Working...
X