Datasources

Overview

DBDataSources provides a way to access and interact with various database, in-memory, view, and stored procedure datasources in Servoy applications. Available through the datasources object, it includes dynamic code completion that aligns with the solution’s data model, providing flexibility and ease when working with different data sources.

For details related to datasources, refer to the specific sections in the Servoy documentation:

Returned Types

DBDataSource,MemDataSource,JSDataSource,JSConnectionDefinition,DBDataSourceServer,ViewDataSource,

Properties Summarized

TypeNameSummary

Scope property for server/table based data sources.

Scope property for in-memory data sources.

Scope property for stored procedures.

Scope property for view foundset data sources.

Methods Summarized

TypeNameSummary

Scope getter for a datasource node based on a JSFoundset/JSRecord/ViewFoundset/ViewRecord

Scope getter for a datasource node based on datasource string.

Properties Detailed

db

Scope property for server/table based data sources.

Type DBDataSource

Sample

datasources.db.example_data.orders

mem

Scope property for in-memory data sources.

Type MemDataSource

Sample

datasources.mem['myds']

sp

Scope property for stored procedures. This will list the stored procedures of server that have this property enabled (see server editor).

Type SPDataSource

Sample

datasources.sp.servername.mystoredproc();

view

Scope property for view foundset data sources.

Type ViewDataSource

Sample

datasources.view['myds']

Methods Detailed

get(datasource)

Scope getter for a datasource node based on a JSFoundset/JSRecord/ViewFoundset/ViewRecord

Parameters

Returns: JSDataSource a JSDataSource based on parameter

Sample

datasources.get(recordOrFoundset)

get(datasource)

Scope getter for a datasource node based on datasource string.

Parameters

Returns: JSDataSource a JSDataSource based on parameter

Sample

datasources.get(datasource)

Last updated