Look-MySQL database stored procedures

-Definition

A stored procedure is a piece of code (procedure) composed of SQL stored in the database.

A stored procedure is usually used to complete a piece of business logic, such as registration, payment of shifts, order storage, etc.

A function usually focuses on a certain function and is regarded as the service of other programs. It needs to call the function in other statements, and the stored procedure cannot be called by others. It is executed by itself through call.

-Create

CREATE PROCEDURE sp_name (parameter list)

过程体

Parameter list: different from the parameter list of the function, the parameter type needs to be specified

IN, said input type

OUT, said output type

INOUT, said hybrid

Note that there is no return value.

/* Stored procedure */

A stored procedure is a collection of executable code. Compared with functions, it is more inclined to business logic.

Call: CALL procedure name

-Attention

  • There is no return value.

  • Can only be called alone, not mixed in other statements

-Parameters

IN|OUT|INOUT parameter name data type

IN input: input data to the parameters inside the process body during the call

OUT output: in the call process, the result of the process body is returned to the client

INOUT input and output: both input and output

– Syntax

CREATE PROCEDURE procedure name (parameter list)

BEGIN

过程体

END

Insert picture description here
The above are some video resources I collected, which helped me a lot in this process. If you don't want to experience the feeling that you can't find the information during self-study, no one answers your questions, and insists on giving up after a few days, you can join our deduction group [313782132], which has various software testing resources and technical discussions.

Insert picture description here
Of course, there are interviews. Interviews are generally divided into technical and hr interviews. In terms of format, there are few group faces. A small number of companies may have an intersection, but in general, the technical aspect is basically an inspection of your professional and technical level. , then hr surface mainly to see the person's overall quality and family situation character does not meet company requirements, in general, technology, then as long as through the technical hr surface is basically no problem (there are a few companies hr face will brush a lot of people)
we Mainly speaking on the technical side, the technical side is mainly to examine the professional technical knowledge and level. The above are also selected interview questions I have compiled.

Come on, test man! If you need to improve your plan, do it. It's better to be on the road than to wait and see at the beginning. There must be a law, and then there will be success.

If the resources are good, give a recommendation~

Guess you like

Origin blog.csdn.net/weixin_50271247/article/details/108663988