This is default featured slide 1 title

Go to Blogger edit html and find these sentences.Now replace these sentences with your own descriptions.

This is default featured slide 2 title

Go to Blogger edit html and find these sentences.Now replace these sentences with your own descriptions.

This is default featured slide 3 title

Go to Blogger edit html and find these sentences.Now replace these sentences with your own descriptions.

This is default featured slide 4 title

Go to Blogger edit html and find these sentences.Now replace these sentences with your own descriptions.

This is default featured slide 5 title

Go to Blogger edit html and find these sentences.Now replace these sentences with your own descriptions.

Oracle for Absolute Beginners: Part 1 – Databases

A wise man* once said, an expert is someone who uses big words and acronyms where simple phrases would do just as nicely. So stand back and listen to this: Database, Relational Database, DBMS, RDBMS, SQL, Sub-queries, normalisation.
[* that wise man was me.]
So now that I’ve established my credentials by bamboozling you with arcane words and capital letters, let me tell you what the purpose of this series of articles is. By the end of it, you will be able to re-read that first paragraph and understand every word; or, if you would prefer that in more practical terms, you will be able to read – and write –  SQL, which is the programming language of databases.

Definitions

Let’s meet the main characters of our story: I’ll give you a couple of definitions; one building on the other.
A Database is an organised collection of data. Not yet sure what that means? Well, do you own an address book, either on your phone or in a physical book? That’s a database. After all, the addresses and phone numbers are organised – with all friends whose names start with A being grouped separately from people whose names start with B or C or D.
A Relational Database is a database in which the data is organised according to type with the relationships being maintained between the differing types. Okay, that sounds a bit like Greek (or Dutch, if you’re Greek; or German, if you’re Dutch; or Xhosa if you’re German…), but it makes sense if you let me explain.
Dig out your address book again. Imagine all the names grouped together; and all the phone numbers grouped together in another list; and all the addresses in a third. On their own these individual lists might be interesting but not useful; but if we establish the relationship between the lists – this address is where that person lives and that’s their phone number – then our database takes shape.
Make sense? Don’t worry about it too much if it doesn’t; we’ll come back to it a little later. Let’s talk about Oracle now.

Oracle

You’ve probably heard the word Oracle mentioned in discussions about databases, but you possibly do not know that Oracle is a corporation. It makes software to create and manage databases – so-called Database Management Systems. That’s the DBMS acronym from way back in paragraph 1; and an RDBMS is, of course, a Relational Database Management System.
Oracle began making RDBMS in the 70s. Today, the Oracle database is, by most metrics, the most popular in the world (it does have some strong competition; we’ll talk about them later. This isn’t like football; now you’re part of Team Oracle, it doesn’t mean you have to hate the opposition. Not much, at least). The latest version of the database is Oracle 12c. You don’t particularly need to remember that now – in fact, you don’t particularly need to remember anything from this section. We’re just painting in the background; the juicy stuff is what comes next.

Databases

It’s time to roll up our sleeves and get our hands dirty. Go get your address book again.
Remember I’d said the data in databases is organised in groups – all the names over here, the phone numbers over there, the addresses over in that other place? Well, those groupings are called tables.
So in our little database we have a FRIEND_NAME table, a PHONE_NUMBER table, and an ADDRESS table. Got that? Cool.
Tables are made up of vertical columns and horizontal rows. The columns contain data of the same type; while rows contain the data that makes up an item. In our example FRIEND_NAME table, the Last_Name column contains all the surnames – Geller, Bing, Tribiani, Geller-Bing, Green and Buffay – while the rows contain the full names, such as Ross Geller.
Oraforbeg1
Our database will be pretty boring – and not relational – if it contained only one table. Let’s knock up our PHONE_NUMBER and ADDRESS tables.
Oraforbeg2
Figure 1: PHONE_NUMBER
Oraforbeg3
Figure 2: ADDRESS

Data Types

You will have noticed that we’ve got different types of data in our tables – from the PHONE_NUMBER table that contains nothing but numbers to FRIEND_NAME and ADDRESS that both contain character strings, numbers and, in the case of the ZIPCODE column, a combination of both.
The Oracle database needs to know the types of all the data you keep. (That way, for instance, if you ask it to subtract the value in the ADDRESS.CITY column from the value in the ADDRESS.HOUSE_NO column, it’ll be able to tell you that you’re crazy.) There is a long list of data types that Oracle recognises, but we’ll only focus on the 3 main types.
NUMBER: This one’s self-explanatory. If a column is created as a NUMBER column, only numbers can be stored in it. It can be whole numbers, decimals, negative or positive.
VARCHAR2: Okay, this one’s a little weird. There’s a lot of history packed into the name of this data type; however, it’s mostly boring, so I won’t go into it. What you need to know is that it stands for VARiable CHARacter and is the data type required to store character strings, such as the data in FRIEND_NAME.FIRST_NAME, FRIEND_NAME.MIDDLE_NAME and FRIEND_NAME.LAST_NAME.
There is one interesting difference between the VARCHAR2 and NUMBER data types, and that is that you can only store numbers in NUMBER columns; however, you can record any string of alphanumeric characters in VARCHAR2 columns. For example, with its combination of numbers and letters, we cannot record ADDRESS.ZIPCODE in a NUMBER column, but we can save it as a VARCHAR2.
DATE: Another self-explanatory data type. We haven’t used any dates in our hypothetical database thus far – but we will; I’m saving that pleasure for later.

The One About Primary Keys

I’ve got another term for you: Primary Key. A primary key is a key – a column or combination of columns – that uniquely identifies a row.
Let me explain. Say one day, you’re chilling out at a café and you start chatting with a stranger. Turns out you’ve got lots in common and you really like that joke they told about a politician, a monkey and a water pistol. When eventually, you rise to leave, you exchange names and numbers and promise to stay in touch. They say their name is Ross Geller. You add it to your address book. But you already had a friend named Ross Geller! How will you know which is which when you want to phone them up and laugh about the monkey joke again?
Oraforbeg4
That’s where primary keys come in. Names – even rare ones like Ross Geller -  do not uniquely identify a record, so we need something that does. In our NAME table it is the number in FRIEND_ID. We simply need to give the new row, the new Ross, a new – unique – number in the FRIEND_ID column.
Databases rule the world, and thus, primary keys are all around us. Your passport number, your social security number, the number on your driving license – they’re all primary keys.

Relational Databases

We now have all the pieces of the puzzle. We can now redefine – and understand – relational databases. A Relational Database is a database in which the data is organised in tables with the relationships being maintained between the different tables.
Our database has a table for names, another for phone numbers, and a third for addresses. However, there is no way of knowing which of our friends lives at what address and when, or what their phone number might be. We’ve built a database, but it’s not yet relational. Let’s create two further tables that address that problem.
Oraforbeg5
Figure 3: FRIEND_ADDRESS
Oraforbeg6
Figure 4: FRIEND_PHONE
Take a minute to study the tables. Notice how useful primary keys are? Instead of typing out the friend’s name in full or typing the full address, all we need is the primary keys. And so, armed with our burgeoning knowledge of databases, we can look at the following:
Oraforbeg7
And after relating this table to the FRIEND_NAME and ADDRESS tables, we know that it is saying between September 1994 and October 2000, Chandler Bing lived at Apartment 19, 90 Bedford Street, New York, NY10014.
And the reason we know that is because we now implicitly understand the concept of foreign keys. Here’s a definition: A Foreign Key is a column (or combination of columns) that uniquely identifies a row in another table.
Foreign keys are the invisible threads that knit all the tables in our database together.  It is the foreign keys, telling us how the rows in one table are related to the rows in another table, that turn a database into a relational database.  It is the foreign key that takes data and begins to turn it into information.
Without foreign keys, a database is like a dull room, full of bored people.
With foreign keys, it’s a party.
Oraforbeg8.jpg

Recap

Here’s what I would like you to remember: what is a database? What is a relational database? What are tables, columns and row? What are the main data types? What are primary keys and foreign keys?
Got that? Great.  In the next article, we’ll be learning SQL, the language of databases.

