Database: sql recursion

mysql self association table, the following are examples of downward recursion and upward recursion. 1. Prepare for recursive query. If your table already exists, this step can be ignored. Building tables CREATE TABLE `wq_areainfo` ( `id` int(11) NOT null AUTO_INCREMENT, `level` int(11) DEFAULT 0 , `name` varchar(255) ...

Added by sford999 on Thu, 02 Jan 2020 02:39:13 +0200

Nine built-in objects and scopes of jsp

1. pageContext saves data in only one page <body> <% // Set the data key - > value of two page ranges pageContext.setAttribute("name","page Wang Er Xiao"); pageContext.setAttribute("age",12); %> <% // Value String name=(String)pageContext.getAttribute("name"); int age=(Integer)pageContext.getAttribute(" ...

Added by vexious on Thu, 02 Jan 2020 00:30:39 +0200

linux implements mysql read-write separation based on proxy

** mysql-proxy ** A powerful function of MySQL Proxy is to realize "read-write separation". The basic principle is to let the main database handle write transactions and the slave database handle SELECT queries. Amoeba for MySQL is an excellent middleware software, which can also achieve read-write separation, l ...

Added by GM on Wed, 01 Jan 2020 15:46:20 +0200

linux formatted text output

There is no standardized format for Linux text output, which is not easy to watch. Today, I have studied the following format: awk; awk  '{printf "%-18s%-8s%-8s%-8s%-55s%-30s%-50s\n",$1,$2,$3,$4,$5,$6,$7}'  cpu.log > cpu_$tsSuf.log   If you want to modify the source file in the shell, you can export it to a temporary file ...

Added by Moharo on Wed, 01 Jan 2020 12:22:53 +0200

20180822  Java database connection, some introduction of using jdbc programming

  Basic concepts of jdbc Java database connection is a set of api interface provided by Java. It accesses different databases (mysql, oracle, sqlserver) in a consistent way java.sql.* java.sql.Driver driver (how to connect to the database) java.sql.Connection connection (represents the connection channel between java progr ...

Added by JoeBrewer on Wed, 01 Jan 2020 03:30:18 +0200

Find in set() function of MySQL

Grammatical explanation FIND_IN_SET(str,strlist) str is the string or field to query;strlist can be a list of fields and characters, multiple strings must be separated by commas, for example: '1,2,e,t'. The function is to query whether str is included in strlist, and return null or record. If the string str is in the string list strlist compose ...

Added by thom2002 on Mon, 30 Dec 2019 20:27:18 +0200

springboot -- multiple data sources

This paper mainly introduces how to configure two data sources (mysql and oracle) in a spring boot project; 1. Import related dependence <!-- https://mvnrepository.com/artifact/mysql/mysql-connector-java --> <dependency> <groupId>mysql</groupId> <artifactId>mysql-connector-java</artifactId> <s ...

Added by DjNaF on Sun, 29 Dec 2019 19:42:04 +0200

mysql export and import table structure

--Using mysql's mysql dump to export and import table structure --The command is as follows: mysqldump -d -h localhost -u root -pmypassword databasename > dumpfile.sql --Where - d means to export only table structure, not data, - h means host, - u means user, - p means password database means to export that database, and d ...

Added by geordie on Sun, 29 Dec 2019 18:56:04 +0200

Building PHP Configuration for LMAP Architecture (Final)

[TOC] Article Directory 1. Introduction to PHP 2. Preparations before installation 3. Manual Compilation and Installation of PHP IV. Installation Process of Forum 1. Introduction to PHP PHP, which is used to interpret dynamic Web page files, provides a development and running environment for Web applications. PHP is a widely used open source, ...

Added by katuki on Fri, 27 Dec 2019 22:18:53 +0200

LNMP Environment Setup (PHP 7.4.0)

Catalog Dead work Install wget Install net-tools Install vim Configure Display Line Number Close Firewall Install Nginx Installation Dependency Compile and install Nginx Configuring environment variables Systemd Management Install M ...

Added by terryl on Fri, 27 Dec 2019 04:51:09 +0200