This is a discussion on Using the zip/unzip command given with Oracle in Unix, withoutdirectory names within the Oracle Miscellaneous forums, part of the Oracle Database category; --> Hi, I am trying to compress using the zip/unzip command given with Oracle in Unix. The objective is to ...
| |||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| ||||
| Hi, I am trying to compress using the zip/unzip command given with Oracle in Unix. The objective is to create a zip file, for e.g. for the following, from any directory other than tt, without the directory name. tt/f1.txt tt/f2.txt into tt.zip. Say I'm using this command: zip -r tt.zip tt/ In other words, I want the zip file to have only f1.txt and f2.txt. I am not able to compress without the directory names. I have seen all the options (shown with -h option) given with zip and also tried to see if unzip has any option to extract without the directory names. I could not find. Can anyone please advise. If there is any other Unix compression commands, to achieve this (.zip format). Thanks, Vijay |
| |||
| On Tue, 2 Sep 2008 02:19:10 -0700 (PDT), compuneo <compuneo@gmail.com> wrote: >Hi, > >I am trying to compress using the zip/unzip command given with Oracle >in Unix. > >The objective is to create a zip file, for e.g. for the following, >from any directory other than tt, without the directory name. > >tt/f1.txt >tt/f2.txt > >into tt.zip. Say I'm using this command: zip -r tt.zip tt/ > >In other words, I want the zip file to have only f1.txt and f2.txt. >I am not able to compress without the directory names. > >I have seen all the options (shown with -h option) given with zip and >also tried to see if unzip has any option to extract without the >directory names. I could not find. > >Can anyone please advise. If there is any other Unix compression >commands, to achieve this (.zip format). > >Thanks, >Vijay Please cd into the directory at hand. As far as I know this is the only method to drop the directory names. This applies to tar and other utilities too. -- Sybrand Bakker Senior Oracle DBA |
| ||||
| Thanks for your response. Actually, there's an option with the zip command, -j, which helps to drop the directory names as I was expecting. I overlooked this option earlier. Now, it's fine. On Sep 2, 12:53*pm, sybra...@hccnet.nl wrote: > On Tue, 2 Sep 2008 02:19:10 -0700 (PDT), compuneo <compu...@gmail.com> > wrote: > > > > > > >Hi, > > >I am trying to compress using the zip/unzip command given with Oracle > >in Unix. > > >The objective is to create a zip file, for e.g. for the following, > >from any directory other than tt, without the directory name. > > >tt/f1.txt > >tt/f2.txt > > >into tt.zip. *Say I'm using this command: zip -r tt.zip tt/ > > >In other words, I want the zip file to have only f1.txt and f2.txt. > >I am not able to compress without the directory names. > > >I have seen all the options (shown with -h option) given with zip and > >also tried to see if unzip has any option to extract without the > >directory names. *I could not find. > > >Can anyone please advise. *If there is any other Unix compression > >commands, to achieve this (.zip format). > > >Thanks, > >Vijay > > Please cd into the directory at hand. > As far as I know this is the only method to drop the directory names. > This applies to tar and other utilities too. > > -- > Sybrand Bakker > Senior Oracle DBA- Hide quoted text - > > - Show quoted text - |
| Thread Tools | |
| Display Modes | |
|
|
| ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| [UNIX] HP Tru64 UNIX Running the ps command, Local Disclosure of Sensitive Information | SecuriTeam | Securiteam | 0 | 07-02-2008 04:18 PM |
| Re: Library names on Unix | Dave Page | pgsql Interfaces odbc | 0 | 04-16-2008 02:43 AM |
| Library names on Unix | Peter Eisentraut | pgsql Interfaces odbc | 0 | 04-16-2008 02:43 AM |
| how to unzip a file and view it in a single command line? | wei.li.1@gmail.com | comp.unix.solaris | 2 | 01-12-2008 05:55 AM |
| How to unzip and install the files in AIX 5.3 Unix Server | afeena83 | AIX Operating System | 1 | 01-05-2008 12:15 PM |