Oracle HTML output

Oracle HTML output


In this small tutorial I will show you how you can display the output of the select command in a formatted HTML table from sqlPlus.

Tutorial info:


Name:Oracle HTML output
Total steps:1
Category:Oracle
Date:2007-11-15
Level:Beginner
Product:See complete product
Viewed:35720

Bookmark Oracle HTML output



AddThis Social Bookmark Button

Step 1 - HTML output from sqlPlus


Oracle HTML output
Oracle is a very feature rich high end database, however sqlPlus is one of it's weakness. Time to time it you need to list the content of a table or view in Oracle using sqlPlus and it usually results a hard interpretable output. There is the possibility to set line size parameter and modify the display size of the columns but it takes to much time.
I nice solution would be to display the output in a HTML format. Fortunately we can do that. Now I will show you 2 solutions. The first one is working from the command line and the second one is working inside sqlPLus.
1. Generate Oracle HTML output from command line:

Code:



  1.  



  2. sqlplus -S -M "HTML ON TABLE 'BORDER="2"'" user/password @test.sql>test.html



  3.  




In this example you need to create the test.sql file and put all your sql statements in this file. The result will be written into the test.html file.
2. Generate Oracle HTML output inside sqlPlus:

Code:



  1. SET markup HTML on



  2. spool test.html



  3. SELECT * FROM mytable;



  4. spool off



  5. SET markup HTML off




In this case you can write all of your sql statements between the spool commands. The test.html file will be generated in the actual directory.
As you can see these solutions are not the best as you can view the files in a browser and not in sqlPlus, however in a lot of cases this solution makes your life easier.

Oracle DBA FAQ - Understanding SQL SELECT Query Stateme

Oracle DBA FAQs and Tips - 400 Questions/Tutorials
This is a collection of FAQ and tips for Oracle DBA and developers. The clear answers and sample scripts provided can be used as learning tutorials or interview preparation guides.
It doesn't matter whether you are a beginner or an experienced Oracle DBA or developer, browse through our Oracle DBA FAQ and tips. They will always help you to improve your skills and find some good ideas to solve problems in your daily tasks.
So far, Our Oracle developers have written 400 questions and answers to share with you. Each one of them answers one commonly asked Oracle question with a short, but precise and clear SQL script. More questions will be available soon. Please come back to visit this page again.

This is a collection of 17 FAQs for Oracle DBA on fundamental concepts. The clear answers and sample scripts provided can be used as learning tutorials or interview preparation guides.
  1. What Is Oracle?
  2. What Is an Oracle Database?
  3. What Is an Oracle Instance?
  4. What Is a Parameter File?
  5. What Is a Server Parameter File?
  6. What Is an Initialization Parameter File?
  7. What Is System Global Area (SGA)?
  8. What Is Program Global Area (PGA)?
  9. What Is a User Account?
  10. What Is the Relation of a User Account and a Schema?
  11. What Is a User Role?
  12. What Is a Database Schema?
  13. What Is a Database Table?
  14. What Is a Table Index?
  15. What Is an Oracle Tablespace?
  16. What Is an Oracle Data File?
  17. What Is a Static Data Dictionary?
  18. What Is a Dynamic Performance View?
  19. What Is a Recycle Bin?
  20. What Is SQL*Plus?
  21. What Is Transport Network Substrate (TNS)?
  22. What Is Open Database Communication (ODBC)?
This is a collection of 21 FAQs for Oracle DBA on Oracle 10g Express Edition with installation and basic introduction. The clear answers and sample scripts provided can be used as learning tutorials or interview preparation guides.
  1. What Is Oracle Database 10g Express Edition?
  2. What Are the Limitations of Oracle Database 10g XE?
  3. What Operating Systems Are Supported by Oracle Database 10g XE?
  4. How To Download Oracle Database 10g XE?
  5. How To Install Oracle Database 10g XE?
  6. How To Check Your Oracle Database 10g XE Installation?
  7. How To Shutdown Your 10g XE Server?
  8. How To Start Your 10g XE Server?
  9. How Much Memory Your 10g XE Server Is Using?
  10. How To Start Your 10g XE Server from Command Line?
  11. How To Shutdown Your 10g XE Server from Command Line?
  12. How To Unlock the Sample User Account?
  13. How To Change System Global Area (SGA)?
  14. How To Change Program Global Area (PGA)?
  15. What Happens If You Set the SGA Too Low?
  16. What To Do If the StartDB.bat Failed to Start the XE Instance?
  17. How To Login to the Server without an Instance?
  18. How To Use "startup" Command to Start Default Instance?
  19. Where Are the Settings Stored for Each Instance?
  20. What To Do If the Binary SPFile Is Wrong for the Default Instance?
  21. How To Check the Server Version?
A collection of 25 FAQs on Oracle command-line SQL*Plus client tool. Clear answers are provided with tutorial exercises on creating tnsnames.ora and connecting to Oracle servers; SQL*Plus settings and environment variables; saving query output to files; getting query performance reports.
  1. What Is SQL*Plus?
  2. How To Start the Command-Line SQL*Plus?
  3. How To Get Help at the SQL Prompt?
  4. What Information Is Needed to Connect SQL*Plus an Oracle Server?
  5. What Is a Connect Identifier?
  6. How To Connect a SQL*Plus Session to an Oracle Server?
  7. What Happens If You Use a Wrong Connect Identifier?
  8. What To Do If DBA Lost the SYSTEM Password?
  9. What Types of Commands Can Be Executed in SQL*Plus?
  10. How To Run SQL Commands in SQL*Plus?
  11. How To Run PL/SQL Statements in SQL*Plus?
  12. How To Change SQL*Plus System Settings?
  13. How To Look at the Current SQL*Plus System Settings?
  14. What Are SQL*Plus Environment Variables?
  15. How To Generate Query Output in HTML Format?
  16. What Is Output Spooling in SQL*Plus?
  17. How To Save Query Output to a Local File?
  18. What Is Input Buffer in SQL*Plus?
  19. How To Revise and Re-Run the Last SQL Command?
  20. How Run SQL*Plus Commands That Are Stored in a Local File?
  21. How To Use SQL*Plus Built-in Timers?
  22. What Is Oracle Server Autotrace?
  23. How To Set Up Autotrace for a User Account?
  24. How To Get Execution Path Reports on Query Statements?
  25. How To Get Execution Statistics Reports on Query Statements?
A collection of 28 FAQs on Oracle SQL language basics. Clear answers are provided with tutorial exercises on data types, data literals, date and time values, data and time intervals, converting to dates and times, NULL values, pattern matches.
  1. What Is SQL Standard?
  2. How Many Categories of Data Types?
  3. What Are the Oracle Built-in Data Types?
  4. What Are the Differences between CHAR and NCHAR?
  5. What Are the Differences between CHAR and VARCHAR2?
  6. What Are the Differences between NUMBER and BINARY_FLOAT?
  7. What Are the Differences between DATE and TIMESTAMP?
  8. What Are the Differences between INTERVAL YEAR TO MONTH and INTERVAL DAY TO SECOND?
  9. What Are the Differences between BLOB and CLOB?
  10. What Are the ANSI Data Types Supported in Oracle?
  11. How To Write Text Literals?
  12. How To Write Numeric Literals?
  13. How To Write Date and Time Literals?
  14. How To Write Date and Time Interval Literals?
  15. How To Convert Numbers to Character Strings?
  16. How To Convert Characters to Numbers?
  17. How To Convert Dates to Characters?
  18. How To Convert Character Strings to Dates?
  19. How To Convert Times to Character Strings?
  20. How To Convert Character Strings to Times?
  21. What Is NULL Value?
  22. How To Use NULL as Conditions?
  23. How To Concatenate Two Text Values?
  24. How To Increment Dates by 1?
  25. How To Calculate Date and Time Differences?
  26. How To Use IN Conditions?
  27. How To Use LIKE Conditions?
  28. How To Use Regular Expression in Pattern Match Conditions?
