Page 1 of 1

Reading data from an unknown file

Posted: Tue Jun 14, 2005 3:52 am
by mikebr
I guess this is the right place for this.

I want to extract some information contained in a file but I can't seem to read the contents. I have tried using a text editor 'Mac BBEdit' which can open most files and databases but BBEdit shows no contents. I also ran fopen($file,"r") on it to try and read it but nothing. The file is 1.7mb in size and has no dot notation.

Anyone any ideas of what best options I would have on how I might do this?

Thanks

Posted: Tue Jun 14, 2005 6:12 am
by timvw
- Do you have sufficient rights to read the file?
- On a *nix machine there is a program "file" which can tell you what the file contains (Well, it's pretty good at estimating anyway)

Posted: Tue Jun 14, 2005 7:02 am
by mikebr
I am working on a Mac 'Unix base' and in the permissions info I own the file and have read write access.

Don't know much about unix but I tried reading the file from a 'OSX' terminal window using 'sudo /Users/mb/Desktop/sp_database', got nothing there either.

Thanks

Posted: Tue Jun 14, 2005 7:24 am
by mikebr
Sorry I meant 'pico /Users/mb/Desktop/sp_database'.