SAP Knowledge Base Article - Preview

3571831 - Crash on dfv_RowViewSubset::GetValuePtr - SAP IQ

Symptom

  • SAP IQ server crashes when executing a specific SQL with a User-Defined Function (UDF) and window function.
  • The SQL is identified to have a syntax error, with non-aggregate columns not included in the group by clause.
  • The crash seems to occur when three conditions are present: a UDF in the select list, a windows function, and the SQL is from a view with many joins.
  • Stacktrace generated:
  • I. 02/11 05:56:00. 0000002837 Disconnect:  SA connHandle: 1000002836  SA connID: 14  IQ connID: 0000002837  User: dbo
    I. 02/11 05:56:26. 0000000099  
    I. 02/11 05:56:26. 0000000099  
    I. 02/11 05:56:26. 0000000099 **************************************************
    I. 02/11 05:56:26. 0000000099 ***   SAP IQ Abort:
    I. 02/11 05:56:26. 0000000099 ***      From:  stcxtlib/st_server.cxx:2507
    I. 02/11 05:56:26. 0000000099 ***      PID: 3153
    I. 02/11 05:56:26. 0000000099 ***      Message: caught signal 11, program abort (pc=0x00007f7164641737, sp=0x00007f7131db9318, fp=0x00007f713ac70a68, addr=0x0000000000000000)
    I. 02/11 05:56:26. 0000000099 ***      Thread: 140124144510720  (TIX: 2)
    I. 02/11 05:56:26. 0000000099 **************************************************
    I. 02/11 05:56:26. 0000000099  
    I. 02/11 05:56:26. 0000000099 140124144510720 Stacktrace requested from stcxtlib/st_server.cxx:2507 on thread 140124144510720 (TIX 2) start stacktrace
    I. 02/11 05:56:26. 0000000099     **  Error from IQ connection:  SA connHandle: 1  SA connID: 6  IQ connID: 0000000099  User: dba
    I. 02/11 05:56:26. 0000000099     **  Time of error:  2025-02-11 05:56:26
    I. 02/11 05:56:26. 0000000099     **  IQ Version:  SAP IQ/16.1.050/14705/P/SP05.13
    I. 02/11 05:56:26. 0000000099     **  OS info:  IQ built on: Linux/Linux64 - x86_64 - 3.10.0-327,  Executed on: Linux/TREINAMENTOIQ/4.18.0-348.7.1.el8_5.x86_64/#1 SMP Wed Dec 22 13:25:12 UTC 2021/x86_64
    I. 02/11 05:56:26. 0000000099     **  Command status when error occurred:  NO COMMAND OR CURSOR ACTIVE
    I. 02/11 05:56:26. 0000000099     **  Parser command text:
    I. 02/11 05:56:26. 0000000099 select "rev_yym" as "Dt",
    I. 02/11 05:56:26. 0000000099   "SS_Fund_Code",
    I. 02/11 05:56:26. 0000000099   "dba"."GetFiscalQuarter"("rev_yym") as "FISCAL_QTR",
    I. 02/11 05:56:26. 0000000099   "SUM"("Avg_AUM_SERIES") as "AUM",
    I. 02/11 05:56:26. 0000000099   "SUM"("GROSS_REV_BMOGAM_p_Mo") as "GROSS_REV_Mo",
    I. 02/11 05:56:26. 0000000099   "MAX"("GROSS_REV_BMOGAM_p_Mo") over(order by "rev_yym" asc,"SS_Fund_Code" asc rows between 11 preceding and current row) as "GROSS_REV_BMOGAM_p_Mo_UPD",
    I. 02/11 05:56:26. 0000000099   "GROSS_REV_BMOGAM_p_Mo"
    I. 02/11 05:56:26. 0000000099   from "dba"."vw_REV_series_breakout"
    I. 02/11 05:56:26. 0000000099   group by "rev_yym","SS_Fund_Code"
    I. 02/11 05:56:26. 0000000099   order by "rev_yym" asc,"SS_Fund_Code" asc
    I. 02/11 05:56:26. 0000000099     **  Dump all thread stacks at stcxtlib/st_server.cxx:2507 for PID: 3153
    I. 02/11 05:56:26. 0000000099 ***************** This is the STACKTRACE ***************
    I. 02/11 05:56:26. 0000000099 ===== Thread Number 140124144510720 (IQ connID: 0000000099) =====
    I. 02/11 05:56:26. 0000000099 pc: 0x400e81 backtrace+21
    I. 02/11 05:56:26. 0000000099 pc: 0x7f712d7c1fc4 pcstkwalk(stk_trace*, int, db_log*, hos_fd*)+34
    I. 02/11 05:56:26. 0000000099 pc: 0x7f712d7c26eb ucstkgentrace(int, int)+18b
    I. 02/11 05:56:26. 0000000099 pc: 0x7f712d7c2fad DumpAllThreads(char const*, unsigned int, int)+2bd
    I. 02/11 05:56:26. 0000000099 pc: 0x7f712d53c701 hos_ABORT(char const*, unsigned int, char const*, char*, char*, sigcontext*, int, int)+4f1
    I. 02/11 05:56:26. 0000000099 pc: 0x7f712e3a8d6c SigHndlr+11c
    I. 02/11 05:56:26. 0000000099 pc: 0x7f71635a6c20 <unknown>
    I. 02/11 05:56:26. 0000000099 pc: 0x7f7164641737 dfv_RowViewSubset::GetValuePtr(unsigned int)+7
    I. 02/11 05:56:26. 0000000099 pc: 0x7f7164643b00 dfv_RowViewContextBase::GetValuePtrs(unsigned int, unsigned int, dfv_Value const**, unsigned int&)+3d0
    I. 02/11 05:56:26. 0000000099 pc: 0x7f71648a1fd8 df_SortHash::WriteHashAndSatellite(UTBufferedOStream&, a_dfe_row*, dfv_Row const*, unsigned long long)+88
    I. 02/11 05:56:26. 0000000099 pc: 0x7f71648a934d df_RowSinkSortOStream::DoAddRow(dfv_Row const*, unsigned long long)+4d
    I. 02/11 05:56:26. 0000000099 pc: 0x7f71648a9404 df_RowSinkSortOStream::AddRow(dfv_Row const*)+34
    I. 02/11 05:56:26. 0000000099 pc: 0x7f7164519caa dfo_SortReplacement::PopulateFully()+5a
    I. 02/11 05:56:26. 0000000099 pc: 0x7f7164519dc0 dfo_SortReplacement::DoFirstFetch(a_cursor_orientation)+80
    I. 02/11 05:56:26. 0000000099 pc: 0x7f71644fc997 dfo_Base::Fetch(a_cursor_orientation)+a7
    I. 02/11 05:56:26. 0000000099 pc: 0x7f716458ccf4 dfo_Window::DoFirstFetch(a_cursor_orientation)+134
    I. 02/11 05:56:26. 0000000099 pc: 0x7f71644fc997 dfo_Base::Fetch(a_cursor_orientation)+a7
    I. 02/11 05:56:26. 0000000099 pc: 0x7f716452d221 dfo_MaterializePack::PopulateFully(a_cursor_orientation)+51
    I. 02/11 05:56:26. 0000000099 pc: 0x7f716452c31a dfo_Materialize::DoFirstFetch(a_cursor_orientation)+1a
    I. 02/11 05:56:26. 0000000099 pc: 0x7f71644fc997 dfo_Base::Fetch(a_cursor_orientation)+a7
    I. 02/11 05:56:26. 0000000099 pc: 0x7f7164505544 dfo_Root::DoFetch(a_cursor_orientation)+44
    I. 02/11 05:56:26. 0000000099 pc: 0x7f71645057d0 dfo_Root::DoFirstFetch(a_cursor_orientation)+30
    I. 02/11 05:56:26. 0000000099 pc: 0x7f71644fc997 dfo_Base::Fetch(a_cursor_orientation)+a7
    I. 02/11 05:56:26. 0000000099 pc: 0x7f71644fdb8d dfo_Root::DoFetchRelative(int, int*)+bd
    I. 02/11 05:56:26. 0000000099 pc: 0x7f7164500cc1 dfo_Root::FetchRelative(int, int*)+91
    I. 02/11 05:56:26. 0000000099 pc: 0x7f71640ce875 DB_Search_fetch(a_db_cursor*, unsigned int, int, int*)+65
    I. 02/11 05:56:26. 0000000099 pc: 0x7f7164269fc2 dbi_fetch(a_db_cursor*, int, unsigned short, unsigned int, unsigned int, unsigned int, unsigned int, unsigned int, unsigned int)+e2
    I. 02/11 05:56:26. 0000000099 pc: 0x7f71643d5b22 db__fetch(Connection*, an_sqlpres_receive*)+1b2
    I. 02/11 05:56:26. 0000000099 pc: 0x7f71643f5586 RequestProcedure::call()+e76
    I. 02/11 05:56:26. 0000000099 pc: 0x7f7164199331 Worker::spawn(Procedure*)+31
    I. 02/11 05:56:26. 0000000099 pc: 0x7f71643f94b6 EngStream::handle_ind(unsigned char, unsigned int)+156
    I. 02/11 05:56:26. 0000000099 pc: 0x7f71643fafef EngStream::execute()+7ff
    I. 02/11 05:56:26. 0000000099 pc: 0x7f71643fb16d RQConnItem::do_request()+d
    I. 02/11 05:56:26. 0000000099 pc: 0x7f71643f2f0e RQBaseItem::do_work(Worker*)+1e
    I. 02/11 05:56:26. 0000000099 pc: 0x7f7164436c17 RequestQueue::worker_body()+77
    I. 02/11 05:56:26. 0000000099 pc: 0x7f71643f42c9 request_task(void*)+89
    I. 02/11 05:56:26. 0000000099 pc: 0x7f716487ef8e run_task_body+1e
    I. 02/11 05:56:26. 0000000099 pc: 0x7f7164438878 UnixTask::pre_body(void*)+78
    I. 02/11 05:56:26. 0000000099 pc: 0x7f716359c17a <unknown>
    I. 02/11 05:56:26. 0000000099 pc: 0x7f71629b0dc3 clone+43


Read more...

Environment

SAP IQ

Product

SAP IQ all versions

Keywords

SAP IQ, crash, SQL, UDF, window function, syntax error, non-aggregate columns, view, joins. , KBA , BC-SYB-IQ , Sybase IQ , Problem

About this page

This is a preview of a SAP Knowledge Base Article. Click more to access the full version on SAP for Me (Login required).

Search for additional results

Visit SAP Support Portal's SAP Notes and KBA Search.