example

package
v0.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 11, 2022 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func InsertManyByM

func InsertManyByM(ctx context.Context, db *mongo.Database) ([]string, error)

func InsertOneByD

func InsertOneByD(ctx context.Context, db *mongo.Database) (string, error)

func InsertOneByM

func InsertOneByM(ctx context.Context, db *mongo.Database) (string, error)

func InsertOneByMap

func InsertOneByMap(ctx context.Context, db *mongo.Database) (string, error)

func InsertOneByStruct

func InsertOneByStruct(ctx context.Context, db *mongo.Database) (string, error)

func QueryOneByNothing

func QueryOneByNothing(ctx context.Context, db *mongo.Database) error

func QueryOneByNothingDesc

func QueryOneByNothingDesc(ctx context.Context, db *mongo.Database) error

func QueryOneByNothingMulSort

func QueryOneByNothingMulSort(ctx context.Context, db *mongo.Database) error

func UpdateDocOrInsert

func UpdateDocOrInsert(ctx context.Context, db *mongo.Database) error

Types

type Person

type Person struct {
	Name     string `json:"name" bson:"Bname"`
	Age      int    `json:"age"`
	LiveCity string `json:"livecity111"`
	// contains filtered or unexported fields
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL