Database.function() method
Home > @direct-sqlite/core > Database > function
Database.function() method
Section titled “Database.function() method”Binds a custom JavaScript runtime algorithm which is directly executable in SQL queries.
Signature:
function(name: string, callback: (...args: any[]) => any): this;Parameters
Section titled “Parameters”|
Parameter |
Type |
Description |
|---|---|---|
|
name |
string |
The name of the function to register. |
|
callback |
(…args: any[]) => any |
The function to be called when the SQL function is invoked. |
Returns:
this