Home | About | Sematext search-lucene.com search-hadoop.com
 Search Hadoop and all its subprojects:

Switch to Plain View
Pig, mail # user - how can I delete a file in pig only after checking if the file exists?


+
Sheng Guo 2012-07-23, 09:12
Copy link to this message
-
Re: how can I delete a file in pig only after checking if the file exists?
Thejas Nair 2012-07-23, 20:21
Use - rmf filename

-Thejas

On 7/23/12 2:12 AM, Sheng Guo wrote:
> Hi all,
>
> Sorry to bother you guys, I used rm FILE_PATH to delete the file in pig
> script, but sometimes if the file does not exist, or I am not sure if it
> exists, this statement will give some error when I run it.
>
> So is there any method so that I can delete a file in pig script only after
> checking the file exists?
>
> Thanks!
>
+
Ruslan Al-Fakikh 2012-07-23, 12:50