Title: Exception when comparing collections with utp.ut.expect · Issue #1235 · utPLSQL/utPLSQL · GitHub
Open Graph Title: Exception when comparing collections with utp.ut.expect · Issue #1235 · utPLSQL/utPLSQL
X Title: Exception when comparing collections with utp.ut.expect · Issue #1235 · utPLSQL/utPLSQL
Description: Describe the bug When comparing collections converted to anydata with utp.ut.expect sometimes we get this error, usually it works correctly. Provide version info utPLSQL 3.1.12 Information about client software not applicable To Reproduc...
Open Graph Description: Describe the bug When comparing collections converted to anydata with utp.ut.expect sometimes we get this error, usually it works correctly. Provide version info utPLSQL 3.1.12 Information about cl...
X Description: Describe the bug When comparing collections converted to anydata with utp.ut.expect sometimes we get this error, usually it works correctly. Provide version info utPLSQL 3.1.12 Information about cl...
Opengraph URL: https://github.com/utPLSQL/utPLSQL/issues/1235
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Exception when comparing collections with utp.ut.expect","articleBody":"**Describe the bug**\r\nWhen comparing collections converted to anydata with utp.ut.expect sometimes we get this error, usually it works correctly.\r\n\r\n**Provide version info**\r\nutPLSQL 3.1.12\r\n\r\n**Information about client software**\r\nnot applicable\r\n\r\n**To Reproduce**\r\n\r\nRun the below script\r\n```sql\r\n\r\n-- type creation\r\n/*\r\ncreate or replace type tp_r_ug_sportsman_invitation_result is object\r\n(\r\n code number(18),\r\n sportsman_name varchar2(100),\r\n mobile_phone varchar2(20),\r\n err_code number,\r\n err_text varchar2(4000)\r\n);\r\ncreate or replace type tp_t_ug_sportsman_invitation_result is table of tp_r_ug_sportsman_invitation_result;\r\n*/\r\n\r\ndeclare\r\n --records to compare\r\n --record 1\r\n v_sportsman_invitation_result tp_t_ug_sportsman_invitation_result := tp_t_ug_sportsman_invitation_result\r\n (\r\n tp_r_ug_sportsman_invitation_result\r\n (\r\n code =\u003e 1,\r\n sportsman_name =\u003e 'sportsman_1',\r\n mobile_phone =\u003e '79666666666',\r\n err_code =\u003e 1,\r\n err_text =\u003e null\r\n )\r\n );\r\n\r\n --record 2\r\n v_sportsman_invitation_exp tp_t_ug_sportsman_invitation_result := tp_t_ug_sportsman_invitation_result\r\n (\r\n tp_r_ug_sportsman_invitation_result\r\n (\r\n code =\u003e 1,\r\n sportsman_name =\u003e 'sportsman_1',\r\n mobile_phone =\u003e '79666666666',\r\n err_code =\u003e 1,\r\n err_text =\u003e null\r\n )\r\n );\r\nbegin\r\n --check rows in collections\r\n utp.ut.expect(v_sportsman_invitation_result.count, 'count collection')\r\n .to_equal(v_sportsman_invitation_exp.count);\r\n\r\n if v_sportsman_invitation_result.count = v_sportsman_invitation_exp.count then\r\n\r\n for i in 1..v_sportsman_invitation_result.count\r\n loop\r\n --check values of each part of a record\r\n utp.ut.expect(v_sportsman_invitation_result(i).sportsman_name, 'sportsman_name(' || i || ')')\r\n .to_equal(v_sportsman_invitation_exp(i).sportsman_name);\r\n utp.ut.expect(v_sportsman_invitation_result(i).mobile_phone, 'mobile_phone(' || i || ')')\r\n .to_equal(v_sportsman_invitation_exp(i).mobile_phone);\r\n utp.ut.expect(v_sportsman_invitation_result(i).err_code, 'err_code(' || i || ')')\r\n .to_equal(v_sportsman_invitation_exp(i).err_code);\r\n end loop;\r\n\r\n --compare 2 collections, here we get the exception\r\n\tutp.ut.expect(anydata.convertCollection(v_sportsman_invitation_result), 'Collections equal')\r\n .to_equal(anydata.convertCollection(v_sportsman_invitation_exp));\r\n\r\n end if;\r\nend;\r\n```\r\n\r\n**See the exception:**\r\n\r\nORA-06502: PL/SQL: : numeric or value error: character string buffer too small\r\nORA-06512: на \"UTP.UT_DATA_VALUE_ANYDATA\", line 98\r\nORA-06512: на \"SYS.DBMS_SQL\", line 2146\r\nORA-06512: на \"UTP.UT_CURSOR_DETAILS\", line 100\r\nORA-06512: на \"UTP.UT_DATA_VALUE_ANYDATA\", line 84\r\nORA-06512: на \"UTP.UT_DATA_VALUE_ANYDATA\", line 114\r\nORA-06512: на \"UTP.UT\", line 33\r\nORA-06512: на line 61\r\n\r\n**Expected behavior**\r\n\r\nWe expect to get collections differences.\r\n","author":{"url":"https://github.com/SElfimov","@type":"Person","name":"SElfimov"},"datePublished":"2022-09-28T12:47:43.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":6},"url":"https://github.com/1235/utPLSQL/issues/1235"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:93f2e9f7-f761-0dae-8f01-d8ec85067424 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | E8B8:3FE03B:A8F2AC:F114CC:6A63831F |
| html-safe-nonce | 49cacf8c95a9ca55d17a422def1be0050a9680502de02c4a53bcfcd6a1590ee1 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJFOEI4OjNGRTAzQjpBOEYyQUM6RjExNENDOjZBNjM4MzFGIiwidmlzaXRvcl9pZCI6IjM5Mjk3Mjc4MjMwMDg0NjU2OTUiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | 5c5891fb54457d7c48cb355b5242b9c0850f0a4b9f0c2995498810954effdc4d |
| hovercard-subject-tag | issue:1389582309 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/utPLSQL/utPLSQL/1235/issue_layout |
| twitter:image | https://opengraph.githubassets.com/f259db124452e68289bd27a6e906b599723c372e2a4a3fdcec560efbde0f6923/utPLSQL/utPLSQL/issues/1235 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/f259db124452e68289bd27a6e906b599723c372e2a4a3fdcec560efbde0f6923/utPLSQL/utPLSQL/issues/1235 |
| og:image:alt | Describe the bug When comparing collections converted to anydata with utp.ut.expect sometimes we get this error, usually it works correctly. Provide version info utPLSQL 3.1.12 Information about cl... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | SElfimov |
| hostname | github.com |
| expected-hostname | github.com |
| None | e4fb64aef87da454ec25b158147f7f5f14aef29216e5ca1612c2e48faa599d1f |
| turbo-cache-control | no-preview |
| go-import | github.com/utPLSQL/utPLSQL git https://github.com/utPLSQL/utPLSQL.git |
| octolytics-dimension-user_id | 15661281 |
| octolytics-dimension-user_login | utPLSQL |
| octolytics-dimension-repository_id | 50728220 |
| octolytics-dimension-repository_nwo | utPLSQL/utPLSQL |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 50728220 |
| octolytics-dimension-repository_network_root_nwo | utPLSQL/utPLSQL |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | e839936ba5faffb9c836dda1cf4729d50c88a32e |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width