Allows you to connect to a database, obtain or clear database errors, and create database cursors.
For JSP targets you must assign a variable of the PSConnectionClass type before you can create an instance of the object or call methods on it. To create an object of type PSConnectionClass in ASP targets, you can designate an untyped variable to reference an instance of the object that is returned by the CreateConnection method on the psServer object.
Syntax with user name and password for JSP targets
PSConnectionClass ( pageContext, Driver, URL, user, password, {bTrace} )
Syntax with database properties for JSP targets
PSConnectionClass ( pageContext, Driver, URL, Properties, {bTrace} )
PSConnectionClass ( name )
PSConnectionClass constructor |
Datatype |
Description |
---|---|---|
pageContext |
PageContext (javax.servlet.jsp class) |
The implicit pageContext object available to JSP targets. |
Driver |
String |
The name of the JDBC driver used to connect to the database. |
URL |
String |
The location of the database to which you want to connect. The database URL is obtained from the database JDBC driver documentation. |
user |
String |
The user name that the object uses to connect to the specified database. |
password |
String |
The password that the object uses to connect to the specified database. |
Properties |
String |
Any properties that your JDBC driver uses to connect to the database. If properties are defined, you must also define the user ID and password in the properties that you list. |
bTrace (Optional) |
boolean |
Allows tracing if set to true. The default is false. |
name |
String |
Name of the connection object. |
PSConnectionClass method |
Description |
---|---|
Clears the list of error objects |
|
Creates a named object that represents a SQL statement |
|
Creates a database cursor |
|
Returns the first error object |