|
| typedef unspecified type | string |
| | string will be std::u16string or std::32string if NANODBC_ENABLE_UNICODE defined.
|
| |
|
typedef unspecified type | null_type |
| | null_type will be int64_t for 64-bit compilations, otherwise long.
|
| |
|
template<typename T > |
| using | is_string = std::bool_constant< std::is_same_v< std::decay_t< T >, std::string >||std::is_same_v< std::decay_t< T >, wide_string >||std::is_same_v< std::decay_t< T >, std::string_view >||std::is_same_v< std::decay_t< T >, wide_string_view > > |
| | A type trait for testing if a type is a std::basic_string compatible with the current nanodbc configuration.
|
| |
| template<typename T > |
| using | is_owning_string = std::bool_constant< std::is_same_v< std::decay_t< T >, std::string >||std::is_same_v< std::decay_t< T >, wide_string > > |
| | A type trait for testing if a type is a string owning the characters it holds.
|
| |
|
template<typename T > |
| using | is_character = std::bool_constant< std::is_same_v< std::decay_t< T >, std::string::value_type >||std::is_same_v< std::decay_t< T >, wide_char_t > > |
| | A type trait for testing if a type is a character compatible with the current nanodbc configuration.
|
| |
|
template<typename T > |
| using | enable_if_string = std::enable_if_t< is_string_v< T > > |
| | Enables an overload only for the string types nanodbc binds as strings.
|
| |
|
template<typename T > |
| using | enable_if_character = std::enable_if_t< is_character_v< T > > |
| | Enables an overload only for the character types nanodbc binds as strings.
|
| |
|
|
result_iterator | begin (result &r) |
| | Returns an iterator to the beginning of the given result set.
|
| |
| result_iterator | end (result &) noexcept |
| | Returns an iterator to the end of a result set.
|
| |
|
std::list< driver > | list_drivers () |
| | Returns a list of ODBC drivers on your system.
|
| |
|
std::list< datasource > | list_datasources () |
| | Returns a list of ODBC data sources on your system.
|
| |
| result | execute (connection &conn, string const &query, long batch_operations=1, long timeout=0) |
| | Immediately opens, prepares, and executes the given query directly on the given connection.
|
| |
| void | just_execute (connection &conn, string const &query, long batch_operations=1, long timeout=0) |
| | Opens, prepares, and executes query directly without creating result object.
|
| |
| template<class Rows , class... Accessors> |
| void | bind_rows (statement &stmt, Rows const &rows, Accessors const &... accessors) |
| | Binds a range of rows, a parameter at a time.
|
| |
| result | execute (statement &stmt, long batch_operations=1) |
| | Execute the previously prepared query now.
|
| |
| void | just_execute (statement &stmt, long batch_operations=1) |
| | Execute the previously prepared query now and without creating result object.
|
| |
| result | transact (statement &stmt, long batch_operations) |
| | Execute the previously prepared query now.
|
| |
| void | just_transact (statement &stmt, long batch_operations) |
| | Execute the previously prepared query now and without creating result object.
|
| |
| void | prepare (statement &stmt, string const &query, long timeout=0) |
| | Prepares the given statement to execute on it associated connection.
|
| |
The entirety of nanodbc can be found within this one namespace.
- Note
- This library does not make any exception safety guarantees, but should work just fine with a threading enabled ODBC driver. If you want to use nanodbc objects in threads I recommend each thread keep their own connection to the database. Otherwise you must synchronize any access to nanodbc objects.