Talk About Network



Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Programming > Awk > incrementing nu...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 1 of 16 Topic 2179 of 2234
Post > Topic >>

incrementing numbers

by tcdrake <rymills@[EMAIL PROTECTED] > Mar 6, 2008 at 11:25 AM

We recieve zip files in the following format...yyyymmdd-#.zip where #
starts at 1 and increments up to 79. I need to unzip these files into
seperate folders based on a specified folder name. Here is what I
have....


BEGIN{
timetab(z,time() - 86400)

printf("c:\\progra~1\\winzip\\wzunzip.exe -e -s %s%02s%02s-.zip c:\
\test\\1\n",z["YEAR"],z["MONTH"],z["DAY"])  > "test.bat"
printf("c:\\progra~1\\winzip\\wzunzip.exe -e -s %s%02s%02s-.zip c:\
\test\\2\n",z["YEAR"],z["MONTH"],z["DAY"])  > "test.bat"

}

As you can see I have the date portion down its the # after the dash
in the zip name I don't know how to do. I'm pretty sure I need the ++
but not sure how.

thanks.




 16 Posts in Topic:
incrementing numbers
tcdrake <rymills@[EMAI  2008-03-06 11:25:29 
Re: incrementing numbers
tcdrake <rymills@[EMAI  2008-03-06 12:44:23 
Re: incrementing numbers
Ted Davis <tdavis@[EMA  2008-03-06 15:47:19 
Re: incrementing numbers
tcdrake <rymills@[EMAI  2008-03-07 06:01:26 
Re: incrementing numbers
tcdrake <rymills@[EMAI  2008-03-07 07:25:05 
Re: incrementing numbers
tcdrake <rymills@[EMAI  2008-03-07 07:32:06 
Re: incrementing numbers
Ted Davis <tdavis@[EMA  2008-03-07 15:04:41 
Re: incrementing numbers
Ted Davis <tdavis@[EMA  2008-03-07 19:58:45 
Re: incrementing numbers
tcdrake <rymills@[EMAI  2008-03-07 07:41:51 
Re: incrementing numbers
tcdrake <rymills@[EMAI  2008-03-07 13:06:05 
Re: incrementing numbers
tcdrake <rymills@[EMAI  2008-03-10 07:22:41 
Re: incrementing numbers
tcdrake <rymills@[EMAI  2008-03-12 12:46:29 
Re: incrementing numbers
Ted Davis <tdavis@[EMA  2008-03-12 15:04:55 
Re: incrementing numbers
tcdrake <rymills@[EMAI  2008-03-12 13:23:37 
Re: incrementing numbers
Ted Davis <tdavis@[EMA  2008-03-12 20:03:31 
Re: incrementing numbers
tcdrake <rymills@[EMAI  2008-03-26 06:48:51 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Mon May 12 4:00:52 CDT 2008.