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!

How to Manage simulteanous execution for creating dynamic temorary tables

Discussion in 'SQL PL/SQL' started by arunkumar546, May 1, 2013.

  1. zargon

    zargon Community Moderator Forum Guru

    Messages:
    2,564
    Likes Received:
    362
    Trophy Points:
    1,430
    Location:
    Aurora, CO
    "So, in case it does, then i can strongly say that not [10/20/n] user's will be using simultaneously, but infact the DROP TABLE statement may (just may) have not worked."

    You cannot guarantee that these temp tables aren't being use simultaneously. If, indeed, the DROP TABLE didn't work it's likely due to the tables BEING USED by the various users who created them. It's also, in my opinion, to create multiple tables with completely different structures all named TEMPBOX of some form -- it would be better to name the tables TEMP_(source table name)[some number here] to better identify the base definition and to ensure that no one tries to use a temp table based on EMP, let's say, to try to store data from DEPT.

    EVeryone has ignored my examples which illustrate that you can have unique table names still based on the submitted base table. I suggest you look at them again.
     
  2. zargon

    zargon Community Moderator Forum Guru

    Messages:
    2,564
    Likes Received:
    362
    Trophy Points:
    1,430
    Location:
    Aurora, CO
    "*Now, i seriously don't like to spoon-feed. :p (I do in case of more complex issues, this is not)
    Come on !! Figure it out."

    This is NOT a proper way to address people in this forum nor is it a respectful way to provide assistance to those who need it. Not everyone is at the same level so allowances must be made. You certainly didn't start out knowing what you do now.

    The tone of this thread has taken a turn for the worse with such admonitions. This is a help forum, NOT a 'know-it-all' club. Treat people with the respect they deserve, especially when they clearly are not at the level of understanding where you believe yourself to be.
     
  3. ac.arijit

    ac.arijit Forum Advisor

    Messages:
    221
    Likes Received:
    23
    Trophy Points:
    280
    Location:
    Kolkata, India
    Hi Guyz[all],

    :D I believe in theory we can even construct a ladder to MOON. Lets talk about the practicality .. if after each processing the tables are dropped then there's a rarest of chances (unless pre-planned like 20-30 ppl together going 'ok lets execute it together') that all the tables in b/w the initiation point and tolerance values will exist simultaneously .. (if u still worrying about the traffic keep the tolerance to 50 or 100 .. whose restricting u). The way its designed, only one user will be allotted one table (until he's done with it).

    I apologize if i overburdened anything on anyone here. But the intention here was ...
    "*Now, i seriously don't like to spoon-feed. (I do in case of more complex issues, this is not)
    Come on !! Figure it out."


    Not to humiliate anyone, but make ppl realize that "Few things if u discover on your own, then it feels like heaven rather than gifted".
    Ppl don't usually value the things gifted to them neither do they know the actual value of it. Its only when u sweat it out for it u sincerely EARN it. (I can say this from my own experience, i wasn't spoon-feeded by anyone) .. And today whatever i know (may be not even 10% of the ocean) but i'm proud of myself for that coz i believe i've EARNED it.

    So, plz excuse me if i'm harsh on anyone but i just don't wanna dupe anyone by providing easy COPY PASTE solutions (which is not good for the individual's long term future).

    **I don't pretend, whatever i'm .. i'm right infront of u. No misleadings, no fake stuff and purely the person who i'm. Ppl knowing me can give a Character certificate for me, who don't .. i don't care what they say
     
  4. a_kamalraj

    a_kamalraj Forum Advisor

    Messages:
    122
    Likes Received:
    23
    Trophy Points:
    280
    Hi Ari,

    Its ok we are not feeling you Harsh.. Not every one in this forum will have the same wavelengh and grasping power as you have.
    so lets give them some good solution and make ppl in forum to ask more questions..

    so chill out. The solution you gave is good but i feel there is some point some issue can happen so i was asking you more.

    my Suggestion is to Use Sequence and create table dynamically using TEMP_TABLENAME_SEQUENCENUMBER can give some unique table name, so this can avoid multiuser trying the procedure same time.

    sorry i may be wrong also, i am just giving this as suggestion.

    Cheers
    Kamal
    (kamal.love@gmail.com)
     
  5. ac.arijit

    ac.arijit Forum Advisor

    Messages:
    221
    Likes Received:
    23
    Trophy Points:
    280
    Location:
    Kolkata, India
    Yeah !!

    Lets cool this off a bit ....

    And where the hell is the one in need for all these suggestions .. :D (As if in b/w all this mess, he's the one who escaped silently)
    Now its all upto him to choose or proceed whichever way he wants ... a lot of suggestions from Kamal, David & myself has been served. I don't think there's anything more to be told here. Now its the part of the initiator which remains .. :rolleyes: