Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number

Re: remove files from the V volume on windows server 2008

by Crackers2 (Parson)
on Aug 22, 2012 at 00:50 UTC ( #988915=note: print w/replies, xml ) Need Help??

in reply to remove files from the V volume on windows server 2008

Two things. First:

if ( $V_RoundedTotalNumberOfFreeGigabytes < 3.5 && $V_RoundedTotalNumberOfFreeGigabytes == 3.5) {

seems wrong. It can't be both < 3.5 and == 3.5 at the same time. Maybe you want to simply say <= 3.5 ?

Second, readdir returns just the filename. So on the unlink you probably want

unlink $dir_to_process . "/" . $file

Replies are listed 'Best First'.
Re^2: remove files from the V volume on windows server 2008
by fnicholas (Initiate) on Aug 22, 2012 at 13:19 UTC
    Thanks for your help! I appreciate it.

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://988915]
[Corion]: Meh. I have a very simple mechanism to scrape+track prices, and even to send me mail if something changes (via cron), but SQLite doesn't support window functions, so my simple SQL to determine a price change won't work :-( Maybe I should store the DB ...
[Corion]: ... in Pg, but that would mean that I'd have to deal with credentials and stuff :)
[Corion]: In fact, the whole thing is just four simple programs, one App::scrape, another being DBIx::RunSQL, and one some glue to convert a JSON object into an SQL INSERT statement (+DBI connect/execute), so it would be an incredibly simple solution...
[Corion]: ... but that simplicity falls down due to SQLite letting me down and me being too lazy to move to a real DB. Maybe DBD::CSV can handle window functions...
[hippo]: Pg has the "trust" mechanism if you don't fancy using credentials for a trivial db.
[Corion]: hippo: Oooh, that sounds quite nice - let me read the documentation on that :)

How do I use this? | Other CB clients
Other Users?
Others wandering the Monastery: (7)
As of 2018-02-23 15:05 GMT
Find Nodes?
    Voting Booth?
    When it is dark outside I am happiest to see ...

    Results (302 votes). Check out past polls.