A collection of 11 FAQs on Oracle SQL DDL statements. Clear answers are provided with tutorial exercises on creating, altering and dropping tables, indexes, and views.
  1. What Are DDL Statements?
  2. How To Create a New Table?
  3. How To Create a New Table by Selecting Rows from Another Table?
  4. How To Add a New Column to an Existing Table?
  5. How To Delete a Column in an Existing Table?
  6. How To Drop an Existing Table?
  7. How To Create a Table Index?
  8. How To Rename an Index?
  9. How To Drop an Existing Index?
  10. How To Create a New View?
  11. How To Drop an Existing View?
A collection of 15 FAQs on Oracle SQL DML statements. Clear answers are provided with tutorial exercises on inserting, updating and deleting rows from database tables.
  1. What Are DML Statements?
  2. How To Create a Testing Table?
  3. How To Set Up SQL*Plus Output Format?
  4. How To Insert a New Row into a Table?
  5. How To Specify Default Values in INSERT Statement?
  6. How To Omit Columns with Default Values in INSERT Statement?
  7. How To Insert Multiple Rows with One INSERT Statement?
  8. How To Update Values in a Table?
  9. How To Update Values on Multiple Rows?
  10. How To Use Existing Values in UPDATE Statements?
  11. How To Use Values from Other Tables in UPDATE Statements?
  12. What Happens If the UPDATE Subquery Returns Multiple Rows?
  13. How To Delete an Existing Row from a Table?
  14. How To Delete Multiple Rows from a Table?
  15. How To Delete All Rows from a Table?
A collection of 33 FAQs on Oracle SQL SELECT query statements. Clear answers are provided with tutorial exercises on selecting rows and columns from tables and views, sorting and counting query outputs, grouping outputs and applying group functions, joining tables, using subqueries.
  1. What Is a SELECT Query Statement?
  2. How To Select All Columns of All Rows from a Table?
  3. How To Select Some Columns from a Table?
  4. How To Select Some Rows from a Table?
  5. How To Sort the Query Output?
  6. Can the Query Output Be Sorted by Multiple Columns?
  7. How To Sort Query Output in Descending Order?
  8. How To Use SELECT Statement to Count the Number of Rows?
  9. Can SELECT Statements Be Used on Views?
  10. How To Filter Out Duplications in Returning Rows?
  11. What Are Group Functions?
  12. How To Use Group Functions in the SELECT Clause?
  13. Can Group Functions Be Mixed with Non-group Selection Fields?
  14. How To Divide Query Output into Groups?
  15. How To Apply Filtering Criteria at Group Level?
  16. How To Count Duplicated Values in a Column?
  17. Can Multiple Columns Be Used in GROUP BY?
  18. Can Group Functions Be Used in the ORDER BY Clause?
  19. How To Join Two Tables in a Single Query?
  20. How To Write a Query with an Inner Join?
  21. How To Define and Use Table Alias Names?
  22. How To Write a Query with a Left Outer Join?
  23. How To Write a Query with a Right Outer Join?
  24. How To Write a Query with a Full Outer Join?
  25. How To Write an Inner Join with the WHERE Clause?
  26. How To Write a Left Outer Join with the WHERE Clause?
  27. How To Name Query Output Columns?
  28. What Is a Subquery?
  29. How To Use Subqueries with the IN Operator?
  30. How To Use Subqueries with the EXISTS Operator?
  31. How To Use Subqueries in the FROM Clause?
  32. How To Count Groups Returned with the GROUP BY Clause?
  33. How To Return Top 5 Rows?
A collection of 22 FAQs on Oracle SQL transaction management. Clear answers are provided with tutorial exercises on starting and ending transactions, committing and rolling back transactions, transaction/statement-level read consistency, read committed isolation level, locks and dead locks.
  1. What Is a Transaction?
  2. How To Start a New Transaction?
  3. How To End the Current Transaction?
  4. How To Create a Test Table for Transaction Testing?
  5. How To Commit the Current Transaction?
  6. How To Rollback the Current Transaction?
  7. What Happens to the Current Transaction If a DDL Statement Is Executed?
  8. What Happens to the Current Transaction If the Session Is Ended?
  9. What Happens to the Current Transaction If the Session Is Killed?
  10. How Does Oracle Handle Read Consistency?
  11. What Is a READ WRITE Transaction?
  12. What Is a READ ONLY Transaction?
  13. How To Set a Transaction To Be READ ONLY?
  14. What Are the Restrictions in a READ ONLY Transaction?
  15. What Are the General Rules on Data Consistency?
  16. What Are Transaction Isolation Levels Supported by Oracle?
  17. What Is a Data Lock?
  18. How Data Locks Are Respected?
  19. How To Experiment a Data Lock?
  20. How To View Existing Locks on the Database?
  21. What Is a Dead Lock?
  22. How Oracle Handles Dead Locks?
A collection of 23 FAQs on Oracle user account, schema and privileges. Clear answers are provided with tutorial exercises on creating user accounts, granting privileges for session connections, granting privileges for creating tables and inserting rows.
  1. What Is a User Account?
  2. What Is the Relation of a User Account and a Schema?
  3. What Is a User Role?
  4. What Are the System Predefined User Roles?
  5. What Are Internal User Account?
  6. How To Connect to the Server with User Account: SYS?
  7. How To Use Windows User to Connect to the Server?
  8. How To List All User Accounts?
  9. How To Create a New User Account?
  10. How To Change User Password?
  11. How To Delete a User Account?
  12. What Privilege Is Needed for a User to Connect to Oracle Server?
  13. How To Grant CREATE SESSION Privilege to a User?
  14. How To Revoke CREATE SESSION Privilege from a User?
  15. How To Lock and Unlock a User Account?
  16. What Privilege Is Needed for a User to Create Tables?
  17. How To Assign a Tablespace to a Users?
  18. What Privilege Is Needed for a User to Create Views?
  19. What Privilege Is Needed for a User to Create Indexes?
  20. What Privilege Is Needed for a User to Query Tables in Another Schema?
  21. What Privilege Is Needed for a User to Insert Rows to Tables in Another Schema?
  22. What Privilege Is Needed for a User to Delete Rows from Tables in Another Schema?
  23. How To Find Out What Privileges a User Currently Has?
A collection of 18 FAQs on database tables for DBA and developers. Clear answers are provided together with tutorial exercises to help beginners on creating, altering and removing tables, adding, altering and removing columns, and working with recycle bin.
  1. What Is a Database Table?
  2. How Many Types of Tables Supported by Oracle?
  3. How To Create a New Table in Your Schema?
  4. How To Create a New Table by Selecting Rows from Another Table?
  5. How To Rename an Existing Table?
  6. How To Drop an Existing Table?
  7. How To Add a New Column to an Existing Table?
  8. How To Add a New Column to an Existing Table with a Default Value?
  9. How To Rename a Column in an Existing Table?
  10. How To Delete a Column in an Existing Table?
  11. How To View All Columns in an Existing Table?
  12. How To Recover a Dropped Table?
  13. What Is Recycle Bin?
  14. How To Turn On or Off Recycle Bin for the Instance?
  15. How To View the Dropped Tables in Your Recycle Bin?
  16. How To Empty Your Recycle Bin?
  17. How To Turn On or Off Recycle Bin for the Session?
  18. How To List All Tables in Your Schema?
This is a collection of 14 FAQs for Oracle DBA on creating, dropping, rebuilding and managing indexes. The clear answers and sample scripts provided can be used as learning tutorials or interview preparation guides.
  1. What Is an Index?
  2. How To Run SQL Statements through the Web Interface?
  3. How To Create a Table Index?
  4. How To List All Indexes in Your Schema?
  5. What Is an Index Associated with a Constraint?
  6. How To Rename an Index?
  7. How To Drop an Index?
  8. Can You Drop an Index Associated with a Unique or Primary Key Constraint?
  9. What Happens to Indexes If You Drop a Table?
  10. How To Recover a Dropped Index?
  11. What Happens to the Indexes If a Table Is Recovered?
  12. How To Rebuild an Index?
  13. How To See the Table Columns Used in an Index?
  14. How To Create a Single Index for Multiple Columns?
