ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

Help / WLanguage / Managing databases / Big Data / HDFS system
WINDEV
WindowsLinuxJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac Catalyst
Others
Stored procedures
Copies a file located on the local machine to a Hadoop server.
Example
// Connection
MyConnection is hdfsConnection
MyConnection.namenode = "MyServer"
MyConnection.User = "Admin"
hdfsOpenConnection(MyConnection)
// Copy from the local computer to the server
hdfsCopyTo(MyConnection, "c:\temp\test.data", "/tmp/test.data")
Syntax
<Result> = hdfsCopyTo(<Connection> , <Source file> , <Destination file> [, <Options> [, <Permission> [, <Progress Bar>]]])
<Result>: Boolean
  • True if the copy was performed,
  • False if a problem occurs. ErrorInfo is used to identify the error.
<Connection>: hdfsConnection variable
Name of the hdfsConnection variable that corresponds to connection to the Hadoop server.
<Source file>: Character string
Path of local file to copy (up to 260 characters). This parameter can correspond to:
  • a file name. This file will be automatically sought in the current directory (returned by fCurrentDir).
  • a file name with its full or relative path. A UNC path can be used.
<Destination file>: Character string
Absolute path of file copied onto the Hadoop server. This path is case sensitive.
<Options>: Optional constant
Options for copying:
hdfsDefault
(Default value)
If the destination file already exists on the server, it is not averwritten.
hdfsOverwriteIf the destination file already exists on the server, it is replaced by the file copied from the local computer.
<Permission>: Optional hdfsRights variable
Name of the hdfsRights variable defining the rights of the destination file on the server.
By default, all the rights are granted to all the users.
<Progress Bar>: Optional control name
Name of the Progress Bar control used to see the progress of file copy.
Business / UI classification: Business Logic
Component: wd300big.dll
Minimum version required
  • Version 21
This page is also available for…
Comments
Click [Add] to post a comment

Last update: 09/25/2024

Send a report | Local help