operations

package
v0.0.0-...-fb6f9e2 Latest Latest
Warning

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

Go to latest
Published: Sep 19, 2024 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateOne

func CreateOne(db *mongo.Database, collectionName string, doc interface{}) error

CreateOne inserts a single document into the specified collection.

func DeleteAll

func DeleteAll(db *mongo.Database, collectionName string, filter interface{}) error

func DeleteOne

func DeleteOne(db *mongo.Database, collectionName string, filter interface{}) error

func ReadAll

func ReadAll(db *mongo.Database, collectionName string, results interface{}) error

func ReadOne

func ReadOne(db *mongo.Database, collectionName string, filter interface{}, result interface{}) error

func Update

func Update(db *mongo.Database, collectionName string, filter interface{}, update interface{}) error

Update modifies an existing document in the specified collection based on the filter and update parameters.

Types

This section is empty.

Jump to

Keyboard shortcuts

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