1. Group function Usage Rules
Group functions in MySQL can be used at will in a SELECT statement, but in Oracle if there is a group function in the query, the other column names must be processed by the group function, or the column in the GROUP BY
The most basic Oracle database connection code (for oracle11g only):
1, right key project-> build path-> Configuration build path, select the third "library", then click "Add External Jar", select "D:\Oracle\app\oracle\product\11.2.0\server
The examples in this article describe the Java-derived classes for MySQL and Oracle links. Share to everyone for your reference. as follows:
Import java.sql.Connection;
Import Java.sql.DriverManager;
Import java.sql.SQLException; public class
To build an Oracle, there will be many schemas below, and no data under each schema is affected.
Feel and MySQL library concept is very similar, now use the database management system is in fact so divided, MySQL with the ip+port+ library
Oracle's Own backups
Until now, many developers have recognized the potential of RMAN and its usefulness as a database backup tool. You may recall that RMAN can back up data directly to disk and tape. When a tape solution is involved, RMAN
ORA-00604 error occurred at recursive SQL level string
Cause:an error occurred while processing a recursive SQL statement (a statement applying to internal dictionary tables).
Action:if the situation described in the next error on the stack can is
The Oracle 11GR2 database has recently been installed on the Red Hat 6.6 virtual machine and is installed with no problem, and the host can access the database on the virtual machine. However, after restarting the virtual machine, the host cannot
1. View the top 10 SQL statements with the most total consumed timeSELECT * FROM (select v.sql_id, V.child_number, V.sql_text, V.elapsed_time, V.cpu_time, V.disk_reads, Rank () Over (o Rder by v.elapsed_time Desc) Elapsed_rank from V$sql v) a where
Some points to note about Oracle compatibility with MySQL: To_char: Convert to String type :to_char (1234.5, ' $9999.9 '), result :$1234.5 To_date: Convert to date type :to_date (' 1980-01-01 ', ' yyyy-mm-dd '), result :01-1 month
Oracle Practice Exercises 1.0February 10, 2017 Friday 9:07:221, list the IT industry database types and user distribution2. List some products commonly used by Oracle Company3. Brief description of Oracle database software, databases, instances, and
Trunc,to_char,round,cast1.trunc intercept the number, the decimal place directly, the whole digit takes 0. Do not make roundingThe second argument is the number of bits to intercept, and if it is not an integer, only the integer digits.2.to_char (),
Syntax for adding a field: ALTER TABLE tablename Add (column datatype [default value][null/not null],....);Modify the syntax of the field: ALTER TABLE tablename modify (column datatype [default value][null/not null],....);Syntax for deleting a field:
In connection with the database, sometimes encountered a "ORA12514: Listener currently does not recognize the service requested by the connection descriptor" error, which is actually the database dynamic registration (about dynamic registration will
--View the use/remaining space of temporary filesSql> select * from V$temp_space_header;--View the temporary tablespace to which the Scott user belongsSql> Select Username, temporary_tablespace from dba_userswhere username= ' SCOTT '; --See which
Oracle Database automatic Backup implementation effect
Export DMP format files using the Oracle EXP command;
Automatically compress DMP files using 7z command line to reduce storage space;
Use Windows timed tasks to automatically
--View Current User select Username from dba_users;--Creating a temporary create USER GZMPC identified by PASSWORD;--authorizing Grant CREATE SESSION to GZMPC; CREATE tablespace gzmoc_wk datafile'Gzmoc_wk.dat'SIZE 10M autoextend on; CREATE temporary
E:\>exp help=y By entering the EXP command and username/password, you canCommands after the user/password: Example: EXP Scott/tiger Alternatively, you can control how export runs by entering an EXP command with various parameters.To specify
Directory + 1. Overview of database Security control policies + 2. User Management + 3. Resource Restriction and password management + 4. Rights Management + 5. Role Management + 6. Audit 1. Overview of database Security control policies Security
--Simple conditional judgment if–then--write a procedure that can enter an employee's name and, if the employee's salary is less than 2000, increase the employee's salary by 10%. Create or Replace procedure Sp_pro6 (spname varchar2) is--Define V_sal
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service