A collection of 19 FAQs on creating and managing tablespaces and data files. Clear answers are provided with tutorial exercises on creating and dropping tablespaces; listing available tablespaces; creating and dropping data files; setting tablespaces and data files offline; removing corrupted data files.
  1. What Is an Oracle Tablespace?
  2. What Is an Oracle Data File?
  3. How a Tablespace Is Related to Data Files?
  4. How a Database Is Related to Tablespaces?
  5. How To View Tablespaces in the Current Database?
  6. What Are the Predefined Tablespaces in a Database?
  7. How To View Data Files in the Current Database?
  8. How To Create a New Oracle Data File?
  9. How To Create a New Tablespace?
  10. How To Rename a Tablespace?
  11. How To Drop a Tablespace?
  12. What Happens to Data Files If a Tablespace Is Dropped?
  13. How To Create a Table in a Specific Tablespace?
  14. How To See Free Space of Each Tablespace?
  15. How To Bring a Tablespace Offline?
  16. How To Bring a Tablespace Online?
  17. How To Add Another Datafile to a Tablespace?
  18. What Happens If You Lost a Data File?
  19. How Remove Data Files before Opening a Database?
This is a collection of 15 FAQs for Oracle DBA on creating Oracle database instances manually using CREATE DATABASE statement. Items in this FAQ collection are organized together to form a complete tutorial guide on creating a new database instance manually.
  1. How To Create an Oracle Database?
  2. How To Create an Oracle Database Manually?
  3. How To Select an Oracle System ID (SID)?
  4. How To Establish Administrator Authentication to the Server?
  5. How To Create an Initialization Parameter File?
  6. How To Connect the Oracle Server as SYSDBA?
  7. How To Create a Server Parameter File?
  8. How To Start an Oracle Instance?
  9. How To Start a Specific Oracle Instance?
  10. How To Start Instance with a Minimal Initialization Parameter File?
  11. How To Run CREATE DATABASE Statement?
  12. How To Do Clean Up If CREATE DATABASE Failed?
  13. How To Run CREATE DATABASE Statement Again?
  14. How To Create Additional Tablespaces for an New Database?
  15. How To Build Data Dictionary View of an New Database?
A collection of 17 FAQs to introduce PL/SQL language for DBA and developers. This FAQ can also be used as learning tutorials on creating procedures, executing procedures, using local variables, controlling execution flows, passing parameters and defining nested procedures.
  1. What Is PL/SQL?
  2. What Are the Types PL/SQL Code Blocks?
  3. How To Define an Anonymous Block?
  4. How Many Anonymous Blocks Can Be Defined?
  5. How To Run the Anonymous Block Again?
  6. What Is a Stored Program Unit?
  7. How To Create a Stored Program Unit?
  8. How To Execute a Stored Program Unit?
  9. How Many Data Types Are Supported?
  10. What Are the Execution Flow Control Statements?
  11. How To Use SQL Statements in PL/SQL?
  12. How To Process Query Result in PL/SQL?
  13. How To Create an Array in PL/SQL?
  14. How To Manage Transaction Isolation Level?
  15. How To Pass Parameters to Procedures?
  16. How To Define a Procedure inside Another Procedure?
  17. What Do You Think about PL/SQL?
A collection of 29 FAQs to introduce Oracle SQL Developer, the new free GUI client for DBA and developers. This FAQ can also be used as learning tutorials on SQL statement execution, data objects management, system views and reports, stored procedure debugging.
  1. What Is Oracle SQL Developer?
  2. What Operating Systems Are Supported by Oracle SQL Developer?
  3. How To Download Oracle SQL Developer?
  4. How To Install Oracle SQL Developer?
  5. How To Start Oracle SQL Developer?
  6. Is Oracel SQL Developer written in Java?
  7. How To Connect to a Local Oracle 10g XE Server?
  8. How To Connect to a Remote Server?
  9. How To Run SQL Statements with Oracle SQL Developer?
  10. How To Export Your Connection Information to a File?
  11. How To Run SQL*Plus Commands in SQL Developer?
  12. How To Work with Data Objects Interactively?
  13. How To Get a CREATE Statement for an Existing Table?
  14. How To Create a Table Interactively?
  15. How To Enter a New Row into a Table Interactively?
  16. What Is the Reports View in Oracle SQL Developer?
  17. How To Get a List of All Tables in the Database?
  18. How To Get a List of All User Accounts in the Database?
  19. How To Get a List of All Background Sessions in the Database?
  20. How To Create Your Own Reports in SQL Developer?
  21. How Many File Formats Are Supported to Export Data?
  22. How To Export Data to a CSV File?
  23. How To Export Data to an XML File?
  24. How To Create a Procedure Interactively?
  25. How To Run a Stored Procedure Interactively?
  26. How To Run Stored Procedures in Debug Mode?
  27. How To Assign Debug Privileges to a User?
  28. How To Set Up Breakpoints in Debug Mode?
  29. What Do You Think about Oracle SQL Developer?
A collection of 22 FAQs on PL/SQL language basics or DBA and developers. It can also be used as learning tutorials on defining variables, assigning values, using "loop" statements, setting "if" conditions, and working with null values.
  1. Is PL/SQL Language Case Sensitive?
  2. How To Enter Comments in PL/SQL?
  3. What Are the Types of PL/SQL Code Blocks?
  4. What Is an Anonymous Block?
  5. What Is a Named Program Unit?
  6. What Is a Procedure?
  7. What Is a Function?
  8. How To Declare a Local Variable?
  9. How To Initialize Variables with Default Values?
  10. How To Assign Values to Variables?
  11. What Are the Arithmetic Operations?
  12. What Are the Numeric Comparison Operations?
  13. What Are the Logical Operations?
  14. How Many Categories of Data Types?
  15. How Many Scalar Data Types Are Supported in PL/SQL?
  16. How To Convert Character Types to Numeric Types?
  17. What Are the Execution Control Statements?
  18. How To Use "IF" Statements on Multiple Conditions?
  19. How To Use "WHILE" Loop Statements?
  20. How To Use "FOR" Loop Statements?
  21. What Is NULL in PL/SQL?
  22. How To Test NULL Values?
A collection of 26 FAQs on PL/SQL managing our own procedures. It can also be used as learning tutorials on creating procedures and functions, executing and dropping procedures, passing actual parameters to formal parameters, making optional parameters.
  1. What Is a Procedure?
  2. What Is a Function?
  3. How To Define an Anonymous Procedure without Variables?
  4. How To Define an Anonymous Procedure with Variables?
  5. How To Create a Stored Procedure?
  6. How To Execute a Stored Procedure?
  7. How To Drop a Stored Procedure?
  8. How To Pass Parameters to Procedures?
  9. How To Create a Stored Function?
  10. How To Call a Stored Function?
  11. How To Drop a Stored Function?
  12. How To Call a Stored Function with Parameters?
  13. How To Define a Sub Procedure?
  14. How To Call a Sub Procedure?
  15. How To Define a Sub Function?
  16. Can Sub Procedure/Function Be Called Recursively?
  17. What Happens If Recursive Calls Get Out of Control?
  18. What Is the Order of Defining Local Variables and Sub Procedures/Functions?
  19. What Is the Difference between Formal Parameters and Actual Parameters?
  20. What Are the Parameter Modes Supported by PL/SQL?
  21. How To Use "IN" Parameter Properly?
  22. How To Use "OUT" Parameter Properly?
  23. How To Use "IN OUT" Parameter Properly?
  24. How To Define Default Values for Formal Parameters?
  25. What Are Named Parameters?
  26. What Is the Scope of a Local Variable?
