Uploaded image for project: 'Music'
  1. Music
  2. MUSIC-391

MDBC error net.sf.jsqlparser.JSQLParserException

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Medium Medium
    • El Alto Release
    • El Alto Release
    • mdbc
    • None

      net.sf.jsqlparser.JSQLParserExceptionnet.sf.jsqlparser.JSQLParserException at net.sf.jsqlparser.parser.CCJSqlParserUtil.parse(CCJSqlParserUtil.java:56) at org.onap.music.mdbc.query.QueryProcessor.extractTableFromQuery(QueryProcessor.java:180)Caused by: net.sf.jsqlparser.parser.ParseException: Encountered " ":" ": "" at line 1, column 17.Was expecting one of:    <EOF>     "AS" ...    "ORDER" ...     at net.sf.jsqlparser.parser.CCJSqlParser.generateParseException(CCJSqlParser.java:16869) at net.sf.jsqlparser.parser.CCJSqlParser.jj_consume_token(CCJSqlParser.java:16722) at net.sf.jsqlparser.parser.CCJSqlParser.Statement(CCJSqlParser.java:91) at net.sf.jsqlparser.parser.CCJSqlParserUtil.parse(CCJSqlParserUtil.java:54) at org.onap.music.mdbc.query.QueryProcessor.extractTableFromQuery(QueryProcessor.java:180) at org.onap.music.mdbc.MdbcConnection.preStatementHook(MdbcConnection.java:507) at org.onap.music.mdbc.MdbcPreparedStatement.execute(MdbcPreparedStatement.java:604) at org.apache.calcite.avatica.jdbc.JdbcMeta.execute(JdbcMeta.java:868) at org.onap.music.mdbc.MdbcServerLogic.execute(MdbcServerLogic.java:264)

       

      select @rn /'/:=/'/ @rn+1 AS rowId, notification_ID, is_for_online_users,is_for_all_roles, msg_header, msg_description,msg_source, start_Time, end_time, priority, created_date, creator_ID,notification_hyperlink, active_YN from select @rn /'/:=/'/ @rn+1 AS rowId, notification_ID, is_for_online_users,is_for_all_roles, msg_header, msg_description,msg_source, start_Time, end_time, priority, created_date, creator_ID,notification_hyperlink, active_YN from  (   select notification_ID, is_for_online_users, is_for_all_roles, msg_header, msg_description, msg_source,start_Time, end_time, priority,created_date, creator_ID,notification_hyperlink,active_YN  from  (  select user_id, notification_id, is_for_online_users, is_for_all_roles, msg_header, msg_description,msg_source,start_Time, end_time, priority, created_date,notification_hyperlink, creator_ID,active_YN  from  (  select a.notification_ID,a.is_for_online_users,a.is_for_all_roles,a.active_YN,  a.msg_header,a.msg_description,a.msg_source,a.start_time,a.end_time,a.priority,a.creator_ID,a.notification_hyperlink,a.created_date,b.role_id,b.recv_user_id  from ep_notification a, ep_role_notification b  where a.notification_id = b.notification_id  and (end_time is null ||  SYSDATE() <= end_time )  and (start_time is null ||  SYSDATE() >= start_time)  and a.is_for_all_roles = 'N'  ) a,  (  select distinct a.user_id, c.role_id, c.app_id, d.APP_NAME  from fn_user a, fn_user_role b, fn_role c, fn_app d  where COALESCE(c.app_id,1) = d.app_id         and a.user_id = b.user_id  and a.user_id = ?  and b.role_id = c.role_id       and (d.enabled='Y' or d.app_id=1)  )b  where  (  a.role_id = b.role_id  )  union  select ?, notification_id, is_for_online_users, is_for_all_roles, msg_header, msg_description,msg_source,start_Time, end_time, priority, created_date,notification_hyperlink, creator_ID,active_YN  from  (  select a.notification_ID,a.is_for_online_users,a.is_for_all_roles,a.active_YN,  a.msg_header,a.msg_description,a.msg_source,a.start_time,a.end_time,a.priority,a.creator_ID,a.created_date, a.notification_hyperlink,b.role_id,b.recv_user_id  from ep_notification a, ep_role_notification b  where a.notification_id = b.notification_id  and (end_time is null ||  SYSDATE() <= end_time )  and (start_time is null ||  SYSDATE() >= start_time)  and a.is_for_all_roles = 'N'  ) a  where  (  a.recv_user_id=?  )  union  (  select ? user_id, notification_id, is_for_online_users, is_for_all_roles, msg_header, msg_description, msg_source,start_Time, end_time, priority, created_date,notification_hyperlink, creator_ID,active_YN  from ep_notification a  where a.notification_id  and (end_time is null ||  SYSDATE() <= end_time )  and (start_time is null ||  SYSDATE() >= start_time)  and a.is_for_all_roles = 'Y'  )  ) a  where  active_YN = 'Y'  and  not exists  (  select ID,User_ID,notification_ID,is_viewed,updated_time from ep_user_notification m where user_id = ? and m.notification_id = a.notification_id and is_viewed = 'Y'  )  order by priority desc, created_date desc,start_Time desc    ) t,  (SELECT @rn /'/:=/'/ 0) t2  ;

            bptschaen bptschaen
            hb123f hb123f
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: