Skip to main content
The Deno 2 Release Candidate is here
Learn more
Module

x/aloedb/lib/database.ts>Database#updateOne

Light, Embeddable, NoSQL database for Deno 🦕
Latest
method Database.prototype.updateOne
import { Database } from "https://deno.land/x/aloedb@0.9.0/lib/database.ts";

Modifies an existing document that match search query.

Parameters

query: Query<Schema> | QueryFunction<Schema>

Document selection criteria.

update: Update<Schema> | UpdateFunction<Schema>

The modifications to apply.

Returns

Promise<Schema | null>

Found document with applied modifications.