In order to learn the SQL statements of the database, after a long wait and learning, I finally learned how to use Oracle 10 Gb to learn the SQL statements of the database over the past few days.
Required Software: Oracle 10g, TOAD for Oracle
The installation of Oracle10g is very simple. Before installation, it is best to set the computer name in advance (if you do not use other visual interfaces, you can only access and operate the database in the DOS environment or through a browser. If you access it through a browser, the computer name is required. I personally use my name YeahuiLau to change the computer name. In this way, the access process is convenient and you do not need to right-click and copy and paste the computer name ). Note the following two points during installation:
First, the global database name. If you create multiple databases, it is recommended that the name be easily remembered. In the future, it will be easier to connect and use. The default name is orcl.
2. Password (User Password ). Because there are many users after the database is created: sys, system, scott, etc. It is best to have the same password, otherwise the corresponding user will not be able to log on. During the installation process, the initial password is the one I often use. At the end of the installation process, there is a "password management" button. You 'd better click to enter password management, open all users and select "all users use the same password" at the bottom ".
To achieve these two points, the installation and access are basically no problem.
The following are database operations. If you do not need other tools, you can use the following methods. 1. Open "run" and enter the command "sqlplus" to perform the operation in DOS. 2. Open "run" and enter "sqlplusw ", this is running on the console, and there is a blank interface; 3. choose Start> program> Oracle OraDb10g_home1> Application Development> SQL Plus ". In fact, these three methods are similar. They are essentially performed under SQL Plus, and the operation commands are the same. However, I do not like to use these methods. I prefer to operate on the visual interface. In class, I saw that the database teacher (very young, only 30 years old) is not using DOS and "SQL Plus ". Back to the dormitory, I have been pondering for a long time, and I checked a lot of information online. I used to use "TOAD for Oracle ". So I downloaded a "TOAD for Oracle 10.5" online and installed it twice. The installation process is relatively simple, basically "next". If something cannot be installed, just remove it. In fact, we are currently using "TOAD for Oracle ".
After the installation is complete, check whether the Oracle service is started. Double-click the "TOAD for Oracle" shortcut (the first time you start something like a registration code, www.bkjia.com, you just need to find it .) Now you are logged on. The user I log on to is "system", and the password is of course set by me. Select the database you want to connect to. What I connect to is "orcl", OK! After completing these steps, you will start to train your SQL statements! A large blank area in the middle is used to input statements for you, and a running button is displayed in the upper left corner of the section. Click to execute the SQL statement. For example, if you have created a table "account" and input "select * from account", all the ancestors in the account will be displayed at the bottom!
Friendly reminder: If Oracle services are enabled all the time, our operating system will run slowly. We recommend that you stop Oracle services when you do not need them. The procedure is as follows: Right-click "my computer"-> "manage" (my system is still XP) -> double-click "service and application"-> double-click "service" (we recommend that you send the "service" shortcut to the desktop to avoid looking for it later ), now all the services on your computer are turned on, and you stop all the services that contain Oracle, which has no impact on the speed of your computer. Start Oracle again when you want to learn SQL. It mainly starts the following items: OracleServiceORCL, OracleOraDb10g_home1TNSListener, OracleOraDb10g_home1iSQL * Plus, OracleDBConsoleorcl, and OracleCSService. It is best to set the "Startup Type" to "Manual" (usually automatic by default, usually boot), and the remaining Oracle services can be set to "disabled ".
OK! The lab platform for simple SQL statements has been set up! Exercise now! The younger brother has a poor foundation and has incorrect understanding. If you have any mistakes, please give us your guidance. Thank you!