MySQL dual database construction
1. Build MySQL master-slave database
Refer to another blog post of the authorhttps://blog.csdn.net/weixin_37838921/article/details/104033403
2.MySQL dual machine environment
role
IP
OS/MySQL version
master1
192.168.11.10
CentOS7 / MySQL5.7
master2
192.168.11.30
CentOS7 / MySQL5.7
3. MyS ...
Posted by thegreatone2176 on Mon, 20 Jan 2020 09:33:42 +0100
mysql is the master-slave copy of each other
Master-1: 192.169.7.242
Master-2: 192.169.0.197
MySQL version: mysql-5.7
1. Modification and description of MySQL configuration file
Modify mysql of the two nodes respectively. Here, modify the configuration file to / etc/my.cnf
Modify Master-1 as follows:
# For advice on how to change sett ...
Posted by cybersurfur on Sun, 19 Jan 2020 10:28:59 +0100
Mybatis source learning (25)-StatementHandler parsing
I. Introduction
The StatementHandler is one of the most core interfaces of Mybatis. He has completed the work related to the interaction between Mybatis and database (the interaction between Mybatis and JDBC on Statement). StatementHandler is mainly used for:
Create Statement object
Bind ...
Posted by robsgaming on Sat, 18 Jan 2020 07:07:33 +0100
Python Crash Course Reading Notes - Chapter 6: DICTIONARIES
A dictionary in Python is a collection of key:value pair s.Similar to Map or lookup table s in other languages.
The key must be a string, and the value can be any object.
Both key and value can use variables.
Simple Dictionary
student = {'name': 'tony', 'age': 14}
print(student ['name'])
print(studen ...
Posted by Mortier on Thu, 16 Jan 2020 02:10:34 +0100
JDBC principle and basic operation
1. JDBC principle
1. JDBC API: provides various operation providers, connection statement Preparedstatement resultset;
2. JDBC Driver Manager: manage different data drivers;
3. All kinds of database drivers: database drivers provided by corresponding database manufacturers, which link to directly oper ...
Posted by TapeGun007 on Mon, 13 Jan 2020 14:06:30 +0100
Consumption and simple optimization of the number of Oracle database connections
Observe the indicators and check the connection consumption
--View session session:
select * from v$session where username is not null
select username,count(username) from v$session where username is not null group by username
--View current connections
select count(*) from v$process;
--View maximu ...
Posted by Sulman on Mon, 13 Jan 2020 12:49:36 +0100
SQL: A pit for inserting data
Inserting data is often required in SQL Server, whether stored procedures or custom functions.When inserting data, many people choose the following
INSERT INTO DestinationTable
SELECT Column1,Column2,<column3 ,>
FROM SourceTable
This insertion usually doesn't cause any problems, but when the table fields of the Destinat ...
Posted by wolfrat on Fri, 10 Jan 2020 19:23:06 +0100
Work summary - get the sub nodes of the tree and copy the tree
1: Structure of tree nodes
class KprDimension{
private String id; //Current node id of the tree
private String name; //Tree node name
private String parentId;// Tree node parent id
private Integer level; //The node level of the tree, as shown in the figure below, A is 1, B,C is 2
private List<KprDimension> children;// ...
Posted by porrascarlos80 on Fri, 10 Jan 2020 09:04:15 +0100
A detailed explanation of the usage of execute immediate and DBMS SQL
1. Use scenario
Both DBMS SQL package and EXECUTE IMMEDIATE in oracle can be used to parse and execute / dynamic SQL statements or PL/SQL blocks created at non runtime. In comparison, EXECUTE IMMEDIATE is relatively simple to use and can meet more common needs.
1.1 basic data
CREATE TABLE stu(
ID NUMBER(10),
xm V ...
Posted by nova on Sun, 05 Jan 2020 13:40:36 +0100
Scala notes (5): MySQL database configuration and scala programming
MySQL database installation configuration
In order to see / operate the database easily and intuitively, Navicat Premium software is generally installed to support multiple databases.
There is not much nonsense in the installation process, mainly referring to the following connections, no pit in hand test, which are the main ...
Posted by aleph_x on Sat, 04 Jan 2020 02:29:12 +0100