Class DB2DatasourceConnection
- Namespace
- YndigoBlue.Velocity.Connections
- Assembly
- YndigoBlue.Velocity.dll
Connection configuration for IBM DB2 databases.
public class DB2DatasourceConnection : DatasourceConnection, IDatasourceConnection
- Inheritance
-
DB2DatasourceConnection
- Implements
Examples
// Connect to DB2 with standard configuration
var conn = new DB2DatasourceConnection
{
Hostname = "localhost",
Port = 50000,
Database = "SAMPLE",
Username = "db2admin",
Password = "mypassword"
};
using (var m = new Manager(conn))
{
var schema = m.LoadSchema("DB2ADMIN");
// Perform database operations
}
Remarks
WARNING: DB2 database support is not available in the Community Edition of Velocity. It requires the Full Edition.
Supports DB2 for LUW (Linux, Unix, Windows) version 11.1 and later.
Default port: 50000
Includes support for spatial data management with configurable update frequencies.
Properties
- DatasourceType
Gets the datasource type for DB2.
- NumberOfSegments
Gets or sets the number of segments for spatial grid indexes. Default is 96.
- ReservedSettings
Gets the reserved connection string settings that are handled by named properties.
- UpdateFrequency
Gets or sets the update frequency schedule for spatial indexes. Default is "d(0,1,2,3,4,5,6) h(0,12) m(0)".
- UpdateMinimum
Gets or sets the minimum number of changes required to trigger an update. Default is 5.