The Oracle temporary Table is not temporary? #oracle #global #temp #table


#

Join the world’s largest interactive community dedicated to Oracle technologies.

That is why it is called a “GLOBAL Temporary Table” !

The Table Definition is visible to all sessions in that schema.
The data in the table is NOT visible.

Thus, each session does not need to execute DDL to “create” the table — it is created only once. DDL introduces overheads to parsing.
However, each session is still free to see it’s own private data without worrying about other sessions !

Hemant K Chitale

That is actually true. Temporary table are global and can be seen from all sessions. But one session cannot see the data that was inserted in another session. The data is bound to a session.

1 пользователь считает эту информацию полезной

    • Мне нравится Показать отметки Мне нравится (0) (0)
    • Действия

    Thanks for Hemant and DimaK’s replies.
    The temp table will exists forever.
    and also seen when you run
    select * from user_objects where object_type = ‘TABLE’

    Therefore, I think the table is not temporary, it is just a special table.
    Moreover, some developers create some intermediary tables for calculation, as a helper table etc.
    He don’t want such table be a part of the application.

    (in Sql server, when you put the ‘#’ in front of the table name,
    it becomes a temporary table, and also disappears when the session close,
    it is more meaningful)

    Edited by: Dever on 2011/2/22 下午 11:37

    Edited by: Dever on 2011/2/22 下午 11:48

    Basically the word TEMPORARY is used in the context of DATA and not TABLE when it comes to Global Temporary Table.

    The Data in the GTB is temporary. You can make the data go away at the end of a transaction or when you end a session. And also the Data in GTB is private to that particular session and is not visible to others.

    I have seen people in the past confusing GTB wiht the Temporary table concept in SQL Server. GTB is entirely different.

    Hello,
    Moreover, some developers create some intermediary tables for calculation, as a helper table etc.
    He don’t want such table be a part of the application. Why not. When you create the table at runtime you cannot use precompiled statements to access this table. You need to do everything with EXECUTE IMMEDIATE and you will get syntax errors only at runtime, the error messages are less meaningful and its harder to debug.

    If he creates them at runtime they are part of the application, even if they are deleted afterwards.

    Edited by: Marwim on 23.02.2011 09:58

    Dever wrote:
    Thanks for Hemant and DimaK’s replies.
    The temp table will exists forever.
    and also seen when you run
    select * from user_objects where object_type = ‘TABLE’

    Therefore, I think the table is not temporary, it is just a special table. No, it’s your interpretation, as others have already mentioned. Global Temporary Tables are tables that allow for the “temporary” storage of data (and specific to a session), but the table itself is pre-defined and permanent, which is an advantage as it allows application code to be developed against the table and any queries used against that table to be parsed by the PL/SQL parser and verified as valid, before the application goes live; certainly something that wouldn’t be done if the table was created in a temporary manner using dynamic dml at run-time.
    Moreover, some developers create some intermediary tables for calculation, as a helper table etc.
    He don’t want such table be a part of the application. Then don’t include them in the final application. Developers shouldn’t be developing in the ‘live’ environment, so those tables will only ever exist as part of the development environment until such a time the developer has finished with them and drops the table.
    (in Sql server, when you put the ‘#’ in front of the table name,
    it becomes a temporary table, and also disappears when the session close,
    it is more meaningful) That’s a matter of opinion. You are trying to compare two completely different technologies. SQL Server Temporary Tables are not Oracle Global Temporary Tables. You cannot say that SQL Servers Temporary Tables are somehow “better” or “more meaningful” than Oracle’s just because they work differently.

    A temporary table created dynamically at run time will prevent any code that uses that table from being parsed and validated at compile time, meaning that any issues or errors that could potentially be spotted (as with Oracle’s GTT’s) would not be until run-time, and sometimes only under certain conditions, thus potentially meaning that you’ve make you application live, and an issue may arise at some seemingly random time (usually during something critical as we’re all familiar with) and then you have no idea where to look for the issue because the table has disappeared.

    Good “design” of an application means that the tables and structures needed by the application are known before any coding takes place. That being the case, there is no need for tables to be created at run-time. Yes, there is a need to have data that is stored specifically for a session that doesn’t conflict with other sessions and that is where Oracle’s GTT’s work just fine. In Oracle, you would have one GTT, which can be used by as many users as need it, without conflict, yet in SQL Server, to achieve the same, you would get multiple temporary tables being created (and re-created) all the time, impacting on the data dictionary (and probably having to have indexes etc. re-created too (I’m not sure how SQL Server does it)).

    I’m familiar with the way SQL Server using Temporary Tables, as Ingres does a similar thing and I’m an old-skool Ingres developer, but they were always problematic. It was actually a relief to find how Oracle lets you deal with temporary data without all the need to create temporary tables at run-time.

    (in Sql server, when you put the ‘#’ in front of the table name,
    it becomes a temporary table, and also disappears when the session close,
    it is more meaningful) No, it is not. Those temp tables in SQL-Server exists because of a fundamental flaw in SQL-Server relating to data concurrency and data (and read) consistency. One (common) way to deal with this flaw, is to create a local copy of that data for the session to work with. This local data copy does not have to deal with concurrency issues. And it provides a consistent snapshot of the “+truth+” in the database, at a specific point in time.

    Unfortunately, many SQL-Server developers are oblivious of how SQL-Server deal with consistency and concurrency. To them, a temp table is just another tool that is often used as it is “easy” to simply use The Large Hammer on a problem. Does not matter whether it actually requires a screwdriver or a drill or a wrench.

    Oracle does not work like that. Does not suffer from the same issues that SQL-Server does. Problems are typically solved differently.

    So it is a major mistake on your part to think Oracle is like SQL-Server and you can use the same hacked/large hammer approach in Oracle PL/SQL and SQL. Oracle does an exceedingly poor imitation of SQL-Server.


    Antique Fine Furniture Restoration Darius #antique #furniture #restoration #nyc, #sculpture #repair, #wood #fix, #cleaning #antique, #conservation #furniture, #english #fix, #oriental #finishing, #french #polish, #est #manhattan, #uptown #antique, #park #ave #service, #antique #restoration10028, #10075, #10021,10023, #10024, #10065, #restoration #10128, #antique,, #furniture #repair, #sculpture #repair, #art #restoration, #wood #restoration, #bronze #sculptures,18th #century, #alabaster, #frame, #asian, #art #restore, #auction, #bed, #board, #best, #bwazery, #cabinet, #chair, #polish, #dining #table, #chandelier, #chippendale, #cleaning, #conservation, #desk, #dresser, #english, #figure, #fine, #wood, #gold, #french #polish, #renovation, #service, #upper #east #side, #insured, #interior, #mahogany, #park #ave, #professional, #boca #raton, #elite, #high, #jupiter, #statue, #treatment, #water #damage, #art #conservator, #biedermeier, #home, #buazery, #new #york, #chippendale, #christie, #distress, #empire, #china, #commode, #fix, #exclusive, #expert, #france, #shellac, #polish, #doyle, #westchester, #before #and #after, #jupiter, #palm #beach, #sotheby�s, #georgian #museum,orient, #quality, #old, #regency, #renaissance, #renovate, #furniture #restore,antique #finishing, #frame,gilding, #fiveave,park #ave,museum #quality, #art #restore, #upper #east #side, #specialization: #english #pillar #dining #table,


    My client. * The family of Albert EINSTEIN
    * MADONNA (singer) Louise Veronica Ciccone
    * Mr.Tommy HILFIGER;
    * 1040 5Ave. Maurice Templesman (Jacqueline KENNEDY Onassis and her maid Marie) .
    Andrea Bocelli

    * Margaux HEMINGWAY * Anne Ascher Beverly Hills (interior decorator for the WHITE HOUSE) * Private residence in Greenwich, CN owner of Empire State Building * Taylor Mead son of Andy WARHOL * G.H. Chakkour (Museum of Modern Art) * BANK of France –Credit Agricole * QUEEN Victoria’s daughter s lute repair * Philanthropists Mr. Carter Burden, the * Earle Vandekar family * Mr. Geller * Elia KAZAN Oscar * Jerome HELMET Oscar winning *Canadian and Swedish consulates, NYC * Charles Gibson (Channel 7 News) * Tom Britt Interior designers

    *Antiques – Restoration Department.1089 Madison AvenueNew York, NY 10028
    *Art Antique Restore. 4500 N Flagler Dr, West Palm Beach, FL

    *Greenwich Oriental Art, 7 East Putnam Avenue, Greenwich, CT *Ann Ascher Interiors Inc Beverly Hills, Los Angeles, CA * Guild Antiques Restoration Department 1095 Madison Ave, New York, NY *Eagle Antiques 1097 Madison Ave New York, NY 10028


    Loan Amortization Calculator – A Free Online Loan Amortization Calculator With Data Table #firestone #auto


    #auto loan amortization
    #

    Your suggestion is on its way!

    Loan Amortization Calculator

    A Loan Amortization Calculator For Any Purpose

    The loan amortization calculator is intended to show you how your loan will work month-by-month, including information about:

    • Your monthly payment
    • How much of your loan gets paid off each month
    • How much of your monthly payment goes to interest each month
    • How much you’ll owe on your loan at any point in time

    The loan amortization calculator includes an amortization table for your reference.

    For more details on the results of your calculation, read How Amortization Works. If you want to dig into the numbers even more deeply, find out Calculate Loans on Your Own.

    Instructions

    Fill in the required information related to your loan, and click the Calculate button. A table will appear below the loan amortization calculator with the information described above.

    You may want to plug the loan amortization calculator’s output into Excel or another spreadsheet program so that you can work with the numbers even further (for example, you might calculate how much interest you’ll pay over the first 10 months of your loan). The best way to do this is to select the data starting outside (above, for example) of the table. Or, use a pre-built Excel loan calculator template.

    The loan amortization calculator can be used for your auto loans, home loans, or any other straight-line amortized loans. It does not work with credit card loans or other revolving loans.


    Car Payment Calculator – A Free Online Calculator With Amortization Table #bad #credit #auto #refinance


    #auto loans calculator
    #

    Your suggestion is on its way!

    Car Payment Calculator

    Calculate Car Payments and Interest Costs

    Need to know how much it will cost to buy a new auto? The car payment calculator will show you what your monthly payments will be if you borrow money to purchase an auto. What s more, you ll see what the vehicle truly costs after you account for the interest you ll pay on the loan.

    About.com s free car payment calculator includes an amortization table so you can understand how your loan works. This is a set of numbers that breaks down all of the details of your auto loan for every month, including:

    • Each month s payment
    • How much of each payment goes towards reducing your loan balance
    • How much of each payment is your interest cost
    • Total amount remaining on your loan
    • Total amount of interest paid up to any point

    If you want, you can even copy this information into a spreadsheet to further slice and dice the numbers. Tip: if you re using Excel, you ll have to select everything, and then use Data — Text to Columns to split the numbers up into separate columns.

    The car payment calculator is already set up for a 5 year loan. There are longer term loans available, but you should generally avoid loans that last longer than 5 years. Sure, you ll get a lower monthly payment with those loans, but you ll pay down your loan balance slowly so slowly that you risk being upside-down on the loan (an unfortunate situation in which you owe more on your auto than it s worth). Then you might find yourself in the difficult position of trying to sell your car while there’s still a loan outstanding.

    Car Payment Calculator


    Loan Amortization Calculator – A Free Online Loan Amortization Calculator With Data Table


    #auto loan amortization
    #

    Your suggestion is on its way!

    Loan Amortization Calculator

    A Loan Amortization Calculator For Any Purpose

    The loan amortization calculator is intended to show you how your loan will work month-by-month, including information about:

    • Your monthly payment
    • How much of your loan gets paid off each month
    • How much of your monthly payment goes to interest each month
    • How much you’ll owe on your loan at any point in time

    The loan amortization calculator includes an amortization table for your reference.

    For more details on the results of your calculation, read How Amortization Works. If you want to dig into the numbers even more deeply, find out Calculate Loans on Your Own.

    Instructions

    Fill in the required information related to your loan, and click the Calculate button. A table will appear below the loan amortization calculator with the information described above.

    You may want to plug the loan amortization calculator’s output into Excel or another spreadsheet program so that you can work with the numbers even further (for example, you might calculate how much interest you’ll pay over the first 10 months of your loan). The best way to do this is to select the data starting outside (above, for example) of the table. Or, use a pre-built Excel loan calculator template.

    The loan amortization calculator can be used for your auto loans, home loans, or any other straight-line amortized loans. It does not work with credit card loans or other revolving loans.