Question

Why does this Query Fails?

SELECT
    SUB_COMMODITY,
    `VOL` AS Sales,
    `VOL_CHANGE` AS Dollar_change,
    `VOL_SHARE` AS Dollar_share,
    `VOL_SHARE_CHANGE` AS Dollar_share_change,
    `U_VOL` AS Unit_sales,
    `UVOL_CHANGE` AS Unit_change,
    `UVOL_SHARE` AS Unit_share,
    `UVOL_SHARE_CHANGE` AS Unit_share_change,
    `VOL_MKT_SHARE` AS Market_share,
    `PERIOD`
FROM `calculatedsummary`
WHERE WEEK = 52
AND PERIOD BETWEEN '2012-03-01' AND '2012-03-31'
AND MKT = '000 Total Market'
AND COMMODITY = 'CONDIMENTS SAUCES'
AND SUB_COMMODITY = 'BBQ SAUCE'
AND BRAND_FAMILY_DESC = 'Total'
AND session_id = 'ADBCDEFGHIJQLMNOPQRSTUVWXYZ'

MySQL server log:

  • InnoDB: Assertion failure in thread 2292 in file row0sel.c line 2441
  • InnoDB: Failing assertion: buf + data_len <= original_buf + buf_len
  • InnoDB: We intentionally generate a memory trap.
  • InnoDB: Submit a detailed bug report to http://bugs.mysql.com.
  • InnoDB: If you get repeated assertion failures or crashes, even
  • InnoDB: immediately after the mysqld startup, there may be
  • InnoDB: corruption in the
  • InnoDB tablespace. Please refer to
  • InnoDB: http://dev.mysql.com/doc/refman/5.5/en/forcing-innodb-recovery.html
  • InnoDB: about forcing recovery.
  • InnoDB: Thread 1544 stopped in file os0sync.c line 474
  • InnoDB: Thread 2028 stopped in file os0sync.c line 781

And also get a #2013 error - Lost connection to MySQL server during query

But if I change

session_id = 'ADBCDEFGHIJQLMNOPQRSTUVWXYZ'

TO

session_id LIKE '%ADBCDEFGHIJQLMNOPQRSTUVWXYZ%'

Was it helpful?

Solution

I solved the problem,

Apparently the table I has working with had the more than 50 fields set to VARCHAR 255 and that was too big, so by reducing the field size to the accurate size the problem got resolved.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top