2004.8.5 Thursday
Today, start close contact with the Oracle database.
Oracle is the world's second day of software, in addition to Oracle Database, developed a database operating tool, ERP and other products. As a database of NO.1, admiring has been admiring. In the market, the use of the use of the appraisal, the DBA position is also hot in his eyes. Teacher Zhao, who is Oracle is a senior Oracle expert. I have to meet a lilist, it is lucky!
Oracle Database has passed multiple versions, 89 8i, 97 years of 97 years, 9i (9.2.0) in 2001, we learn and use 9i. That is, from this, Oracle began to fully support all SQL statements. SQL is a non-pro-processed language that can only be manipulated from statements.
Oracle speaking five days, learning from the Java editing process involves the Oracle part. Teacher Zhao introduced the content of our study is one tenth of DBA. I have sent two textbooks: an exercise, a courseware. Courseware is a standard Oracle training courseware, all English. The courseware is just a skeleton. It is difficult to form a complete thing, but by Mr. Zhao explained that the content of the courseware is immediately filled with flesh and fresh. Even thinking, these coursewares and class notes, they are precious working materials!
Today, two chapters, introduced the Oracle's background, some operational statements in SQL Plus, and part of the first SQL statement. DBA textbooks have two books, one of which is related to SELECT. The SELECT of the fourteen SQL statements will cost such a space, which is important.
The exercises were practiced in three or a half in the class, and the content of the day was digested on the same day.
2004.8.6 Friday sunny
Today's progress is higher than yesterday, telling the seventh chapter, has passed half of the whole courseware. Teacher Zhao said: Tomorrow weekend, you can exercise these two days. These two months have fully studied, and it is not too late to find a good job. Our tuition is 12,000, 840 hours, from 9:30 in the morning, from 3 to 5:30, it is almost seven hours a day. With a just learned statement: SELECT 12000 / (840/7) from dual, 乖, one hundred oceans every day, Teacher Zhao said. How to don't be with your own Money :)
The content of these chapters is Single Row Functions, changing the field type, display format, and some numerical calculations (plus, subtraction, multiplication, division, surplus, filling). In the date of display format, the date is a problem, using English, month, month, the first Monday after a week, and the first few days of one month.
Chapter 4 shows data from multiple tables. Equijoin, Non-Equijion, Outor Join, and Self Join. Teacher Zhao said that Outer Join is a question that is often asked in the interview. These JOINs are different on the statement: Equijoin applies to the primary bond in two tables; Non-Equijion does not correspond to the main key, but the content has other correspondence (Join Condition Contains An Oser Than Equal). If there is no content in the two tables in Join, there is no content in the corresponding field. It is Outer Join situation. Which is less, where WHER is placed in the field "( )", and the self join is just Join Both tables are the same table (logically look at two tables).
There are Single with Group: AVG, Max, Count, Sum, Min. Use these five Functions when SELECT can make Group Operator. If SELECT follows a single column name, the column name must appear in the group BY statement, and it is not necessarily. After WHERE, you can't use Having if you want to filter with Group functions. As for the Sub Query of the sixth chapter, the variables in the statement in Chapter 7 are simpler, and there is no two chapters in the exercise.
In the class, Teacher Zhao is an active atmosphere, deliberately asking some questions, let us say the answer and propose bet. If you lose, please eat. Oh, free dinner, I like it!
2004-8-8 Sunday sunny
In the bright sunshine, the Suzhou River near the Suzhou River is like a dark satin, and it is like a gorgeous scarf that is like the wonderful breast, and the Huangpu has a style. Running or one or two ships drive, scarves are polite scales. The basket bridge is woven on the river: a hurried crowd, rolling forward wheel, summer Suzhou river, therefore, vivid. There is a 10-storey residential building in the distance. There is a large area of the fourth floor. There are some roof gardens: someone in the shade wear sunglasses and watched the magazine, next to the table, just drink halfway Drink. There are a few floral green swimsuits in the swimming pool. There is a child in a happy play. The surrounded by this building is surrounded by some short buildings, and there is similar view from the distance. Standing in the top floor of science and technology, the advertising words of the high-rise building are clearly identified.
When I was tired, I like it a long time. Hold a glass of water and look at the distance. The wind is blown slightly, and his thoughts traveled in the building. Thinking, or don't want anything. The sun is mildly illuminated on the body, in the air-conditioned room, and the sun in the summer has also become warm.
In the warm sun, a plane is overwhelming in the sky. The Suzhou River is slowly flowing on the ground. The aircraft has established heads, and the river flows into the sea. Do yourself? From Jiangxi to Shenzhen and to Shanghai, the heart always floats the kite in the sky. Walk all the way and look for it all the way. Where is the right line? Want to catch what, many years have passed, both hands are still empty.
The sun is gradually hot, or go back to the classroom, continue to read.
"After two days of rest, everyone is not bad" (Zhao teacher language), the colorful thing today's learning task is not heavy. After the eighth and nine chapters, practiced at 3:30 in the afternoon. When you finish your homework, looked at everyone's picture, I believe that many students are saying: com on, come on, oracle!
Chapter VII Testing Data Model Preview and Database Design, all conceptual things. Entity corresponds to table, Attribute corresponding column. Relationship Types is: one-on-one (at this time, the two tables can be used to synthesize a table, very small); multi-to-one (used upstream); multiple-to-many (more) To one relationship). Oracle Database Fractions Three Paradigm: The first paradigm property (typing) must be single value; second paradigm: other fields are dependent on the primary key; third paradigm: There is no dependency between other fields. In addition, Chapter 8 is a big step in how to convert the Entity to Table.
The detailed usage of the SELECT statement is lectured, how is the table created by the content of SELECT? Chapter 9: Table Name, Column Name, Column Type, more important is Constraint. There are also five constraints of Primary Key, Foreign Key, Unique (unique), NOT NULL (non-empty), Check (primary key). CONSTRAINT is directly constraint for Column Level after Column Name, such as after all fields and a comma, is Table Level. Two levels set some details, and the two fields must be set on the Table Level. There is a time to turn over the "programmer" magazine, find two good books perhaps: "Oracle 9i Beginner Guide" (very suitable for beginners), "Oracle Expert Advanced Programming" (a classic of Oracle successfully developed applications It is recommended to read the original version of the English).
2004-8-10 Tuesday
Today and Yesterday's learning progress, such as walking, yesterday is a leisure, and today is three steps and two steps. Let us first understand the number of chapters: Chapter 11, Chapter 12, Chapter 14, Chapter 15. The Chapter 13 and Chapter 16 is not too important. The tutorials issued did not, and Teacher Zhao shared an electronic version.
Chapter 11: Describes how to operate data, and the operation command has the following:
INSERT: INSERT INTO TABLE [(Column [, Column ...])] VALUES (Value [, Value ...]); Update: Update Table Set Column = Value [, Column = Value] [WHERE CONDition]; Delete: Delete [from] Table [Where condition];
Only the above three commands have submitted (strital) and rollback. If not submit, the above operation only changes the display content of the current session. Rollback can set back the scrollback point (SavePoint Marker) and returned via Rollback to Marker.
Chapter 12 speaks to modify the table and constraint, and the command is not familiar, and it is good to summarize it. The first is what object can be modified:
1. For ALTER TABLE Allow modification: 1) Increase and modify the line (add value type width, accuracy; null or no records to reduce column width; field without null value allows to increase non-empty constraints by modifying rows); 2) increase Or remove constraints (constraints can be modified? Cannot be); 3) makes the constraint effective or invalid. 2. Delete the structure and data of a table; 3. Other Rename, Truncate (Remove Table Records simultaneously release the occupancy space) and the Comment (object to table) is less important.
Understand the content frame, then look at the specific syntax:
1. ALTER TABLE TABLE ADD (Column Dattype [DEFAULT EXPR] [NOT NULL] [NULL] ...); 2. Alter Table Table Modify (Column Dattype [Default Expr] [NOT NULL] [, Column DataType]. ..); 3. ALTER TABLE TABLE ADD [Constraint Constraint] TYPE (Column); 4. Alter Table Table Drop [Constraint Constraint]; 5. Alter Table Table Disable (Enable) [Constraint Constraint];
Try to link these statements to the previous content, :) Then we create a view. What is a view? Teacher Zhao asked. Mirror? Soft connection? It turned out to be a SELECT statement. Creating a view of the VIEW from the Creative Table content framework comes from the SubQuery class. But modifying View is different, using Create or Replace. Display view data operation is the same.
Chapter 15 describes indexing, field constraints, automatically establish an index for this field when the primary key and the unique value are automatically created, and the index can be created.
The difference between the second day of the diary, you should be able to feel the richness of learning content today! Today's content is digested. In addition, how do you operate Oracle in actual work?
2004-8-11 Tuesday
"How did the computer learn?", Teacher Zhao asked.
"The computer is practicing!", The same is in the same way.
How to think about advertising? Oh, after the Oracle small project of the day, this is our true feeling.
The project is a construction of the recording rental system database. Establish a table, constraint, add field, create a sequence, entry data, and query the created object from the data dictionary and retrieve inserted data. Finally, a report is issued through a script. This seemingly simple project is organically linked to Oracle knowledge of the previous four days.
A total of five reports: Title record basic information; title_copy records the rental status; Rental records the rental time; the reservation log reservation; the MEMBER table records customer information. Table Instance Charts generated by ERD graphs has been given, we only need to build a table directly.
The harvest comes from setbacks. The eight topic of the project is a ring. The COPY_ID of the Rental Table, Title_ID is the main foreign key relationship with the corresponding field of the Title_Copy table. Initially set up the COPY_ID field of the Rental table, how to make the primary key is a unique key. OK, add the COPY_ID field of the title_copy table with Unique Constraint. The table is built and then inserts the data. One table, two tables ... can't insert data? How is it still a table title_copy? Day, the sample data COPY_ID actually has a repetition value. Remove the Unique Constraint, and the Rental table cannot be established. Do not delete, the data cannot be entered. Before and back, it is not necessary, this ..., the joint foreign key is the first to be difficult.
Another detail from the Price field for the Title table adds non-empty constraints. Use Alter Table Table Add [Constraint Constraint]. Carefully Search on Chapter 12, the NOT NULL constraint is completed when modifying the field. God, this is not that Teacher Zhao emphasized in the classroom.
After a hurry to complete the project, there is a matter of mood to make a more careful test. Why is the rental status not directly written to the title table, save it with a title_copy table because there is a number of copies in the same tape. The Title_copy is used in the Title_ID and COPY_ID in the table to be unique. This is the same, the book rent is not the same?