Joinutility seperatorLogin utility separator Infobright.com
   
 
ERROR 1049 (42000): Unknown database ‘n’;’ during data load
Posted: 21 August 2010 09:21 PM   Ignore ]  
Newbie
Rank
Total Posts:  4
Joined  2010-08-17

These are the steps that I followed for data loading:

- use test;
- LOAD DATA INFILE ‘/test.csv’ INTO TABLE data FIELDS TERMINATED BY ‘|’ LINES TERMINATED BY ‘\r\n’;
- I get an error ERROR 1049 (42000): Unknown database ‘n’;’

After that, the connection to MySQL gets lost. Any further queries on that connection result in the following error:
- select * from data;
- No connection. Trying to reconnect…
ERROR 1049 (42000): Unknown database ‘n’;’
ERROR:
Can’t connect to the server

Although, it re-connects to the server after I ‘use test’ again:

- use test
- No connection. Trying to reconnect…
Connection id:  45
Current database: *** NONE ***

Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A

Database changed

Any help in this regard will be appreciated. Thanks!

Profile
 
Posted: 03 September 2010 05:10 PM   Ignore ]   [ # 1 ]  
Member
Avatar
RankRankRank
Total Posts:  191
Joined  2008-10-20

What operating system and version (ie. CentOS 5.5), are you using and what method did you use to install (source, rpm, windows)? Also, is there any messages in the bh.err that were issued just before it failed.

Signature 
Profile
 
Posted: 06 September 2010 09:21 PM   Ignore ]   [ # 2 ]  
Newbie
Rank
Total Posts:  4
Joined  2010-08-17

The OS that I am using is CentOS Release 5.5.

I installed using this rpm: http://www.infobright.org/Download/ICE/infobright-3.4.2-x86_64-ice.rpm

cd /usr/local/infobright
sudo rpm -ivh infobright-3.4.2-x86_64-ice.rpm

I don’t see any errors issued in bh.err (/usr/local/infobright-3.4.2-x86_64/data/bh.err) file just before the failure.

Profile
 
Posted: 07 September 2010 03:46 AM   Ignore ]   [ # 3 ]  
Super Duper Member
Avatar
RankRankRankRankRank
Total Posts:  916
Joined  2008-08-18

Hi !

It looks there is some mismatch in character encoding. You may type ‘use test’ , but apparently other character codes are transmitted to the server. Maybe, try verifying character encoding settings, see http://dev.mysql.com/doc/refman/5.1/en/charset-connection.html

Profile
 
Posted: 07 September 2010 12:03 PM   Ignore ]   [ # 4 ]  
Newbie
Rank
Total Posts:  4
Joined  2010-08-17

@Janusz Borkowski - Thanks a lot! I think it totally makes sense - it does seem to have something to do with the character set because of the weird characters that it error-ed out with.

Before I changed anything, I wanted to re-produce the same error. Unfortunately (or fortunately smile ), the load worked completely fine this time! The only thing that has changed ever since I tried the last time is that the machine was rebooted.

Seems like this issue is resolved but I am sorry I can’t shed any light on how this issue got resolved. :(

Profile