I have a huge (38Gb after bzip2) Oracle EXP dump file. It contains one table. Such big dumps usually end up with an error, but in fact contain the full table.

Earlier I was importing these tables back into DB to check that they are ok. But it takes significant amount of time and resources.

Easy way to check that the file is fine - is to see how many rows in it. To compare with database (this table for example has 4 464 761 311 rows). But because export ended with an error, EXP did not show how many rows it dumped.

So how is it possible to see how many rows inside dump file without importing it?

Export was done with such parameters: exp direct=y recordlength=65535 and there are no visible sql commands in it, just the data.

  • Try use imp parameter show=y
    – ibre5041
    Apr 23, 2013 at 13:11
  • It does not show row count, only table name (but reads the whole file without errors). Apr 23, 2013 at 13:51
  • first you can try and look for the exp log. if you don't have it try opening the file with notepad or performing some search with regex for the table name in the file - if you have oracle client installed then in oracle/bin/perl you have batch file called search.bat. you can search inside files with it. maybe you can find it like that.
    – haki
    Apr 23, 2013 at 15:27
  • Exp ended with an error, so there is no row count in it. And file itself is binary, because done with direct export. I'll look into search.bat Apr 24, 2013 at 1:50
  • 1
    Even such big dumps should not usually end up with an error. What parameters do you user for export? What kind of error do you get from exp? Which Oracle Version do you use?
    – miracle173
    Sep 11, 2014 at 5:59

1 Answer 1

grep -a -A 5 METRICSTposttables table.dmp


METRICSTposttables actions
METRICSTPost-inst procedural actions
METRICSTDeferred analyze commands
TABLE "my_table"

Where 381 matched the export count:

. . exporting table          MY_TABLE        381 rows exported
  • 2
    Are you writing about the old exp/imp tools or about the newer expdp/impdp datapunp tools? And which version of Oracle?
    – miracle173
    Sep 11, 2014 at 5:50

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.