Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I have a really weird problem with MySQL server

When I execute for example:

EXPLAIN EXTENDED SELECT PRODNO,
          DT,
          FLAG1,
          FLAG2,
          `ORDER`,
          `QUANTITY`,
          `CARRYOVER`,
          `RETURNS`,
          `QUANTITY` + `CARRYOVER` - `RETURNS` AS `TOTALMARKET`
   FROM   (SELECT  NAME_CONST('_DATE',_binary'2011-02-20' COLLATE 'binary') AS wdt
             UNION ALL
             SELECT DATE(DATE_SUB( NAME_CONST('_DATE',_binary'2011-02-20' COLLATE 'binary'), INTERVAL 1 WEEK )) AS wdt
             UNION ALL
             SELECT DATE(DATE_SUB( NAME_CONST('_DATE',_binary'2011-02-20' COLLATE 'binary'), INTERVAL 2 WEEK )) AS wdt
             UNION ALL
             SELECT DATE(DATE_SUB( NAME_CONST('_DATE',_binary'2011-02-20' COLLATE 'binary'), INTERVAL 3 WEEK )) AS wdt
             UNION ALL
             SELECT DATE(DATE_SUB( NAME_CONST('_DATE',_binary'2011-02-20' COLLATE 'binary'), INTERVAL 4 WEEK )) AS wdt
             ) days
          JOIN bbproduct b
            ON b.dt = days.wdt
   WHERE  ROUTENO =  NAME_CONST('_ROUTENO',3)
   ORDER  BY DT DESC,
             PRODNO ASC

Server version: 5.1.31-community

This simply shutdowns the MySQL server. What could be wrong?

share|improve this question
    
Please check your errorlog and print the lines. –  Stony Mar 27 '11 at 22:35
add comment

1 Answer

up vote 0 down vote accepted

The problem was that COLLATE 'binary' stuff.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.