Re: [R] filehash

From: Roger D. Peng <rpeng_at_jhsph.edu>
Date: Mon, 17 Mar 2008 09:16:47 -0400

Yes, the file will be created in the current working directory and is probably the reason for the error in 'dbInit'. This is a bit of a dumbo on my part---thanks for copying me.

-roger

Prof Brian Ripley wrote:
> I suspect you have a file permission problem, and noticed filehash has
> some bugs which would mask this. E.g. it does
>
> createDB1 <- function(dbName) {
> if(!hasWorkingFtell())
> stop("need working 'ftell()' to use 'DB1' format")
> if(!file.exists(dbName))
> file.create(dbName)
> else
> message(gettextf("database '%s' already exists", dbName))
> TRUE
> }
>
> and so fails to check that file.create succeeded, and calls message() on
> an already translated message without 'domain=NA'. (It also calls
> dir.create without checking the result.)
>
> As far as I can see filehash will try to create a file in the current
> working directory. Did you set up the shortcut as dscribed in the
> rw-FAQ so that the working directory was owned by you?
>
> On Fri, 14 Mar 2008, Davood Tofighi wrote:
>

>> Hello,
>>
>> I'm using filehash on the windows XP and it has been working fine with 
>> the
>> newest R version 2.6.2. However, on the windows vista, when I ran the 
>> same
>> code, I got the following error:
>>
>>> dbCreate("simdb")    #create simdb database
>> [1] TRUE
>>> db<-dbInit("simdb")  #initiate an object of database
>> Error in sprintf(gettext(fmt, domain = domain), ...) :
>>  object "datafile" not found
>>>
>>
>> Thanks,
>> Davood
>>
>>     [[alternative HTML version deleted]]
>>
>> ______________________________________________
>> R-help_at_r-project.org mailing list
>> https://stat.ethz.ch/mailman/listinfo/r-help
>> PLEASE do read the posting guide 
>> http://www.R-project.org/posting-guide.html
>> and provide commented, minimal, self-contained, reproducible code.
>>

>
-- 
Roger D. Peng  |  http://www.biostat.jhsph.edu/~rpeng/

______________________________________________
R-help_at_r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
Received on Mon 17 Mar 2008 - 13:22:47 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Mon 17 Mar 2008 - 15:30:22 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.

list of date sections of archive