bug: The instance is crashed when extracting data from the union all result set of decimal and integer.
haitaoguan opened this issue · comments
haitaoguan commented
Have you read the Contributing Guidelines on issues?
- I have read the Contributing Guidelines on issues.
Please confirm if bug report does NOT exists already ?
- I confirm there is no existing issue for this
Describe the problem
SELECT IF(@rowno != a.taxis_no, @rankno := 1, @rankno := @rankno + 1) AS "rowNos",
IFNULL(a.out_amount / 1, '-') out_amount
FROM (SELECT a.*
FROM (SELECT a.currency_id, a.out_amount, d.taxis_no
FROM (SELECT b.CURRENCY_ID, a.account_id, 0 out_amount
FROM C1AM_ACCT_DAY a, C1MD_BANK_ACCT b
WHERE a.account_id = b.ROW_ID
UNION ALL
SELECT b.CURRENCY_ID,
a.account_id,
sum(a.out_amount) out_amount
FROM C1AM_BANK_LIST a, C1MD_BANK_ACCT b
WHERE a.account_id = b.ROW_ID
GROUP BY a.account_id, b.CURRENCY_ID) a
JOIN C1MD_BANK_ACCT b
on b.row_id = a.account_id
JOIN C1MD_COMPANY c
on c.row_id = b.company_id
JOIN C1CD_CURRENCY d
ON a.currency_id = d.row_id
WHERE 1 = 1
AND c.row_id IN (SELECT t1.row_id
FROM C1MD_COMPANY t1, C1MD_COMPANY t2
WHERE t1.sys_id = t2.sys_id)) a) a
ERROR 2013 (HY000): Lost connection to MySQL server during query
Expected behavior
No response
How To Reproduce
No response
Environment
./mysqld Ver 5.7.36-StoneDB-v1.0.1 for Linux on x86_64 (build-)
build information as follow:
Repository address: https://github.com/stoneatom/stonedb.git:stonedb-5.7-dev
Branch name: stonedb-5.7-dev
Last commit ID: 1f43e44
Last commit time: Date: Wed May 31 17:34:21 2023 +0800
Build time: Date: Thu Jun 1 07:20:38 UTC 2023
Are you interested in submitting a PR to solve the problem?
- Yes, I will!