Tar extract file in particular directory excluding path stored in tar file

In winzip you have chk box 'Use Foldername', if you uncheck it, all files will be extracted to path given in Extract to:
Like winzip, do you have facility to extract files from tar file to a particular directory ignoring path stored in tar file.
os - linux,unix
regds

Using -C <new_directory> options creates
subdirectories under the new_directory as per path
stored in tar file
I just want to extract the files in the -C directory.
e.g.
# tar -tvf archive.tar
-rw-r----- oracle/oinstall 4669440 2006-11-30
13:23:02 /app/fmb/FORM1.fmb
-rw-r----- oracle/oinstall 200704 2006-11-29
10:18:25 /app/fmb/FORM2.fmb
when i give following command
tar -xvf archive.tar -C TargetDir
creats subdirectory app/fmb in this TargetDir and
then extract the files Forms1.fmb
TargetDir/app/fmb/FORM1.fmb
TargetDir/app/fmb/FORM2.fmb.
where as i want FORM1.fmb and FORM2.fmb in TargetDir
TargetDir/FORM1.fmb
TargetDir/FORM2.fmb
regdsit's include directory information when you run tar cvf.
you can do the following action
1. cd /app/fmb/
2. tar cvf archive.tar *
3. tar -xvf archive.tar -C TargetDir