A collection of 23 FAQs on working with database objects in PL/SQL. Clear answers are provided with tutorial exercises on running DML statements, assign table data to variables, using the implicit cursor, defining and using RECORDs with table rows.
  1. Can DML Statements Be Used in PL/SQL?
  2. Can DDL Statements Be Used in PL/SQL?
  3. Can Variables Be Used in SQL Statements?
  4. What Happens If Variable Names Collide with Table/Column Names?
  5. How To Resolve Name Conflicts between Variables and Columns?
  6. How To Assign Query Results to Variables?
  7. Can You Assign Multiple Query Result Rows To a Variable?
  8. How To Invoke Built-in Functions in PL/SQL?
  9. How To Retrieve the Count of Updated Rows?
  10. What Is the Implicit Cursor?
  11. How To Assign Data of the Deleted Row to Variables?
  12. What Is a RECORD in PL/SQL?
  13. How To Define a Specific RECORD Type?
  14. How To Define a Variable of a Specific RECORD Type?
  15. How To Assign Values to Data Fields in RECORD Variables?
  16. How To Retrieve Values from Data Fields in RECORD Variables?
  17. How To Define a Data Field as NOT NULL?
  18. How To Define a RECORD Variable to Store a Table Row?
  19. How To Assign a Table Row to a RECORD Variable?
  20. How To Insert a RECORD into a Table?
  21. How To Update a Table Row with a RECORD?
  22. How To Define a Variable to Match a Table Column Data Type?
A collection of 19 FAQs on working with database objects in PL/SQL. Clear answers are provided with tutorial exercises on defining, opening, and closing cursors, looping through cursors, defining and using cursor variables.
  1. What Is a Cursor?
  2. How Many Types of Cursors Supported in PL/SQL?
  3. What Is the Implicit Cursor?
  4. How To Use Attributes of the Implicit Cursor?
  5. How To Loop through Data Rows in the Implicit Curosr?
  6. How To Define an Explicit Cursor?
  7. How To Open and Close an Explicit Cursor?
  8. How To Retrieve Data from an Explicit Cursor?
  9. How To Retrieve Data from a Cursor to a RECORD?
  10. How To Use FETCH Statement in a Loop?
  11. How To Use an Explicit Cursor without OPEN Statements?
  12. Can Multiple Cursors Being Opened at the Same Time?
  13. How To Pass a Parameter to a Cursor?
  14. What Is a Cursor Variable?
  15. How To Define a Cursor Variable?
  16. How To Open a Cursor Variable?
  17. How To Loop through a Cursor Variable?
  18. How To Pass a Cursor Variable to a Procedure?
  19. Why Cursor Variables Are Easier to Use than Cursors?
A collection of 27 FAQs on Oracle loading data and exporting data. Clear answers are provided with tutorial exercises on saving data as flat files, loading data from flat, exporting and importing database, schema and tables, creating external tables.
  1. What Is the Simplest Tool to Run Commands on Oracle Servers?
  2. What Is the Quickest Way to Export a Table to a Flat File?
  3. How To Export Data with a Field Delimiter?
  4. What Is SQL*Loader?
  5. What Is a SQL*Loader Control File?
  6. How To Load Data with SQL*Loader?
  7. What Is an External Table?
  8. How To Load Data through External Tables?
  9. What Are the Restrictions on External Table Columns?
  10. What Is a Directory Object?
  11. How To Define an External Table in a Text File?
  12. How To Run Queries on External Tables?
  13. How To Load Data from External Tables to Regular Tables?
  14. What Is the Data Pump Export Utility?
  15. What Is the Data Pump Import Utility?
  16. How To Invoke the Data Pump Export Utility?
  17. How To Invoke the Data Pump Import Utility?
  18. What Are Data Pump Export and Import Modes?
  19. How To Estimate Disk Space Needed for an Export Job?
  20. How To Do a Full Database Export?
  21. Where Is the Export Dump File Located?
  22. How To Export Your Own Schema?
  23. How To Export Several Tables Together?
  24. What Happens If the Imported Table Already Exists?
  25. How To Import One Table Back from a Dump File?
  26. What Are the Original Export and Import Utilities?
  27. How To Invoke Original Export/Import Utilities?
A collection of 9 FAQs on Oracle ODBC drivers and connections. Clear answers are provided with tutorial exercises on installing Oracle ODBC drivers; TNS settings; defining DSN entries; connecting MS Access or ASP pages to Oracle servers.
  1. What Is Open Database Communication (ODBC)?
  2. How To Install Oracle ODBC Drivers?
  3. How To Find Out What Oracle ODBC Drivers Are Installed?
  4. How Can Windows Applications Connect to Oracle Servers?
  5. How To Create Tables for ODBC Connection Testing?
  6. How To Verify Oracle TNS Settings?
  7. How To Define a Data Source Name (DSN) in ODBC Manager?
  8. How To Connect MS Access to Oracle Servers?
  9. How To Connect ASP Pages to Oracle Servers?

Oracle DBA FAQ - Introduction to PL - SQL

Oracle DBA FAQs and Tips - 400 Questions/Tutorials
This is a collection of FAQ and tips for Oracle DBA and developers. The clear answers and sample scripts provided can be used as learning tutorials or interview preparation guides.
It doesn't matter whether you are a beginner or an experienced Oracle DBA or developer, browse through our Oracle DBA FAQ and tips. They will always help you to improve your skills and find some good ideas to solve problems in your daily tasks.
So far, Our Oracle developers have written 400 questions and answers to share with you. Each one of them answers one commonly asked Oracle question with a short, but precise and clear SQL script. More questions will be available soon. Please come back to visit this page again.

This is a collection of 17 FAQs for Oracle DBA on fundamental concepts. The clear answers and sample scripts provided can be used as learning tutorials or interview preparation guides.
  1. What Is Oracle?
  2. What Is an Oracle Database?
  3. What Is an Oracle Instance?
  4. What Is a Parameter File?
  5. What Is a Server Parameter File?
  6. What Is an Initialization Parameter File?
  7. What Is System Global Area (SGA)?
  8. What Is Program Global Area (PGA)?
  9. What Is a User Account?
  10. What Is the Relation of a User Account and a Schema?
  11. What Is a User Role?
  12. What Is a Database Schema?
  13. What Is a Database Table?
  14. What Is a Table Index?
  15. What Is an Oracle Tablespace?
  16. What Is an Oracle Data File?
  17. What Is a Static Data Dictionary?
  18. What Is a Dynamic Performance View?
  19. What Is a Recycle Bin?
  20. What Is SQL*Plus?
  21. What Is Transport Network Substrate (TNS)?
  22. What Is Open Database Communication (ODBC)?
This is a collection of 21 FAQs for Oracle DBA on Oracle 10g Express Edition with installation and basic introduction. The clear answers and sample scripts provided can be used as learning tutorials or interview preparation guides.
  1. What Is Oracle Database 10g Express Edition?
  2. What Are the Limitations of Oracle Database 10g XE?
  3. What Operating Systems Are Supported by Oracle Database 10g XE?
  4. How To Download Oracle Database 10g XE?
  5. How To Install Oracle Database 10g XE?
  6. How To Check Your Oracle Database 10g XE Installation?
  7. How To Shutdown Your 10g XE Server?
  8. How To Start Your 10g XE Server?
  9. How Much Memory Your 10g XE Server Is Using?
  10. How To Start Your 10g XE Server from Command Line?
  11. How To Shutdown Your 10g XE Server from Command Line?
  12. How To Unlock the Sample User Account?
  13. How To Change System Global Area (SGA)?
  14. How To Change Program Global Area (PGA)?
  15. What Happens If You Set the SGA Too Low?
  16. What To Do If the StartDB.bat Failed to Start the XE Instance?
  17. How To Login to the Server without an Instance?
  18. How To Use "startup" Command to Start Default Instance?
  19. Where Are the Settings Stored for Each Instance?
  20. What To Do If the Binary SPFile Is Wrong for the Default Instance?
  21. How To Check the Server Version?
