Bug #2455 select into outfile crashing mysql
Submitted: 20 Jan 2004 5:15 Modified: 20 Jan 2004 13:44
Reporter: Antti Kurenniemi Email Updates:
Status: Can't repeat Impact on me:
None 
Category:MySQL Server: Command-line Clients Severity:S2 (Serious)
Version:4.1.1a-alpha-nt OS:Windows (Windows 2000 Professional)
Assigned to: Dean Ellis CPU Architecture:Any

[20 Jan 2004 5:15] Antti Kurenniemi
Description:
When using SELECT INTO OUTFILE with a field name that is invalid, MySQL server crashed. It threw an exception, but I was too hasty to write it down and did not succeed in repeating the error.

The whole syntax was: 
  
  select name into outfile "c:/tst.txt" fields terminated by '\t' lines terminated by '\r\n' from cust;

...where "name" field does not exist in table "cust". After restarting the MySQL server, the same statement gives an error "1054 (42S22): unknown column 'name' in 'field list'" without crashing, as expected.

How to repeat:
Unfortunately I was unable to repeat it. I tried this right after importing a text file into this same table (cust), which seemed to go alright.

Suggested fix:
Since it was an access violation, could it perhaps be an un-initialized object?
[20 Jan 2004 13:44] Dean Ellis
I cannot repeat it, either.  If you can identify a specific test case which demonstrates the problem, please update this report with it.