Tag:Zhang San

  • About converting column values to column names in MySQL


    We sometimes have this need:This presentation related to column values is sometimes very intuitive. I will use a small demo to realize this kind of operation. Table structure create table demo1( Sname varchar (20) not null comment ‘student’, Course varchar (10) not null comment ‘account’, Score float not null comment ‘score’ ) Insert the following […]

  • Use of spring authorization server


    1、 Background staySpring Security 5It is not available nowAuthorization serverConfiguration, butAuthorization serverIn our usual development process, we still use more. However, the spring official provides a community driven authorization service led by the spring officialspring-authorization-serverAt present, it has reached version 0.1.2, but the project is still an experimental project and can not be used in […]

  • 41 skills that JS development must know [continuous update]


    preface JS is the core of the front end, but you may not know some skills;This paper combs 41 skills of JS to help you improve your skills in using JS;The article is a little long. You can clone the source code and directly roll up the source code addressPlease stamp all the source code, […]

  • Django: transaction


    Series articles: Solve the compatibility problem between Django 2.2 and MySQL Django: transaction Use of aggregation in Django Use of F function in Django Django blogs use markdown to automatically generate directories Sometimes we needPerform a series of operations on the database, if one of the operations fails, the other operations will be rolled back […]

  • How does golang operate excel?


    Introduction to key terms In order to get started quickly with the open source library, let’s first understand several key terms in Excel, as shown in the figure below. ① is sheet, that is, the tab in the table; ② Is row, representing a row in Excel; ③ Cell represents a cell in Excel. Under […]

  • Difference between export and export default


    I believe that many beginners will often see the use of export and export default when learning Vue, but what is the difference between the two? 1. Both export and export default can be used to export constants, functions, files, modules, etc\2. You can import it in other files or modules by means of import […]

  • Set, map data structure


    Set data structure ES6 provides a new data structure set. It is similar to an array, but the values of members are unique and there are no duplicate values. Set itself is a constructor used to generate a set data structure. const s = new Set() s. Add (1). Add (2). Add (1). Add (3) […]

  • [c#] usage and efficiency comparison of reflection


    Reflection instantiation class public class Person { public string Name { get; set; } public Person(string name) { this.Name = name; } public string Say(string msg) { return $”{Name}: {msg}”; } } class Program { //Number of tests const int count = 10000000; static void Main(string[] args) { CreateInstance0(); CreateInstance1(); CreateInstance2(); CreateInstance3(); CreateInstance4(); Console.Read(); } […]

  • MySQL transaction details summary and analysis [update]


    Transaction base route Transaction definition A transaction is a collection of DML statements. Transactions ensure the consistent operation of data in the database. Storage engine In daily development, our common storage engines include InnoDB and MyISAM. However, MyISAM does not support transaction operations. Transaction commit method Sample code CREATE TABLE `user` ( `id` int(10) UNSIGNED […]

  • MySQL shared lock, exclusive lock and automatic submission


    There are two kinds of locksShared lock: Select… Lock in share modeExclusive lock: Select… For update 1. Submit the exclusive lock manually Turn off MySQL auto commitSet autocommit = 0; Window 1 execute command mysql> select * from stu where id=1 for update; +—-+——+—–+———+ | id | name | num | version | +—-+——+—–+———+ |1 […]

  • Sub link query and special query of MySQL basic syntax (Union and limit)


    Subqueries and special queries (Union and limit) The syntax of sub query and special query in MySQL is summarized Subquery Sub queries are divided intoSubquery in where statement、Subquery in from statement、Subquery in select statement Because the subquery in the select statement is rarely used, the following tests only correspond to the subquery in the where […]