Joinutility seperatorLogin utility separator Infobright.com
   
 
outfile to mount folder can not read…
Posted: 22 July 2010 12:49 AM   Ignore ]  
Newbie
Rank
Total Posts:  42
Joined  2009-03-26

Hi all,

We have some problem with IB when using select outfile into mount folder, look like:

From Data warehouse server: 

SET @bh_dataformat 'txt_variable';
SELECT campaigndomainB.locationIDCOUNT(*)`click
FROM clicks0410 AS A  LEFT JOIN `ip2location_bh` AS B ON A.`ip` = B.`ip
WHERE timecreate BETWEEN '2010-07-21 12:00:00' AND '2010-07-21 12:09:59'
GROUP BY campaigndomainB.locationID 
ORDER BY campaign
domainB.locationID 
INTO OUTFILE 
'/vnfs/share129/mysqldata/103_click.out' 
FIELDS TERMINATED BY  ',' ENCLOSED BY 'NULL'


From MySQL client:

LOAD DATA INFILE '/data/share/mysqldata/103_click.out' 
INTO TABLE 102_temp_click_cam_ban_location FIELDS TERMINATED BY  ','

and when i ran the script load into table, the error occurred :

The file ‘/data/share/mysqldata/103_click.out’ must be in the database directory or be readable by all

while i set full permission for my MySQL account. And the local folder on MySQL client: ‘/data/share/mysqldata/’ was map with the share name: ’/vnfs/share129/mysqldata/’ on the remote Data warehouse.

Can anybody help me?

Thanks,
Thanh Nguyen.

Signature 

Thanh Nguyen

skype: thanhntvt
Website: Admicro.vn

Profile
 
Posted: 05 August 2010 10:16 AM   Ignore ]   [ # 1 ]  
Administrator
RankRankRank
Total Posts:  139
Joined  2008-08-18

Hi Thanh,

The user who run the mysql client needs to have read access to the data file. Make sure the user has at least read permission and run the load again.

regards,
Kethees.

Profile
 
Posted: 05 August 2010 10:57 AM   Ignore ]   [ # 2 ]  
Sr. Member
Avatar
RankRankRankRank
Total Posts:  505
Joined  2008-08-18

Hi,

Are you trying to load the file into a separate running Infobright instance?

Export and import are always done under the userid of the process running mysqld.

Please check that the user running the mysqld process (normally “mysql”) has the same userid on both machines. Otherwise the file will look like it belongs to a different user, and the second instance may not have permission to read it.

Geoffrey

Signature 
Profile