• Mongodb join table query


    Database table Table 1: data record table var mongoose = require(‘mongoose’), Schema = mongoose.Schema; var DocViewSchema = new Schema({ RealName: string, // real name User name: string, // OA account Count: number, // document statistics Docname: string, // document project name DOCTYPE: string, // document item type Orgpath: string, // the organization path of the […]

  • How to use type command in Linux system


    typeTools for displayingcommandType information for. It will be shown on thecommandEnter how the given command will be interpreted on the line. How to use the type command typeThe command is built-in to bash, and the type syntax is as follows: type [-afptP] [name …] For example, viewtypeThe type of [[email protected] ~]# type typetype is a […]

  • Mybatis dynamic mapping, this time I finally got it


    Focus on “Java back end technology stack” Reply to “interview” for full interview information Dynamic SQL is one of the powerful features of mybatis. If you have used JDBC or other similar frameworks, you should be able to understand how painful it is to splice SQL statements according to different conditions. For example, when splicing, […]

  • [ VB.NET Tips] to create an anonymous type list


    When calling some web APIs, you often need to send or receive some data, and you may need to create some classes when constructing JSON.Many of these classes are used only when calling related methods, so anonymous type is a good choice. If you want to transfer some table structure data, you need to create […]

  • Python function definition and parameter explanation


    Function definition First, we create a function that outputs Fibonacci series within a specified range. #!/usr/bin/env python #coding=utf-8 ”’ Created on September 4, 2016 2:37:31 PM @author: Flowsnow @file: D:/Workspaces/eclipse/HelloPython/main/FibonacciSeries.py @Function: define a function to output a fibrachian sequence within a given range ”’ def Fibonacci(n): #print “success” a=0 b=1 while a<n: print a, a,b=b,a+b […]

  • Some tips for swift development


    Selector import UIKit private extension Selector { static let open = #selector(TestViewController.open(sender:)) } class TestViewController: UIViewController { override func viewDidLoad() { super.viewDidLoad() let openBtn : UIButton = UIButton() openBtn.addTarget(self, action: .open, for: .touchUpInside) view.addSubview(openBtn) } @objc fileprivate func open(sender: UIButton) { } } useExtensionTo expand in a new waySelector, which will be used inSelectorIn this […]

  • JavaScript advanced (5)


    ES6 Es: full name ECMAScript, it is a standard specification of scripting language developed by ECMA International Organization for standardization. The so-called ES6 refers to the version after 2015 Let keyword New keyword of declaring variable in ES6 <!DOCTYPE html> <html lang=”en”> <head> <meta charset=”UTF-8″> The < title > let keyword declares variables < / […]

  • Final keyword and secure Publishing


    General understanding of final In Java, the final keyword can be used to modify classes, methods and variables (including member variables and local variables)You should all know that final means final, that is, it can’t continue The modifier class indicates that it cannot be inherited (string – all methods implicitly final); Modifying method means that […]

  • Sorting (exercise class)


    Which of the following sorting methods is to take out the elements from the unordered sequence, compare them with the elements in the sorted sequence, and put them in the correct position in the sorted sequence. (insert sort) The sequence 15,9,7,8,20, – 1,4 is sorted. If the sequence after one-time sorting is 9,15,7,8,20, – 1,4, […]

  • Two ways to create custom functions


    1. Use function keywords to create function named function Function fn () {/ / FN is a keyword } fn();   2. Creation of anonymous function – function expression Var FN = function (Num) {/ / FN is a variable name, not a function name //Functions are stored in FN, while values are stored in […]

  • Rust has questions and answers


    A series of articles: Rust has questions and answers What is cargo Rust has questions and answers What is toml in rust Q & A What can we learn from HelloWorld What is use Rust is the keyword of programming language. Using is the key word of programming language C #. Keyword is a predefined […]

  • New features of C × 8.0


    readonly member private struct Point { public Point(double x, double y) { X = x; Y = y; } private double X { get; set; } private double Y { get; set; } private readonly double Distance => Math.Sqrt(X * X + Y * Y); public override readonly string ToString() => $”({X}, {Y}) is {Distance} […]