Compact is wrong. That's for enabling and disabling NTFS file compression of a file on disk, not for creating and extracting *.zip files.
The easiest ways are using java:
java xf file.zip
or some other third party tool (7zip, pkzip, info-zip, etc) that has a decent CLI tool.
If you must use the built in windows zip tool, you can do it using this Visual Basic like this:
http://stackoverflow.com/questions/2...ip-file-with-vbscriptBecause windows doesn't actually clean up the temp folder automatically, and because the script referenced can't handle temp folder names greater than 99, you'll only be able to run it 99 times before it fails. So you'll want to modify the script to delete it's temp folder after it extracts.
(ProTip: if you want to read the Expert's Exchange linked in the Stack Overflow, paste the URL into Google and click from there, then scroll WAY down to the bottom.)