Similar Messages

  • How to extract JAR file in particular directory

    Hi,
    I am extracting a JAR file(A.jar) in a Makefile
    Now the path of the Makefile is say /home/developer/
    The location of the JAR file is in /opt/tools/mk/A.jar
    I am extracting the jar file as:
    jar xvf /opt/tools/mk/A.jar
    This creates a directory named "A" under /home/developer, since the location of the Makefile is at /home/developer.
    Question) How do I unjar /opt/tools/mk/A.jar under /opt/tools/mk/ itself, irrespective of the location of the Makefile?
    thanks

    jar -?
    Usage: jar {ctxu}[vfm0Mi] [jar-file] [manifest-file] [-C dir] files ...
    Options:
        -c  create new archive
        -t  list table of contents for archive
        -x  extract named (or all) files from archive
        -u  update existing archive
        -v  generate verbose output on standard output
        -f  specify archive file name
        -m  include manifest information from specified manifest file
        -0  store only; use no ZIP compression
        -M  do not create a manifest file for the entries
        -i  generate index information for the specified jar files
        -C  change to the specified directory and include the following fileI'd say you may want to try the -C option

  • Ssis - move files from one directory to another and rename destination file if present

    Hello,
    How is it possible to move files from one directory to another directory and if the file already exists in destination directory then rename it?
    Thanks

    1. Use a foreach loop with file enumerator pointing to first directory.
    Inside loop have a ssis variable of type string to get filename (@[User::FileName])
    Choose option as Fully Qualified in loop
    2. Add another variable called @[User::DestFileName], set EvaluateAsExpression true for it and set expression like this
    REPLACE(@[User::FileName],<source directory path>,<destination directory path>)
    put actual paths in above expression in your case
    and another variable called @[User::RenameFileName], set EvaluateAsExpression true for it and set expression like this
    REPLACE(@[User::FileName],".","_old.")
    3. Create a boolean variable say @[User::FileEXists]
    4. Add a Script Task inside the loop and pass @DestFileName variable in ReadOnly mode and FileExists in ReadWrite mode
    Inside Script Task write code as per below
    http://blog.dbandbi.com/2013/11/13/check-file-exists-ssis/
    5. Add File System Task choose operation as Rename File, Select IsSourcePathVariable as true and select @[user::DestFileName] variable and IsDestinationPath variable as true and select @[user::RenameFileName] variable
    6. Choose ExpressionAndConstraint option for precedeence constraint from ScriptTask to above File System Task and choose constraint as OnSuccess and expression as
    @FileExists == True
    7. Add another File System task with operation as Move File Select IsSourcePathVariable as true and select @[user::FileName] variable and IsDestinationPath variable as true and select @[user::DestFileName] variable. Join Script Task as well as
    File System Task above to this task and choose constraint as OnSuccess and Multiple Constraint option as Or (dotted line)
    Then once executed it will work as per your requirement
    Please Mark This As Answer if it helps to solve the issue Visakh ---------------------------- http://visakhm.blogspot.com/ https://www.facebook.com/VmBlogs

  • File opened in external editor not stored with referenced files

    If I open a referenced raw file in an external editor (CS2) and work on the image adding layers etc., the image is not stored where I have all the other referenced files. It gets stored in the Aperture Library. Is there a way around this. I want to keep all my files together. This can be done in Lightroom, but I am trying to make Aperture work for my workflow.
    Thanks,
    gary
    mac book, G5   Mac OS X (10.4.7)  

    Well, here's the feedback I submitted to Apple:
    With the introduction of Aperture 1.5, you offered users the ability to manage their own libraries, and for Aperture to work with 'referenced' images. In fact, because of this very reason, many of us consumers decided to buy Aperture 1.5.
    Most of us photographers also use Adobe Photoshop routinely.
    But there is a huge problem/bug for us users who manage our own library (force Aperture to work with 'referenced' images) AND use Photoshop (or any external editor for that matter). When we open a file in an external editor via Aperture, Aperture creates a new 'master' for editing -- but does so in its own 'managed' library! When we save from Photoshop, the image remains in the 'managed' library! So now we have one 'master' in our own directory, and the externally-edited 'master' in Aperture's 'managed' library! This is very CONFUSING and renders external editing via Aperture USELESS... no one in their right mind would want one version of their image in an organized directory, and an edited version in Aperture's managed library (where it is difficult to find manually)! No, it makes much more sense to create the edited 'master' in the same location as the original 'master'!
    PLEASE fix this bug ASAP! Aperture already has a good method for automatically renaming files by adding (1) or (2) or (3) or so forth when it is relocating files and finds a file with the same file-name. The same logic can be applied when creating a new 'master' for external-editing: that is, it should just create another .tiff (or .psd, or what have you) file with the same name but with a (1) or (2) tagged on. For example, if my master image is \Pictures\Seattle\SpaceNeedle.tiff, then when I open this image in an external editor, Aperture should automatically make the file: \Pictures\Seattle\SpaceNeedle (1).tiff, and open that file in the external editor... rather than create SpaceNeedle.tiff in its own managed library where I can't even find it using Finder or Windows Explorer, etc.
    Many of us have this complaint (just search Apple discussions)... PLEASE rectify this problem ASAP as it is completely messing up our workflows by requiring us to manually save through the external editor and then having to manually remove every 'managed' file that Aperture makes. This is really a pain and seriously makes me want to switch to a different image management program... though I love Aperture thus far and would love to stick to it as I believe it is visionary and shaping the future of how photographers will manage their digital workflows!
    Many thanks in advance for your time!
    Best,
    Rishi

  • Get file list from directory(t.code: AL11).

    Hi Frnds,
    i need to get the list of file for particular directory from t.code AL11,
    is there any Function Module to display the list of File from  the directory in executable program,
    i have directory like '/home/im3/hrintf/processed/..... ' and now i need to get the list of file from that directory,
    the list is available in t.code AL11( standard program :RSWATCH0 ).
    pls suggest me with relevant FM or relevant logic.
    Thank you.
    Regards
    Ramesh M

    Hi 
       use this code i have checked its working fine
    Data:
          w_itab type table of  EPSFILI,
          w_dirnam type  EPSF-EPSDIRNAM.
          w_dirnam = 'C:\usr\sap\E6S\DVEBMGS00\work'.
    CALL FUNCTION 'EPS_GET_DIRECTORY_LISTING'
      EXPORTING
        dir_name                     = w_dirnam
    *   FILE_MASK                    = ' '
    * IMPORTING
    *   DIR_NAME                     =
    *   FILE_COUNTER                 =
    *   ERROR_COUNTER                =
      tables
        dir_list                     = w_itab
    * EXCEPTIONS
    *   INVALID_EPS_SUBDIR           = 1
    *   SAPGPARAM_FAILED             = 2
    *   BUILD_DIRECTORY_FAILED       = 3
    *   NO_AUTHORIZATION             = 4
    *   READ_DIRECTORY_FAILED        = 5
    *   TOO_MANY_READ_ERRORS         = 6
    *   EMPTY_DIRECTORY_LIST         = 7
    *   OTHERS                       = 8
    IF sy-subrc <> 0.
    * MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    *         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    write: 'test'.
    Thanks
    Viquar Iqbal

  • How to create a file in current directory

    hi,
    I want to create a file in a current directory, But when i written following
    code then it cannot create file, How i will create file in current directory?
    Is there anyone who can help me?what will be the solution of this problem?
    Please give me solution
    String dir=application.getRealPath("/");
         int count;
         String filename="sample.txt";
         out.println(dir+filename);
         FileOutputStream fout=new FileOutputStream(filename);
         PrintStream p;
         p=new PrintStream(fout);
         p.print("1");
         p.close();with regards
    Bina

    hi,
    my problem is that my path is ok...but when i open file in this directory then
    it cannot open a file, is there anyone who can do it? When a user save data in server from remote
    area then what will be path of my code? how i will solve it? please give me
    solution.
    with regards
    bina

  • How do I delete a file from a directory

    I want to delete the file I have finished processing in the c:\upload directory but the f.delete() command is not working. Am I using this command correctly?
    The f.delete() is after I copy the file to an archive directory.
    Program:
    import java.io.*;
    import java.util.*;
    import java.text.*;
    import java.sql.*;
    public class ReadSource {
    public static void main(String[] args) throws Exception {
         StringTokenizer st1;
              String val1, val3, val4, val5, val9, val10, val11, val12, val13, val14, val16;
              String val2, val6, val7, val8, val15, val17, val18, val19, val20;
              int cnt;
              File f = new File("C://upload" );
              FileWriter outFile = new FileWriter("C://RIFIS/log/logfile.txt", true);
              String filetext = "Starting RIFIS Upload";
              java.util.Date d = new java.util.Date();
              SimpleDateFormat form = new SimpleDateFormat("dd/MMM/yyyy hh:mm:ss");
              String dateString = form.format(d);
         try {
              Class.forName("oracle.jdbc.driver.OracleDriver").newInstance();
    Connection conn = DriverManager.getConnection("jdbc:oracle:thin:@xxxxx.xxxx.xxx:1521:xx","xxxxxx","xxxx");
                        Statement st = conn.createStatement();
                        outFile.write(System.getProperty("line.separator"));
                        outFile.write(filetext+" - "+dateString);
                        if (f.isDirectory())
                        { String [] s = f.list();
                        for (int i=0; i<s.length; i++)
                        { outFile.write(System.getProperty("line.separator"));
                             outFile.write("Found file - "+f+"/"+s);
              FileReader file = new FileReader(f+"/"+s[i]);
                                  File inputFile = new File(f+"/"+s[i]);
                                  File outputFile = new File("C://RIFIS/archive/"+s[i]);
                        BufferedReader buff = new BufferedReader(file);
                        boolean eof = false;
                        String val0="";
                        ResultSet rec = st.executeQuery("SELECT landings_hold_batch_seq.nextval FROM dual");
                        while(rec.next())
                        { val0 = rec.getString(1); }
                                  cnt=0;
                        while (!eof)
                        { String line = buff.readLine();
                             if (line == null)
                             { eof = true; }
                             else
                             { //System.out.println(line);
                                       cnt = cnt+1;
                                  st1 = new StringTokenizer(line,",");
                                       val1 = st1.nextToken();
                                       val2 = st1.nextToken();
                                       val3 = st1.nextToken();
                                       val4 = st1.nextToken();
                                       val5 = st1.nextToken();
                                       val6 = st1.nextToken();
                                       val7 = st1.nextToken();
                                       val8 = st1.nextToken();
                                       val9 = st1.nextToken();
                                       val10 = st1.nextToken();
                                       val11 = st1.nextToken();
                                       val12 = st1.nextToken();
                                       val13 = st1.nextToken();
                                       val14 = st1.nextToken();
                                       val15 = st1.nextToken();
                                       val16 = st1.nextToken();
                                       val17 = st1.nextToken();
                                            val18 = st1.nextToken();
                                            val19 = st1.nextToken();
                                            val20 = st1.nextToken();
                                       /*System.out.println("Token 0: " + val0);
                                  System.out.println("Token 1: " + val1);
                                  System.out.println("Token 2: " + val2);
                                       System.out.println("Token 3: " + val3);
                                       System.out.println("Token 4: " + val4);
                                       System.out.println("Token 5: " + val5);
                                       System.out.println("Token 6: " + val6);
                                       System.out.println("Token 7: " + val7);
                                       System.out.println("Token 8: " + val8);
                                       System.out.println("Token 9: " + val9);
                                       System.out.println("Token 10: " + val10);
                                       System.out.println("Token 11: " + val11);
                                       System.out.println("Token 12: " + val12);
                                       System.out.println("Token 13: " + val13);
                                       System.out.println("Token 14: " + val14);
                                       System.out.println("Token 15: " + val15);
                                       System.out.println("Token 16: " + val16);
                                       System.out.println("Token 17: " + val17);
                                            System.out.println("Token 18: " + val18);
                                            System.out.println("Token 19: " + val19);
                                            System.out.println("Token 20: " + val20);*/
                                       st.executeUpdate("INSERT INTO LANDINGS_HOLD (lh_id, lh_batch, supplier_dr_id, supplier_unique_id, supplier_dealer_id, supplier_cf_id, supplier_vessel_id, unload_year, unload_month, unload_day, state_code, county_code, port_code, itis_code, market, grade, reported_quantity, unit_measure, dollars, lh_loaddt, lh_loadlive, purch_year, purch_month, purch_day)" +
                        "VALUES (0,'"+val0+"','"+val1+"',"+val2+",'"+val3+"','"+val4+"','"+val5+"',"+val6+","+val7+","+val8+",'"+val9+"','"+val10+"','"+val11+"','"+val12+"','"+val13+"','"+val14+"',"+val15+",'"+val16+"',"+val17+",SYSDATE,NULL,"+val18+","+val19+","+val20+")");
                             FileReader in = new FileReader(inputFile);
                             FileWriter out = new FileWriter(outputFile);
    int c;
                             while ((c = in.read()) != -1)
                             { out.write((char)c); }
                             in.close();
                             out.close();
                             outFile.write(System.getProperty("line.separator"));
                             outFile.write("Number of records inserted - "+cnt);
                             outFile.write(System.getProperty("line.separator"));
                             outFile.write("Copied upload file to archive directory");
                             f.delete(); // delete the upload file
                             outFile.write(System.getProperty("line.separator"));
                             outFile.write(f+"/"+s[i]+" - Has been removed from upload directory");
                             buff.close();
                        outFile.write(System.getProperty("line.separator"));
                        outFile.write("Upload Complete...NO ERRORS");
                        outFile.write(System.getProperty("line.separator"));
                        outFile.write("*************************************************************");
                        outFile.write(System.getProperty("line.separator"));
                        //outFile.flush();
              //outFile.close();
                        conn.close();
                        else
                        { outFile.write("No files to process"); }
              catch(Exception e)
                   { outFile.write(System.getProperty("line.separator"));
                   outFile.write("ALERT....ALERT....ALERT");
                        outFile.write(System.getProperty("line.separator"));
                        outFile.write("Error Occurred in ReadSource.java - RIFIS Upload");
                        outFile.write(System.getProperty("line.separator"));
                   outFile.write("My Error: " + e);
                        outFile.write(System.getProperty("line.separator"));
                        outFile.write("*************************************************************");
                   outFile.flush();
              outFile.close();

    Gave it a try but file c:\upload\DS121002.csv did not go away. Here is the location of my delete command:
    st.executeUpdate("INSERT INTO LANDINGS_HOLD (lh_id, lh_batch, supplier_dr_id, supplier_unique_id, supplier_dealer_id, supplier_cf_id, supplier_vessel_id, unload_year, unload_month, unload_day, state_code, county_code, port_code, itis_code, market, grade, reported_quantity, unit_measure, dollars, lh_loaddt, lh_loadlive, purch_year, purch_month, purch_day)" +
                        "VALUES (0,'"+val0+"','"+val1+"',"+val2+",'"+val3+"','"+val4+"','"+val5+"',"+val6+","+val7+","+val8+",'"+val9+"','"+val10+"','"+val11+"','"+val12+"','"+val13+"','"+val14+"',"+val15+",'"+val16+"',"+val17+",SYSDATE,NULL,"+val18+","+val19+","+val20+")");
                             FileReader in = new FileReader(inputFile);
                             FileWriter out = new FileWriter(outputFile);
    int c;
                             while ((c = in.read()) != -1)
                             { out.write((char)c); }
                             in.close();
                             out.close();
                             inputFile.delete();
                             outFile.write(System.getProperty("line.separator"));
    ............

  • How to get all files in one directory

    Hi there,
    is there any way to get all the files in one directory?
    e.g. a method
    File[] getAllFiles(String directory){
    Thank you

    Just out of interest, which part of the File API was confusing?
    http://java.sun.com/j2se/1.5.0/docs/api/index.html
    If you look down the left-hand side, you'll see a frame listing "All File". If you select "File" from that list, it opens up the API in the right-hand frame. Quite near the top you'll find "listFiles".
    I only ask as this (and other questions easily answered by looking at the API) are frequently asked. Did you overlook it when you read the API or did you just not read it?
    I really want to know. I think there is scope to cater for that behaviour within this site. A nice API finder would be good; something more intelligent than the search function (which people use less frequently even than the API docs).

  • How to store file into a directory?

    i want to save the file(text file) into the directory which i have created using File object in the codes below. how do i do it?
    public void saveString(String filename, String string)
              //declare textfile to be null
              PrintWriter textFile = null;
              String line = null;
              try {
                   // writes to write.txt
                   textFile = new PrintWriter (new FileWriter(filename,true));
                   line = string;
                   // save string in textfile
                   textFile.println(line);
                   textFile.close();
                   // create a directory (to store (output).xml file)
              File fobj = new File("Testing");
              fobj.mkdir();
              catch (IOException e) {
                   System.out.println("Error in opening file");
                   System.exit(0);
         }

    create the directory first and then create the file u want liek this
    File f = new File (fobj,filename);
    and then open the fiel to write like this
    textFile = new PrintWriter (new FileWriter(f,true));
    regards
    rohan

  • How to  move a page file to another directory ?

    Hi,
    What I did to try to move a page to another directory is:
    1. copy the page file to another directory /public_html/mydirectory.
    2. modify the nevigation-rule in the faces-config.xml file so that the nevigation-rule
    point to the file in the new directory.
    But when run the page, there is an FacesException: Cannt instantiate backing_bean.
    How to move a page file to another directory?
    Thanks
    Stephen

    besides moving the file to the new directory, i'd advise you to find the name of your page in every file of your application (ultraedit does this very well) and append the directory wherever it appears otherwise you'd probably miss a reference and have a problem like you have.

  • Name of the file in a directory

    There is a file in a directory say C:\abcd
    I want to find the name of the file in that directory.
    There is only one file in that directory
    How to proceed with this

    Sarma,
    That was a little abrupt and rude of you. Oracle_Friend was only asking if anyone knew of a way to detect the existence of a file in a directory, not exactly asking the world of us. And for all you know he probably has already searched in documentation, but probably isn't quite sure what to look for.
    Remember : The manual has every damn thing that you want. We can only help you when you are stuck somewhere after having treid many options.a) sometimes people don't know what options to try so how can they have tried many options before posting on here.
    b) The manual doesn't have every damn thing that you want. I want a lot of money and some lunch cos I'm getting hungry, but it doesn't have that. On a serious note though, the manuals do miss things and can't possibly cater for everybody's business requirements.
    Chill out man, and help rather than hinder.

  • File in target directory?

    Hi Friends,
    The audit log says that the message is delivered but i cannot find the file in target directory.Does this indicate that the file is picked by the receiver system,if yes then once the file is picked the file is deleted from the target directory?
    Note-The "file construction mode" is set as create.
    Regards,
    Suresh.

    Hi Suresh
    Check for the SXMB_MONI as suggested above if you have success message.
    Moreover
    ,if yes then once the file is picked the file is deleted from the target directory?
    When the audit log says message delivered it will be delivered to target directory.
    Now if your scenario is file to file message can be deleted from source directory and not from target directory.
    Thanks
    Gaurav

  • Selecting all the files in a directory

    How would i select all the files in a directory, write the info of the files into a new file, and after the end of each file, make a New Line?

    hi zymus,
    check this code u will get the solution for ur problem..
    import java.io.*;
    public class files {
    public static void main(String[] args) {
    File f = new File("c://");// specify ur directory name here
    String[] n = f.list();
    System.out.println("ALL FILES.....");
                   if (n != null)
                             System.out.println("length = " + n.length);
    for (int i = 0; i < n.length; i++) { System.out.println("i = " + n[i]); }
                                  String[] n2 = f.list(new myJavaFileFilter());
                                  System.out.println("ALL JAVA FILES.....");
                                  if (n2 != null)
                                       System.out.println("length = " + n2.length);
    for (int i = 0; i < n2.length; i++)
         System.out.println("the files are::::::::: " + n2);
    class myJavaFileFilter implements FilenameFilter
    public boolean accept(File dir, String name)
         if (name.indexOf(".pdf") > 0)// give the file extension what u want
         return true;
    return false;

  • "Get Info" Reports an Incorrect Number of Files in a Directory

    I have a 17" MacBook Pro with OS X, 10.6.4. I've been relying upon Finder's "Get Info" to determine how many files a directory contains, and I never noticed any problems when using it. However, this afternoon I saw an anomaly with the actual number of files in a directory and what "Get Info" reported.
    I had previously created a new directory and moved 23 files to it. This morning I added three (3) more files to the directory, for a total of 26 files. This afternoon I added another five (5) files for a final total of 31 files in the directory. While Finder's "Get Info" showed that the directory had been updated this afternoon, it would not update the number of files it contains -- it still showed 26 files and the old total file size. I had to log out and log back in again for it to show me the correct file size and number of files.
    Is this normal behavior or was it a glitch in Finder? That is, can I rely upon Finder to tell me the correct number of files in a folder -- or not?
    Is there a way to force Finder to refresh itself? I looked around, but I did not see anything obvious, which is why I tried the logout/login method of refreshing it.
    Thanks,
    Bev in TX

    Welcome to Apple Discussions.
    This is a known issue in Finder. No fix I know of but a decent refresh here.
    -mj

  • Read all files in a directory

    I need to compare the date of creation of multiple files that are being created throughout the execution of the application, so that if the date and time of the file is equal to the current date and time, a led will light up, and if not, the file will be deleted.
    I've made a VI, but I'm getting an error and I don't know how to fix it.
    What I need is for the vi to read all the files in the directory and continue reading all the files as they are created in the directory. The weird thing about this error is that it only shows up when I run it without highlight execution.
    Attachments:
    Date & Time comparison.vi ‏10 KB

    Several things come to mind.
    0. What error do you get? The error code or description can be very useful in identifying a problem.
    1. When a VI runs OK with execution highlighting and fails without, that usually indicates a timing problem.
    2. The inner loop runs as fast as possible because there is nothing in there to slow it down. Put a Wait (ms) in there to slow things down a bit.
    3. The loops will never stop.  Do not create infinite loops by wiring False constants to the Stop if True terminal. The inner loop should probably be a for loop which will automatically stop after checking all files. The outer loop should have something to stop it - a front panel button, error, something.
    4. The timestamp has approximately 19 digits of precision in the fraction of a second portion. The resolution is limited by the clock in the computer. The implication is that you will almost never get exact equality.  You need to define "how close" is close enough. Perhaps within 1 second? Then modify the comparison function to determine whether the timestamps are within that limit.
    Lynn

Maybe you are looking for

  • ITunes 11.1.1 won't open even after OS update.  Is there something ELSE I'm missing?

    After I updated my iTunes to 11.1.1, it wouldn't open.  I found something on these forums that had a link to an OS update to fix the problem.  Downloading and installing the OS update took nearly 24 hours, and iTunes still won't open.  Is there somet

  • "Tax code AD for country IN has been deleted or incorrectly changed

    While doing the cash application process in the customer account, I am not able to clear invoice ,as it has discount value. We are getting an error message as "Tax code AD for country IN has been deleted or incorrectly changed" and we are not able to

  • Firefox shows my outdated e-mail address when forwarding

    I was trying to forward a petition to other people to sign, but Firefox shows an outdated e-mail address, which I can no longer access because I'm not paying for the service. I have tried overriding the old address with the new one, but it doesn't wo

  • A check on my settings to get the best out of them.

    Just checking base with you as you always offer me the best advice. Have just received my extra 2gb ram (yipee) which now takes me to the max 4gb allowed for my OS. Everything is working as it should so l'm wondering whether l'm now getting the best

  • Which operator is better: "minus" or "not in"

    I have 2 queries below which produce same result, see Case1 and Case2. My questions are: 1. When it is better to exclude records with MINUS operator, and when with "NOT IN" operator. Maybe we can theoretically answer that question? Maybe MINUS-operat