PC SOFT

ONLINE HELP
FOR WINDEV, WEBDEV AND WINDEV MOBILE

Home | Sign in | English US
  • WLanguage properties that can be used with a connection described by programming
  • Native Oracle access: managing the external authentication
  • Equivalence between code: Describing a connection
  • Equivalence between code: Establishing a connection
  • Equivalence between codes: Assigning a connection
  • Equivalence between codes: Modifying an existing connection
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadApple WatchUniversal Windows 10 AppWindows Mobile
Others
Stored procedures
Connection (Type of variable)
In French: Connexion (Type de variable)
HFSQLNot available with this kind of connection
The Connection type is used to describe one or more connections to external databases (HFSQL Client/Server, Native Access, ). Then, this connection can be opened by HOpenConnection. The characteristics of this connection can be defined and modified by several WLanguage properties.
Versions 15 and later
PHP This type of variable is now available for the PHP sites.
New in version 15
PHP This type of variable is now available for the PHP sites.
PHP This type of variable is now available for the PHP sites.
Versions 17 and later
iPhone/iPad This type of variable is now available for the iPhone/iPad applications.
New in version 17
iPhone/iPad This type of variable is now available for the iPhone/iPad applications.
iPhone/iPad This type of variable is now available for the iPhone/iPad applications.
The Connection variable can also be used to:
Note: See Declaring a variable for more details.
Note: From version 19, HFSQL is the new name of HyperFileSQL.
Example
MyConnection is Connection

// Describe the connection
MyConnection..User = "USER"
MyConnection..Password = "PASSWORD"
MyConnection..Server = "MYSERVER"
MyConnection..Database = "Database"
MyConnection..Provider = hAccessHFClientServer
MyConnection..Access = hOReadWrite
MyConnection..ExtendedInfo = "Extended information"
MyConnection..CursorOptions = hClientCursor

// Open the connection
HOpenConnection(MyConnection)

// Assign the connection to all data files
HChangeConnection("*", MyConnection)
Remarks

WLanguage properties that can be used with a connection described by programming

The properties specific to the connections are presented in the table below:
Note: ..Provider and ..Server or ..Provider and ..Source must necessarily be initialized when describing a connection.
Property nameEffect
AccessAllows you to manage the type of access for a connection (HFSQL Client/Server, OLE DB, ...): Read, Read/Write
Versions 23 and later
ActiveDirectory
New in version 23
ActiveDirectory
ActiveDirectory
Used to manage the connection via Active Directory.
DatabaseAllows you to manage the name of the database associated with a connection (HFSQL Client/Server, OLE DB, ...).
CompressionAllows you to manage the compression of data transmitted by the connection.
CryptMethodAllows you to manage the type of encryption for the communication between the Client computers and the HFSQL server.
ExtendedInfoAllows you to manage the additional information of a connection.
CaptionAllows you to find out and modify the caption of a connection.
PasswordAllows you to modify the password associated with the user of a connection.
NameAllows you to find out the name of the connection
CursorOptionsAllows you to manage the different types of cursors used by the connection.
ProviderAllows you to manage the type of data handled by the connection.
ServerAllows you to manage the name of the server used in the connection. This property is identical to ..Source. This property is mainly used for the HFSQL Client/Server connections or for the Native Accesses on the servers.
HFSQL Client/Server
Versions 15 and later
You have the ability to specify an IPv6 address by writing the IPv6 address between square brackets. In this case, the port number must be specified after the closing square bracket. For example: [0154:2145:2155::5554]:4900.
New in version 15
You have the ability to specify an IPv6 address by writing the IPv6 address between square brackets. In this case, the port number must be specified after the closing square bracket. For example: [0154:2145:2155::5554]:4900.
You have the ability to specify an IPv6 address by writing the IPv6 address between square brackets. In this case, the port number must be specified after the closing square bracket. For example: [0154:2145:2155::5554]:4900.
SourceAllows you to manage the name of the data source used in the connection. This property is identical to ..Server. This property is mainly used for a connection on MS Access or on an xBase file. .
CacheSizeAllows you to manage the size of the cache
UserAllows you to manage the user of the connection
Versions 18 and later
WINDEVWEBDEV - Server codeNative Accesses

Native Oracle access: managing the external authentication

To connect via an external authentication:
  • the ..User property must correspond to "/" (slash)
  • the ..Password property must correspond to "" (empty string)
Note: The external authentication consists in using the name of Windows user and his password to connect to the database. The external authentication requires a setting of the server. See the documentation about Oracle to find out how to authorize the external authentications on the server.
New in version 18
WINDEVWEBDEV - Server codeNative Accesses

Native Oracle access: managing the external authentication

To connect via an external authentication:
  • the ..User property must correspond to "/" (slash)
  • the ..Password property must correspond to "" (empty string)
Note: The external authentication consists in using the name of Windows user and his password to connect to the database. The external authentication requires a setting of the server. See the documentation about Oracle to find out how to authorize the external authentications on the server.
WINDEVWEBDEV - Server codeNative Accesses

Native Oracle access: managing the external authentication

To connect via an external authentication:
  • the ..User property must correspond to "/" (slash)
  • the ..Password property must correspond to "" (empty string)
Note: The external authentication consists in using the name of Windows user and his password to connect to the database. The external authentication requires a setting of the server. See the documentation about Oracle to find out how to authorize the external authentications on the server.

Equivalence between code: Describing a connection

Code that is using HDescribeConnection:
HDescribeConnection("MyConnection", "USER", "PASSWORD", "TESTSERVER", ...
       "Database", hAccessHFClientServer, hOReadWrite, ...
       "Extended info", hClientCursor)
Code that is using the connection:
MyConnection is Connection
// Describe the connection
MyConnection..User = "USER"
MyConnection..Password = "PASSWORD"
MyConnection..Server = "TESTSERVER"
MyConnection..Database = "Database"
MyConnection..Provider = hAccessHFClientServer
MyConnection..Access = hOReadWrite
MyConnection..ExtendedInfo = "Extended information"
MyConnection..CursorOptions = hClientCursor

Equivalence between code: Establishing a connection

Code that is using HOpenConnection:
HOpenConnection("MyConnection", "USER", "PASSWORD", "TESTSERVER", ...
       "Database", hAccessHFClientServer, hOReadWrite, ...
       "Extended info", hClientCursor)
Code that is using the connection:
MyConnection is Connection
// Describe the connection
MyConnection..User = "USER"
MyConnection..Password = "PASSWORD"
MyConnection..Server = "TESTSERVER"
MyConnection..Database = "Database"
MyConnection..Provider = hAccessHFClientServer
MyConnection..Access = hOReadWrite
MyConnection..ExtendedInfo = "Extended information"
MyConnection..CursorOptions = hClientCursor
HOpenConnection(MyConnection)

Equivalence between codes: Assigning a connection

Code that is using HChangeConnection:
HChangeConnection(CLIENT, MyConnection)
Code that is using the connection:
CLIENT..Connection = MyConnection

Equivalence between codes: Modifying an existing connection

Code that is using HDescribeConnection:
HDescribeConnection(MyConnection, "USER2", "PASSWORD2", MyConnection..CtDatabase, ...
MyConnection..CtInitialCatalog, ...
MyConnection..CtOLEDBProvider, MyConnection..CtAccess, ...
MyConnection..CtExtendedInfo, MyConnection..CtCursorOptions)
Code that is using the connection:
// Modifies the login and password for the connection
MyConnection..User = "USER2"
MyConnection..Password = "PASSWORD2"
Minimum required version
  • Version 10
This page is also available for…
Comments
Click [Add] to post a comment