A collection of 25 FAQs on Oracle command-line SQL*Plus client tool. Clear answers are provided with tutorial exercises on creating tnsnames.ora and connecting to Oracle servers; SQL*Plus settings and environment variables; saving query output to files; getting query performance reports.
  1. What Is SQL*Plus?
  2. How To Start the Command-Line SQL*Plus?
  3. How To Get Help at the SQL Prompt?
  4. What Information Is Needed to Connect SQL*Plus an Oracle Server?
  5. What Is a Connect Identifier?
  6. How To Connect a SQL*Plus Session to an Oracle Server?
  7. What Happens If You Use a Wrong Connect Identifier?
  8. What To Do If DBA Lost the SYSTEM Password?
  9. What Types of Commands Can Be Executed in SQL*Plus?
  10. How To Run SQL Commands in SQL*Plus?
  11. How To Run PL/SQL Statements in SQL*Plus?
  12. How To Change SQL*Plus System Settings?
  13. How To Look at the Current SQL*Plus System Settings?
  14. What Are SQL*Plus Environment Variables?
  15. How To Generate Query Output in HTML Format?
  16. What Is Output Spooling in SQL*Plus?
  17. How To Save Query Output to a Local File?
  18. What Is Input Buffer in SQL*Plus?
  19. How To Revise and Re-Run the Last SQL Command?
  20. How Run SQL*Plus Commands That Are Stored in a Local File?
  21. How To Use SQL*Plus Built-in Timers?
  22. What Is Oracle Server Autotrace?
  23. How To Set Up Autotrace for a User Account?
  24. How To Get Execution Path Reports on Query Statements?
  25. How To Get Execution Statistics Reports on Query Statements?
A collection of 28 FAQs on Oracle SQL language basics. Clear answers are provided with tutorial exercises on data types, data literals, date and time values, data and time intervals, converting to dates and times, NULL values, pattern matches.
  1. What Is SQL Standard?
  2. How Many Categories of Data Types?
  3. What Are the Oracle Built-in Data Types?
  4. What Are the Differences between CHAR and NCHAR?
  5. What Are the Differences between CHAR and VARCHAR2?
  6. What Are the Differences between NUMBER and BINARY_FLOAT?
  7. What Are the Differences between DATE and TIMESTAMP?
  8. What Are the Differences between INTERVAL YEAR TO MONTH and INTERVAL DAY TO SECOND?
  9. What Are the Differences between BLOB and CLOB?
  10. What Are the ANSI Data Types Supported in Oracle?
  11. How To Write Text Literals?
  12. How To Write Numeric Literals?
  13. How To Write Date and Time Literals?
  14. How To Write Date and Time Interval Literals?
  15. How To Convert Numbers to Character Strings?
  16. How To Convert Characters to Numbers?
  17. How To Convert Dates to Characters?
  18. How To Convert Character Strings to Dates?
  19. How To Convert Times to Character Strings?
  20. How To Convert Character Strings to Times?
  21. What Is NULL Value?
  22. How To Use NULL as Conditions?
  23. How To Concatenate Two Text Values?
  24. How To Increment Dates by 1?
  25. How To Calculate Date and Time Differences?
  26. How To Use IN Conditions?
  27. How To Use LIKE Conditions?
  28. How To Use Regular Expression in Pattern Match Conditions?
A collection of 11 FAQs on Oracle SQL DDL statements. Clear answers are provided with tutorial exercises on creating, altering and dropping tables, indexes, and views.
  1. What Are DDL Statements?
  2. How To Create a New Table?
  3. How To Create a New Table by Selecting Rows from Another Table?
  4. How To Add a New Column to an Existing Table?
  5. How To Delete a Column in an Existing Table?
  6. How To Drop an Existing Table?
  7. How To Create a Table Index?
  8. How To Rename an Index?
  9. How To Drop an Existing Index?
  10. How To Create a New View?
  11. How To Drop an Existing View?
A collection of 15 FAQs on Oracle SQL DML statements. Clear answers are provided with tutorial exercises on inserting, updating and deleting rows from database tables.
  1. What Are DML Statements?
  2. How To Create a Testing Table?
  3. How To Set Up SQL*Plus Output Format?
  4. How To Insert a New Row into a Table?
  5. How To Specify Default Values in INSERT Statement?
  6. How To Omit Columns with Default Values in INSERT Statement?
  7. How To Insert Multiple Rows with One INSERT Statement?
  8. How To Update Values in a Table?
  9. How To Update Values on Multiple Rows?
  10. How To Use Existing Values in UPDATE Statements?
  11. How To Use Values from Other Tables in UPDATE Statements?
  12. What Happens If the UPDATE Subquery Returns Multiple Rows?
  13. How To Delete an Existing Row from a Table?
  14. How To Delete Multiple Rows from a Table?
  15. How To Delete All Rows from a Table?
A collection of 33 FAQs on Oracle SQL SELECT query statements. Clear answers are provided with tutorial exercises on selecting rows and columns from tables and views, sorting and counting query outputs, grouping outputs and applying group functions, joining tables, using subqueries.
  1. What Is a SELECT Query Statement?
  2. How To Select All Columns of All Rows from a Table?
  3. How To Select Some Columns from a Table?
  4. How To Select Some Rows from a Table?
  5. How To Sort the Query Output?
  6. Can the Query Output Be Sorted by Multiple Columns?
  7. How To Sort Query Output in Descending Order?
  8. How To Use SELECT Statement to Count the Number of Rows?
  9. Can SELECT Statements Be Used on Views?
  10. How To Filter Out Duplications in Returning Rows?
  11. What Are Group Functions?
  12. How To Use Group Functions in the SELECT Clause?
  13. Can Group Functions Be Mixed with Non-group Selection Fields?
  14. How To Divide Query Output into Groups?
  15. How To Apply Filtering Criteria at Group Level?
  16. How To Count Duplicated Values in a Column?
  17. Can Multiple Columns Be Used in GROUP BY?
  18. Can Group Functions Be Used in the ORDER BY Clause?
  19. How To Join Two Tables in a Single Query?
  20. How To Write a Query with an Inner Join?
  21. How To Define and Use Table Alias Names?
  22. How To Write a Query with a Left Outer Join?
  23. How To Write a Query with a Right Outer Join?
  24. How To Write a Query with a Full Outer Join?
  25. How To Write an Inner Join with the WHERE Clause?
  26. How To Write a Left Outer Join with the WHERE Clause?
  27. How To Name Query Output Columns?
  28. What Is a Subquery?
  29. How To Use Subqueries with the IN Operator?
  30. How To Use Subqueries with the EXISTS Operator?
  31. How To Use Subqueries in the FROM Clause?
  32. How To Count Groups Returned with the GROUP BY Clause?
  33. How To Return Top 5 Rows?
A collection of 22 FAQs on Oracle SQL transaction management. Clear answers are provided with tutorial exercises on starting and ending transactions, committing and rolling back transactions, transaction/statement-level read consistency, read committed isolation level, locks and dead locks.
  1. What Is a Transaction?
  2. How To Start a New Transaction?
  3. How To End the Current Transaction?
  4. How To Create a Test Table for Transaction Testing?
  5. How To Commit the Current Transaction?
  6. How To Rollback the Current Transaction?
  7. What Happens to the Current Transaction If a DDL Statement Is Executed?
  8. What Happens to the Current Transaction If the Session Is Ended?
  9. What Happens to the Current Transaction If the Session Is Killed?
  10. How Does Oracle Handle Read Consistency?
  11. What Is a READ WRITE Transaction?
  12. What Is a READ ONLY Transaction?
  13. How To Set a Transaction To Be READ ONLY?
  14. What Are the Restrictions in a READ ONLY Transaction?
  15. What Are the General Rules on Data Consistency?
  16. What Are Transaction Isolation Levels Supported by Oracle?
  17. What Is a Data Lock?
  18. How Data Locks Are Respected?
  19. How To Experiment a Data Lock?
  20. How To View Existing Locks on the Database?
  21. What Is a Dead Lock?
  22. How Oracle Handles Dead Locks?
