1. Get rid of all advertisements and get unlimited access to documents by upgrading to Premium Membership. Upgrade to Premium Now and also get a Premium Badge!

Insert query runs too slow

Discussion in 'SQL PL/SQL' started by karthikeyanc2003, Aug 22, 2011.

  1. karthikeyanc2003

    karthikeyanc2003 Active Member

    Messages:
    24
    Likes Received:
    0
    Trophy Points:
    100
    Hi Guys,
    I have a select query with connecting 5 tables. I have a table (say R) to caputre the result for doing some modifications. That select query run in 30 seconds.but if I try to insert the output into R using

    insert into R
    as select
    xxx
    xxx
    xxx
    xx x
    xxx
    from
    a,
    b,
    c;

    It takes more than 4 hours to get insert. I dont have any index in R Table . And I tried all sort of hints . Nothing works. Since its not a one time process I have to resolve this issue.

    Please let me know how to resolve this issue.

    Thanks in advance
    Karthik
     
  2. zargon

    zargon Community Moderator Forum Guru

    Messages:
    2,351
    Likes Received:
    348
    Trophy Points:
    1,430
    Location:
    Aurora, CO
    Post the query and the explain plan; no one can help you without that information.
     
  3. rajavu

    rajavu Forum Guru

    Messages:
    815
    Likes Received:
    52
    Trophy Points:
    610
    Location:
    @ Bangalore , India
    Btw,

    Why there is no WHERE clause ?