OXY API 1.0
OXY API Library Documentation
Loading...
Searching...
No Matches
oxy::context::copy_fn Struct Reference

A function object that copies rows from one database context to a specified path, with optional column selection. More...

#include <context.hpp>

Public Member Functions

void operator() (context_t const &from, std::string const &to_path, std::string const &column="*") const

Detailed Description

A function object that copies rows from one database context to a specified path, with optional column selection.

The copy_fn struct defines a function call operator that takes a source context_t, a target path, and an optional column selection string. It performs the operation of copying the rows from the source context to the specified path, allowing for selective copying of columns if desired. This is useful for exporting data or creating backups of specific parts of the database.

Member Function Documentation

◆ operator()()

void oxy::context::copy_fn::operator() ( context_t const & from,
std::string const & to_path,
std::string const & column = "*" ) const
Parameters
from- The source database context from which to copy rows.
to_path- The target path where the rows will be copied to.
column- A string specifying which columns to copy (default is "*", meaning all columns).