A collection of 23 FAQs on Oracle user account, schema and privileges. Clear answers are provided with tutorial exercises on creating user accounts, granting privileges for session connections, granting privileges for creating tables and inserting rows.
  1. What Is a User Account?
  2. What Is the Relation of a User Account and a Schema?
  3. What Is a User Role?
  4. What Are the System Predefined User Roles?
  5. What Are Internal User Account?
  6. How To Connect to the Server with User Account: SYS?
  7. How To Use Windows User to Connect to the Server?
  8. How To List All User Accounts?
  9. How To Create a New User Account?
  10. How To Change User Password?
  11. How To Delete a User Account?
  12. What Privilege Is Needed for a User to Connect to Oracle Server?
  13. How To Grant CREATE SESSION Privilege to a User?
  14. How To Revoke CREATE SESSION Privilege from a User?
  15. How To Lock and Unlock a User Account?
  16. What Privilege Is Needed for a User to Create Tables?
  17. How To Assign a Tablespace to a Users?
  18. What Privilege Is Needed for a User to Create Views?
  19. What Privilege Is Needed for a User to Create Indexes?
  20. What Privilege Is Needed for a User to Query Tables in Another Schema?
  21. What Privilege Is Needed for a User to Insert Rows to Tables in Another Schema?
  22. What Privilege Is Needed for a User to Delete Rows from Tables in Another Schema?
  23. How To Find Out What Privileges a User Currently Has?
A collection of 18 FAQs on database tables for DBA and developers. Clear answers are provided together with tutorial exercises to help beginners on creating, altering and removing tables, adding, altering and removing columns, and working with recycle bin.
  1. What Is a Database Table?
  2. How Many Types of Tables Supported by Oracle?
  3. How To Create a New Table in Your Schema?
  4. How To Create a New Table by Selecting Rows from Another Table?
  5. How To Rename an Existing Table?
  6. How To Drop an Existing Table?
  7. How To Add a New Column to an Existing Table?
  8. How To Add a New Column to an Existing Table with a Default Value?
  9. How To Rename a Column in an Existing Table?
  10. How To Delete a Column in an Existing Table?
  11. How To View All Columns in an Existing Table?
  12. How To Recover a Dropped Table?
  13. What Is Recycle Bin?
  14. How To Turn On or Off Recycle Bin for the Instance?
  15. How To View the Dropped Tables in Your Recycle Bin?
  16. How To Empty Your Recycle Bin?
  17. How To Turn On or Off Recycle Bin for the Session?
  18. How To List All Tables in Your Schema?
This is a collection of 14 FAQs for Oracle DBA on creating, dropping, rebuilding and managing indexes. The clear answers and sample scripts provided can be used as learning tutorials or interview preparation guides.
  1. What Is an Index?
  2. How To Run SQL Statements through the Web Interface?
  3. How To Create a Table Index?
  4. How To List All Indexes in Your Schema?
  5. What Is an Index Associated with a Constraint?
  6. How To Rename an Index?
  7. How To Drop an Index?
  8. Can You Drop an Index Associated with a Unique or Primary Key Constraint?
  9. What Happens to Indexes If You Drop a Table?
  10. How To Recover a Dropped Index?
  11. What Happens to the Indexes If a Table Is Recovered?
  12. How To Rebuild an Index?
  13. How To See the Table Columns Used in an Index?
  14. How To Create a Single Index for Multiple Columns?
A collection of 19 FAQs on creating and managing tablespaces and data files. Clear answers are provided with tutorial exercises on creating and dropping tablespaces; listing available tablespaces; creating and dropping data files; setting tablespaces and data files offline; removing corrupted data files.
  1. What Is an Oracle Tablespace?
  2. What Is an Oracle Data File?
  3. How a Tablespace Is Related to Data Files?
  4. How a Database Is Related to Tablespaces?
  5. How To View Tablespaces in the Current Database?
  6. What Are the Predefined Tablespaces in a Database?
  7. How To View Data Files in the Current Database?
  8. How To Create a New Oracle Data File?
  9. How To Create a New Tablespace?
  10. How To Rename a Tablespace?
  11. How To Drop a Tablespace?
  12. What Happens to Data Files If a Tablespace Is Dropped?
  13. How To Create a Table in a Specific Tablespace?
  14. How To See Free Space of Each Tablespace?
  15. How To Bring a Tablespace Offline?
  16. How To Bring a Tablespace Online?
  17. How To Add Another Datafile to a Tablespace?
  18. What Happens If You Lost a Data File?
  19. How Remove Data Files before Opening a Database?
This is a collection of 15 FAQs for Oracle DBA on creating Oracle database instances manually using CREATE DATABASE statement. Items in this FAQ collection are organized together to form a complete tutorial guide on creating a new database instance manually.
  1. How To Create an Oracle Database?
  2. How To Create an Oracle Database Manually?
  3. How To Select an Oracle System ID (SID)?
  4. How To Establish Administrator Authentication to the Server?
  5. How To Create an Initialization Parameter File?
  6. How To Connect the Oracle Server as SYSDBA?
  7. How To Create a Server Parameter File?
  8. How To Start an Oracle Instance?
  9. How To Start a Specific Oracle Instance?
  10. How To Start Instance with a Minimal Initialization Parameter File?
  11. How To Run CREATE DATABASE Statement?
  12. How To Do Clean Up If CREATE DATABASE Failed?
  13. How To Run CREATE DATABASE Statement Again?
  14. How To Create Additional Tablespaces for an New Database?
  15. How To Build Data Dictionary View of an New Database?
A collection of 17 FAQs to introduce PL/SQL language for DBA and developers. This FAQ can also be used as learning tutorials on creating procedures, executing procedures, using local variables, controlling execution flows, passing parameters and defining nested procedures.
  1. What Is PL/SQL?
  2. What Are the Types PL/SQL Code Blocks?
  3. How To Define an Anonymous Block?
  4. How Many Anonymous Blocks Can Be Defined?
  5. How To Run the Anonymous Block Again?
  6. What Is a Stored Program Unit?
  7. How To Create a Stored Program Unit?
  8. How To Execute a Stored Program Unit?
  9. How Many Data Types Are Supported?
  10. What Are the Execution Flow Control Statements?
  11. How To Use SQL Statements in PL/SQL?
  12. How To Process Query Result in PL/SQL?
  13. How To Create an Array in PL/SQL?
  14. How To Manage Transaction Isolation Level?
  15. How To Pass Parameters to Procedures?
  16. How To Define a Procedure inside Another Procedure?
  17. What Do You Think about PL/SQL?
A collection of 29 FAQs to introduce Oracle SQL Developer, the new free GUI client for DBA and developers. This FAQ can also be used as learning tutorials on SQL statement execution, data objects management, system views and reports, stored procedure debugging.
  1. What Is Oracle SQL Developer?
  2. What Operating Systems Are Supported by Oracle SQL Developer?
  3. How To Download Oracle SQL Developer?
  4. How To Install Oracle SQL Developer?
  5. How To Start Oracle SQL Developer?
  6. Is Oracel SQL Developer written in Java?
  7. How To Connect to a Local Oracle 10g XE Server?
  8. How To Connect to a Remote Server?
  9. How To Run SQL Statements with Oracle SQL Developer?
  10. How To Export Your Connection Information to a File?
  11. How To Run SQL*Plus Commands in SQL Developer?
  12. How To Work with Data Objects Interactively?
  13. How To Get a CREATE Statement for an Existing Table?
  14. How To Create a Table Interactively?
  15. How To Enter a New Row into a Table Interactively?
  16. What Is the Reports View in Oracle SQL Developer?
  17. How To Get a List of All Tables in the Database?
  18. How To Get a List of All User Accounts in the Database?
  19. How To Get a List of All Background Sessions in the Database?
  20. How To Create Your Own Reports in SQL Developer?
  21. How Many File Formats Are Supported to Export Data?
  22. How To Export Data to a CSV File?
  23. How To Export Data to an XML File?
  24. How To Create a Procedure Interactively?
  25. How To Run a Stored Procedure Interactively?
  26. How To Run Stored Procedures in Debug Mode?
  27. How To Assign Debug Privileges to a User?
  28. How To Set Up Breakpoints in Debug Mode?
  29. What Do You Think about Oracle SQL Developer?
