Symptom
- The SET STATISTICS IO ON command has been executed
- Query invoking a user-defined function (UDF) is executed
- Query with UDF result set returned with different format than similar query with system function
- For example:
Query results with system function:
1> select id, rtrim(substring(token, 1, charindex( ',', token)-1)) from t1
2> go
id
----------- --------------------
1 aa
2 bb
3 cc
Table: t1 scan count 1, logical reads: (regular=1 apf=0 total=1), physical
reads: (regular=0 apf=0 total=0), apf IOs used=0
Total writes for this command: 0
(3 rows affected)
Query results with user-defined function:
1> select id, dbo.f1(token) from t1
2> go
Total writes for this command: 0
Total writes for this command: 0
Total writes for this command: 0
id
----------- ------------------------------
1 aa
Total writes for this command: 0
Total writes for this command: 0
Total writes for this command: 0
id
----------- ------------------------------
2 bb
Total writes for this command: 0
Total writes for this command: 0
Total writes for this command: 0
id
----------- ------------------------------
3 cc
Table: t1 scan count 1, logical reads: (regular=1 apf=0 total=1), physical
reads: (regular=0 apf=0 total=0), apf IOs used=0
Total writes for this command: 0
(3 rows affected)
- Variable format may cause problems for applications expecting a certain result set format
Read more...
Environment
SAP Adaptive Server Enterprise (ASE) 15.x and above
Product
Keywords
system function, query, resultset , KBA , BC-SYB-ASE , Sybase ASE Database Platform (non Business Suite) , BC-DB-SYB , Business Suite on Adaptive Server Enterprise , Product Enhancement
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.