Calling stored procedures and functions using JDBC

Original Link: http://www.yiidian.com/jdbc/jdbc-callablestatement.html 1 CallableStatement interface The CallableStatement interface is used to call stored procedures and functions. By using stored procedures and functions, we can write business logic on the database, which will improve performance because they are precompiled. 2 What is the di ...

Posted by msurabbott on Wed, 18 Mar 2020 04:02:52 +0100

Summary of DDL, DML and DCL statements of MySQL relational database

Article brief introduction When learning relational database, the database in the textbook uses Oracle relational database, while I use MySQL database for other reasons. From the perspective of database type, both are relational databases, and there is not much difference in data access mode. But afte ...

Posted by Stickdragon on Wed, 12 Feb 2020 12:26:31 +0100

Type processor for Mybatis

When Mybatis sets a parameter in the prepared statement, it uses the default typeHandler for processing. When you want to search a person's information by name <select id="getRole" parameterType="string" resultRole="role"> select rolename,phonenumber from t_role where rolename = #{rolname} </select> When Mybatis calls this query ...

Posted by saco721 on Sat, 07 Dec 2019 09:33:27 +0100

Notes on the way to security: JDBC's defense against SQL injection

0x00 Preface This article records my way of learning, directly into the body. 0x01 text Why does SQL injection occur? For me, it will be summed up as one sentence: "the SQL statement executed by dynamic splicing contains untrusted data." What is dynamic splicing? Look at the following SQL ...

Posted by cgf2000 on Sun, 27 Oct 2019 03:06:19 +0100

Synchronize database information (stored procedure + cursor)

The project is basically based on the existing database for development, or expansion, basically encounter projects are more than 2 to 3 databases, headache. The basic or common way to do this is to write down the synchronization, such as the synchronization of employees, departments, roles, etc. My ...

Posted by xtopolis on Sat, 05 Oct 2019 11:07:21 +0200

Oracle Advanced Learning

Oracle Advanced Learning Paging 1,rowid rowid, which is generated and unchanged when creating records, is the unique identifier of physical location, pointing directly to the storage location on the hardware. ID is the only logical identifie ...

Posted by FraXTC on Wed, 28 Aug 2019 15:06:48 +0200

MySQL index optimization analysis 3-single table query optimization

MySQL Index Optimizing Analysis 3-Single Table Query for SQL Query Optimizing 1. Data preparation 1.1 Formulation 1.2 Setting parameter log_bin_trust_function_creators 1.3 Create SQL functions to ensure that each data is different 1.4 Create SQL ...

Posted by ezekiel on Thu, 22 Aug 2019 10:49:08 +0200

Control flow statement

To supplement the basic knowledge, part of the summary of commonly used process control statements 1 -- BEGIN... END: Execute multiple TSQL statements together BEGIN TRANSACTION SELECT @@TRANCOUNT--Transaction counting,Result 1 IF @@TRANCOUNT=0 BEGIN--Statement block start SELECT TOP 1 * FROM d ...

Posted by MockY on Wed, 31 Jul 2019 12:39:55 +0200

ORACLE 11g uses ROWNUM to perfect ORA-00600: internal error code

  1, ORA-00600: Internal error code Oracle upgraded from 11.2.0.1 to 11.2.0.4. Developers reported a job failure, debugging error messages, ORA-00600: internal error code, parameters: [rwoirw: check ret val], [], [], [], ORA-06512:... As shown in the following figure:   C:\pic\oracle\2017040501 ...

Posted by postmanager on Tue, 30 Jul 2019 08:56:41 +0200

PL/SQL Learning Section 2

Conllection Type PL/SQL has Collection Type: associative array] [1], VARRAY [(variable-size array)] [1], and nested table. All three declarations must be initialized, VARRAY and Nestes Table have constructors, and associative arraty [1] has no constructors. [[VARRAY] [1]: You can modify and initialize arrays with constructors or access them ...

Posted by airwinx on Mon, 15 Jul 2019 20:22:09 +0200