A collection of 22 FAQs on PL/SQL language basics or DBA and developers. It can also be used as learning tutorials on defining variables, assigning values, using "loop" statements, setting "if" conditions, and working with null values.
  1. Is PL/SQL Language Case Sensitive?
  2. How To Enter Comments in PL/SQL?
  3. What Are the Types of PL/SQL Code Blocks?
  4. What Is an Anonymous Block?
  5. What Is a Named Program Unit?
  6. What Is a Procedure?
  7. What Is a Function?
  8. How To Declare a Local Variable?
  9. How To Initialize Variables with Default Values?
  10. How To Assign Values to Variables?
  11. What Are the Arithmetic Operations?
  12. What Are the Numeric Comparison Operations?
  13. What Are the Logical Operations?
  14. How Many Categories of Data Types?
  15. How Many Scalar Data Types Are Supported in PL/SQL?
  16. How To Convert Character Types to Numeric Types?
  17. What Are the Execution Control Statements?
  18. How To Use "IF" Statements on Multiple Conditions?
  19. How To Use "WHILE" Loop Statements?
  20. How To Use "FOR" Loop Statements?
  21. What Is NULL in PL/SQL?
  22. How To Test NULL Values?
A collection of 26 FAQs on PL/SQL managing our own procedures. It can also be used as learning tutorials on creating procedures and functions, executing and dropping procedures, passing actual parameters to formal parameters, making optional parameters.
  1. What Is a Procedure?
  2. What Is a Function?
  3. How To Define an Anonymous Procedure without Variables?
  4. How To Define an Anonymous Procedure with Variables?
  5. How To Create a Stored Procedure?
  6. How To Execute a Stored Procedure?
  7. How To Drop a Stored Procedure?
  8. How To Pass Parameters to Procedures?
  9. How To Create a Stored Function?
  10. How To Call a Stored Function?
  11. How To Drop a Stored Function?
  12. How To Call a Stored Function with Parameters?
  13. How To Define a Sub Procedure?
  14. How To Call a Sub Procedure?
  15. How To Define a Sub Function?
  16. Can Sub Procedure/Function Be Called Recursively?
  17. What Happens If Recursive Calls Get Out of Control?
  18. What Is the Order of Defining Local Variables and Sub Procedures/Functions?
  19. What Is the Difference between Formal Parameters and Actual Parameters?
  20. What Are the Parameter Modes Supported by PL/SQL?
  21. How To Use "IN" Parameter Properly?
  22. How To Use "OUT" Parameter Properly?
  23. How To Use "IN OUT" Parameter Properly?
  24. How To Define Default Values for Formal Parameters?
  25. What Are Named Parameters?
  26. What Is the Scope of a Local Variable?
A collection of 23 FAQs on working with database objects in PL/SQL. Clear answers are provided with tutorial exercises on running DML statements, assign table data to variables, using the implicit cursor, defining and using RECORDs with table rows.
  1. Can DML Statements Be Used in PL/SQL?
  2. Can DDL Statements Be Used in PL/SQL?
  3. Can Variables Be Used in SQL Statements?
  4. What Happens If Variable Names Collide with Table/Column Names?
  5. How To Resolve Name Conflicts between Variables and Columns?
  6. How To Assign Query Results to Variables?
  7. Can You Assign Multiple Query Result Rows To a Variable?
  8. How To Invoke Built-in Functions in PL/SQL?
  9. How To Retrieve the Count of Updated Rows?
  10. What Is the Implicit Cursor?
  11. How To Assign Data of the Deleted Row to Variables?
  12. What Is a RECORD in PL/SQL?
  13. How To Define a Specific RECORD Type?
  14. How To Define a Variable of a Specific RECORD Type?
  15. How To Assign Values to Data Fields in RECORD Variables?
  16. How To Retrieve Values from Data Fields in RECORD Variables?
  17. How To Define a Data Field as NOT NULL?
  18. How To Define a RECORD Variable to Store a Table Row?
  19. How To Assign a Table Row to a RECORD Variable?
  20. How To Insert a RECORD into a Table?
  21. How To Update a Table Row with a RECORD?
  22. How To Define a Variable to Match a Table Column Data Type?
A collection of 19 FAQs on working with database objects in PL/SQL. Clear answers are provided with tutorial exercises on defining, opening, and closing cursors, looping through cursors, defining and using cursor variables.
  1. What Is a Cursor?
  2. How Many Types of Cursors Supported in PL/SQL?
  3. What Is the Implicit Cursor?
  4. How To Use Attributes of the Implicit Cursor?
  5. How To Loop through Data Rows in the Implicit Curosr?
  6. How To Define an Explicit Cursor?
  7. How To Open and Close an Explicit Cursor?
  8. How To Retrieve Data from an Explicit Cursor?
  9. How To Retrieve Data from a Cursor to a RECORD?
  10. How To Use FETCH Statement in a Loop?
  11. How To Use an Explicit Cursor without OPEN Statements?
  12. Can Multiple Cursors Being Opened at the Same Time?
  13. How To Pass a Parameter to a Cursor?
  14. What Is a Cursor Variable?
  15. How To Define a Cursor Variable?
  16. How To Open a Cursor Variable?
  17. How To Loop through a Cursor Variable?
  18. How To Pass a Cursor Variable to a Procedure?
  19. Why Cursor Variables Are Easier to Use than Cursors?
A collection of 27 FAQs on Oracle loading data and exporting data. Clear answers are provided with tutorial exercises on saving data as flat files, loading data from flat, exporting and importing database, schema and tables, creating external tables.
  1. What Is the Simplest Tool to Run Commands on Oracle Servers?
  2. What Is the Quickest Way to Export a Table to a Flat File?
  3. How To Export Data with a Field Delimiter?
  4. What Is SQL*Loader?
  5. What Is a SQL*Loader Control File?
  6. How To Load Data with SQL*Loader?
  7. What Is an External Table?
  8. How To Load Data through External Tables?
  9. What Are the Restrictions on External Table Columns?
  10. What Is a Directory Object?
  11. How To Define an External Table in a Text File?
  12. How To Run Queries on External Tables?
  13. How To Load Data from External Tables to Regular Tables?
  14. What Is the Data Pump Export Utility?
  15. What Is the Data Pump Import Utility?
  16. How To Invoke the Data Pump Export Utility?
  17. How To Invoke the Data Pump Import Utility?
  18. What Are Data Pump Export and Import Modes?
  19. How To Estimate Disk Space Needed for an Export Job?
  20. How To Do a Full Database Export?
  21. Where Is the Export Dump File Located?
  22. How To Export Your Own Schema?
  23. How To Export Several Tables Together?
  24. What Happens If the Imported Table Already Exists?
  25. How To Import One Table Back from a Dump File?
  26. What Are the Original Export and Import Utilities?
  27. How To Invoke Original Export/Import Utilities?
A collection of 9 FAQs on Oracle ODBC drivers and connections. Clear answers are provided with tutorial exercises on installing Oracle ODBC drivers; TNS settings; defining DSN entries; connecting MS Access or ASP pages to Oracle servers.
  1. What Is Open Database Communication (ODBC)?
  2. How To Install Oracle ODBC Drivers?
  3. How To Find Out What Oracle ODBC Drivers Are Installed?
  4. How Can Windows Applications Connect to Oracle Servers?
  5. How To Create Tables for ODBC Connection Testing?
  6. How To Verify Oracle TNS Settings?
  7. How To Define a Data Source Name (DSN) in ODBC Manager?
  8. How To Connect MS Access to Oracle Servers?
  9. How To Connect ASP Pages to Oracle Servers?