exp query
DBAsupport.com Forums - Powered by vBulletin
Page 1 of 2 12 LastLast
Results 1 to 10 of 14

Thread: exp query

  1. #1
    31006558 Guest

    Talking exp query

    My problem: A client of mine deleted a crucial amount of data on their DB,with no backup to recover.(I only do the performance tuning on their DB!!). Luckely I made a dump of the data on my DB for development purposes before the Troll did it.

    Q:Is it possible to exp more than one query(subset of tables) at a time...100?
    I have never tried it this way.

    Thanks for help,sarcasm wellcome.

  2. #2
    Join Date
    Jan 2001
    Posts
    3,131
    Sarcasm, well you have come to the right place!

    I'm not sure if you can use multiple queries in an export, what are you trying to do anyway?
    From your description it seems like you would want to import from the old export you have no?

    MH
    I remember when this place was cool.

  3. #3
    31006558 Guest
    Yip

    Want to create an exp from their old imp that is on my DB.

    My querY looks something like this:

    select'SELECT *FROM TABLE '||OWNER||'.'||TABLE_NAME||' WHERE NETWORK_ID<>8'
    from sys.all_tab_columns
    where owner in ('IAMM','IAMM_LOAD','IAMM_AUDIT')
    AND COLUMN_NAME IN('NETWORK_ID','SECTION_ID')
    ORDER BY owner,TABLE_NAME;

    This gives a return of appr 100 queries where the deleted data is hidden on my DB which i have to exp

  4. #4
    Join Date
    Nov 2000
    Location
    Pittsburgh, PA
    Posts
    4,003
    You should do an export of the current database. Then take your import and bring it into another schema. You can then try to reconstruct the data through queries. If feel rather silly saying this, since it is too late, but you should help your customer come up with a backup strategy. It is incomprehensible that anyone would use a database and not back it up. That tells me that the data in the database is not important.

  5. #5
    Join Date
    May 2002
    Posts
    2,645
    Interesting question. Almost. Export is a logical backup, you export various objects, not data returned from a query. You can specify the tables - and you have to specify them - not specify/return them as a result of a query.

    exp via command line input or parameter file - how would/could you use a select statement as a parameter?

  6. #6
    31006558 Guest
    1.The data is very important and expensive to gather.The Troll that deleted the data did not tell anyone. So a backup was made of the missing data.(He still works for the company). Because of this incident i'm currently working on a SECURITY plan to "uplift" their internal use of data.-(More work for me!!)

    2.I will try your suggestion.It seems like an easier solution.

    Thanx

  7. #7
    Join Date
    Jan 2001
    Posts
    3,131
    Originally posted by stecal
    Interesting question. Almost. Export is a logical backup, you export various objects, not data returned from a query. You can specify the tables - and you have to specify them - not specify/return them as a result of a query.

    exp via command line input or parameter file - how would/could you use a select statement as a parameter?
    I thought he wanted to add a query into the export parfile, as per 8i, I'm not sure if there is a limit on this parameter.
    Whoops, I just found this...


    Restrictions
    The parameter QUERY cannot be specified for full, user, or transportable tablespace mode exports.

    The parameter QUERY must be applicable to all specified tables.

    The parameter QUERY cannot be specified in a direct path export (DIRECT=Y)

    The parameter QUERY cannot be specified for tables with inner nested tables.

    You will not be able to determine from the contents of the export file whether the data is the result of a QUERY export.

    MH
    I remember when this place was cool.

  8. #8
    31006558 Guest
    Rem--Export is a logical backup, you export various objects, not data Rem--returned from a query.

    Steven, I see your point, but exp a query is an option as described in the exp help file. It does not say you can not use a select statement. Why use a query then?

    I resently used a select query in MS SQLserver exp and it worked perfectly, why shouldn't it work in Oracle?

  9. #9
    Join Date
    May 2002
    Posts
    2,645
    Well, if you never try to answer questions here, you never run the risk of having to eat crow. Should have read further into the parameters for export; query parameter sure looks familar now (but have never used it). You know what you know, and what you don't know sometimes shows. My bad.

  10. #10
    31006558 Guest
    Hanky

    Thanx for the info.

    I will try it tomorrow.(Its 22h20 and i'm still at the damn office!!)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width