Recently I wanted to write a project, but can not start, because they have never used Oracle data development, use is used to all is foggy, see the Theory of knowledge is useless, only with hands-on practice to create the value of self, this road, combined with the network of their own slowly explore, research.
There are usually two ways to build a library in Oracle. The first is the use of Oracle's library tools DBCA, this is a graphical interface tool, easy to use and easily understood, because its interface friendly, beautiful, and the hint is also quite complete. In Windows systems, this tool can be opened in an Oracle program group ("Start"-"program"-"oracle-oradb10g_home1"-"Configuration and migration Tools"-"Database Configuration Assistant "), or you can open it by entering DBCA directly in the command line (start-run-cmd) tool. Another way is to build the library by hand, and I'll give you an example here.
Create manually
Creating a library by hand is a hassle, but it's a must for a developer or a professional DBA to have a better command of Oracle knowledge. Follow me here, step by step, it takes several steps to build a library manually, and every step is critical. It includes:
1, create the necessary relevant directory
2. Create initialization parameter file
3, set the environment variable Oracle_sid
4. Create an instance
5. Create password file
6, start the database to Nomount (instance) status
7. Execute the Library script
8. Execute catalog script Create data dictionary
9. Execute CATPROC Create Package Package
10, the implementation of PUPBLD
11. Create SPFile file by initialization parameter file
12. Execute Scott script to create Scott mode
The platform where I work
Experimental system platform: Windows 7 Database system version: Oracle database 11G
Oracle Installation path: Database name created in D disk: Book
1. Create the necessary relevant directory
Create a folder under installation directory: D:product11.1.0db_1adminbook
In D:product11.1.0db_1adminbook, create five folder Arch,bdump,cdump,create,udump.
Create a folder at the same time D:product11.1.0db_1oradatabook
The process of creating a table of contents can also be created in the graphical interface of Windows, and several subdirectories in the book directory are used primarily to keep track of the database while it is running. The most important two subdirectories are the Bdump and Udump directories, where the Bdump directory stores the tracking information for the various background processes that are running in the database, in which the alert file is a warning file and its filename is called Alert_ Book.log, when a database problem occurs, you can first view the file to find out why, and the various problems that arise during the manual creation process can often be found by looking at the file. Udump directory Storage and specific session-related tracking information.
2. Create initialization parameter file
When the database system starts, it needs to allocate memory with the setting of initialization parameter file, and start the necessary background process. Therefore, whether the initialization parameter file is created correctly and the parameter settings correctly relate to the "fate" of the entire library.
Creating an initialization parameter file can be done by copying the existing initialization parameter file and making the appropriate modifications so that you do not have to write it in one sentence by hand, because the structure of the initialization parameter file is basically the same. When we installed Oracle, the system has installed a database named ORCL for us, so we can get an initialization parameter file from it.