Stored Procedures in Oracle:
/*
Create a storage function and return the name, salary, and annual income of the specified employee.
*/
Create or replace function queryEmp2 (eno in number, empname out VARCHAR2, empsal out NUMBER)
-- Returns the
Mysqladmin MySQL client management tool
Flush-hosts Flush all cached hosts (max_connect_errors)Refresh all information in host BufferFlush-logs Flush all logsRefresh all logsFlush-status Clear status variablesClear status variablesFlush-tables Flush
I. node information:Master1: 192.168.80.143/24 + CAMaster2: 192.168.80.144/24
The two nodes are the same as the master node and the slave of the other node.
Ii. Basic Configuration:
(1) mysql is installed on both servers.
# pvcreate /dev/sda5
Oracle 11g (11.2.0.1.0) has a bug. When the table has no data, no segment is assigned.
Solution:
1. insert a row and then roll back to generate a segment.
This method inserts data into an empty table and then deletes it, resulting in a segment. An
Cursor Concept
A cursor is a memory Workspace of SQL, which is defined by the system or user as a variable.
A cursor is used to temporarily store data blocks extracted from the database.
Why use a cursor? The data in the database is stored in the
I. Environment Description (using rsync for mysql Incremental Backup)
192.168.0.2 is the backup server.
192.168.0.3 is the mysql database that needs to be backed up frequently.
Ii. Main Configuration
1. Backup Server ConfigurationUseradd
Summary:
1. Are the data stored in the database (data files) consistent?
When the database is shut down, it should be consistent; when the database is shut down abnormally, it should be inconsistent; when the database is enabled, it may
Inconsistent
Oracle Database Connection and calling of Stored ProceduresCreate table chengji (id number, xing_ming varchar2 (25), yu_wen number, shu_xue number)-- Query All Information select * from chengji-- Stored procedure with no return value typeCreate
1 Definition
RBA is the address corresponding to redo entries in the redo log file.
2 components
RBA consists of three parts:
Serial number (4 bytes)
Block number (4 bytes)
Start byte (2 bytes)
All of the above are in hexadecimal storage.
3 type
3.1
For Oracle 11gR2 RAC best practices for adding nodes, see:OS information:[Grid @ 11grac1 ~] $ Uname-Linux 11grac1 2.6.32-300.10.1.el5uek #1 SMP Wed Feb 22 17:22:40 EST 2012 i686 i686 i386 GNU/LinuxDB information:SQL> select * from v $ version where
The Hash Index is based on the Hash table. It is only useful for exact search of each column in the Index. For each row, the storage engine calculates the indexed Hash Code, which is a small value and may be different from the Hash Code of other
Many systems only perform a flag when performing the delete operation, and do not perform operations that are as expensive as setting the disk to 0. The same is true for truncate. Only the segment header and I-node tables are changed. Truncate
After the system executes expdp export, alert. log reports the service name modification information, as follows: Wed Sep 05 02:09:29 2012Alter system set service_names = 'sys $ SYS. KUPC $ C_1_20120905020929.ZZBRAC3 'SCOPE = memory sid = 'zzbrac31 '
Today, when the company changed tomcat, the connection to the database failed. In the beginning, the password expired. Later, the password was changed from Oracle. When trying to connect, an error was reported that the password was locked, check the
I always thought that except rollup and cube, group by can be aggregated at different granularities according to the fields specified in the clause. There are no other methods. Today, another method is found because of the groupby bug (hash group B
When a customer updates data, the database content is deleted by mistake, because the database is master-slave, but not backup (backup is very important !) Fortunately, the bin-log is enabled, and the entire log record has to be taken back to the
A. Use impdp and network_link
1. Create a db link in the target databaseCreate public database link hrtestdb connect to system identified by 1234 using 'hrtestdb ';
Impdp system/1234 network_link = hrtestdb schemas = BMCCZHPUSR;
2. Create a
When I interviewed mysqldba, I encountered a question:
Describes the implementation principle of the msyql replication mechanism. How can I restore the database node of the slave with inconsistent data without stopping the mysql master
Test environment:System: LINUX-64Database: 10.2.0.1Two-node RAC: RACDB1, ASM used by RACDB2 Storage (1) Insert data without submittingRACDB1> insert into xuhm. test3 values (4, 'A '); There is an active transaction.RACDB1> select usn, xacts from v $
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