AYUDA EN LÍNEA
 WINDEVWEBDEV Y WINDEV MOBILE

Este contenido se ha traducido automáticamente.  Haga clic aquí  para ver la versión en inglés.
Ayuda / WLanguage / Administrar bases de datos / HFSQL / Funciones HFSQL Client/Server
  • Operating mode of <Variable Connection>.CopyFile
  • Use conditions
  • Names of data files and directories on the server
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReportes y ConsultasCódigo de Usuario (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Código Navegador
WINDEV Mobile
AndroidWidget Android iPhone/iPadIOS WidgetApple WatchMac CatalystUniversal Windows 10 App
Otros
Procedimientos almacenados
Performs an copy of a data file HFSQL (.fic, .ndx, .ftx, .sdx and .mmo files if available):
  • from the HFSQL server to the server (to perform a backup for example).
  • from the HFSQL server to the client (to perform a local backup for example).
  • from the client to the HFSQL server (to update the data files for example).
  • from an HFSQL server to another HFSQL server.
Novedad versión 2024
HFSQL Cluster
From version 2024 Update 1, it is possible to use the <Variable Connection>.CopyFile function with an HFSQL cluster. In particular, it is possible to make an copy of a data file:
  • from the HFSQL server to a node in the HFSQL cluster.
  • from a local directory to an HFSQL cluster.
Ejemplo
// Description de la connexion
MaConnexion is Connection

// Copie des fichiers de données du serveur vers le serveur
// avec renommage et changement de répertoire
MaConnexion.CopieFichier(".\sauvegarde\fichierclient_sov.fic", MaConnexion, ".\fichierclient.fic")
// Description de la connexion
MaConnexion is Connection

// Copie des fichiers de données du poste client vers le poste serveur
MaConnexion.CopieFichier("client.fic", "", "C:\Données\Client.fic")
// Description de la connexion
MaConnexion1 is Connection
MaConnexion2 is Connection

// Copie le(les) fichiers de données d'un serveur vers un autre serveur
MaConnexion1.CopieFichier("client.fic", MaConnexion2, "rep\client.fic", hNoIndex, JAUGE_MaJauge)
Sintaxis
<Result> = <Destination connection>.CopyFile(<Destination data file> , <Source connection> , <Source data file> [, <Copy mode> [, <Progress Bar control> [, <Password>]]])
<Result>: booleano
  • True if the data file was copied,
  • False if an error occurs. HError is used to identify the error.
<Destination connection>: Variable de tipo Connection
Name of the Connection variable that describes the connection in which the data file must be copied.
<Destination data file>: Cadena de caracteres
Name and path of destination data file. The path and this data file are automatically created if they do not exist on the server.
If the destination data file is found on the server, the path is relative to the database.
Caution: the extension of the '.fic' file must be specified.
<Source connection>: Cadena de caracteres o variable de tipo Connection
Connection from which the data file must be copied. This connection corresponds to:
<Source data file>: Cadena de caracteres
Name and path of the source data file (to copy). If the source data file is found on the server, the path is relative to the database.
Caution:
  • the extension of the '.fic' file must be specified.
  • the '.mmo' file, if any, will be automatically copied.
<Copy mode>: Constante opcional de tipo Integer
Copy mode used:
hCopyIfNotFoundCopies the data file only if it does not exist at the specified location on the destination computer.
hCopyIndexThe of the data file index(es) are copied (NDX file, SDX file and FTX file if available).
hCreateIndexof the data file index(es) are not copied (NDX file, SDX file and FTX file if they exist). They are automatically re-created on the destination via a reindex operation.
If the data file is password-protected, the <Password> parameter must be specified.
hNoIndexThe of the data file index(es) are not copied (NDX file, SDX file and FTX file if they exist).
<Progress Bar control>: Nombre de control opcional
Name of Progress Bar control found in the window, used to show the progress of copy.
<Password>: Cadena de caracteres opcional
File password (if it exists). This password is required if the hCreateIndex constant is used.
Observaciones

Operating mode of <Variable Connection>.CopyFile

  • The copied data file is unlocked, as well as the records found in the data file.
  • The index is not copied if it does not exist or if it is corrupted.
  • The password is not required to copy the data file. However, the copied data file remains password-protected.
  • It is not possible to copy data files to a source server of a SPARE replication server.
  • Data file in transaction: before copying the data file, we advise you to:

Use conditions

  • You can also copy a data file from the client computer to the same client computer. In this case, this function is equivalent to fCopyFile.
  • This function is used to copy files to an HFSQL server (in Client/Server mode). This function cannot be used with an external server (Oracle or other).
  • To copy an HFSQL data file from a local computer to the server, all the users must have freed such file beforehand. No connection to the data file must be in progress, or the copy will fail. To prevent any new connection to the data file, you can:
  • Case of replicated data files (replication between servers):
    For a replicated data file, <Variable Connection>.CopyFile must not be used to copy a data file to the server: the copy is not possible. However, a data file can be copied from the server to the client computer.
  • Novedad versión 2024
    Case of an HFSQL cluster
    • If the data files to be copied use enhanced security, it is necessary to specify the of the data file password via the parameter . This password is required to synchronize data files on the various nodes..
    • To use the <Variable Connection>.CopyFile function with an HFSQL cluster, it is necessary that both the HFSQL cluster and the client application use at least version 2024 Update 1.

Names of data files and directories on the server

  • The names of data files (.fic, .ndx, .ftx, .sdx and .mmo files if they exist) on the server must not include accents.
  • On a LINUX server, the name of the data files must be written in lowercase characters.
Componente: wd290hf.dll
Versión mínima requerida
  • Versión 25
Esta página también está disponible para…
Comentarios
Haga clic en [Agregar] para publicar un comentario

Última modificación: 08/03/2024

Señalar un error o enviar una sugerencia | Ayuda local