ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

Help / WLanguage / Managing databases / Big Data / Managing Hive databases
  • Overview
  • How to handle a database with Hive in programming?
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac CatalystUniversal Windows 10 App
Others
Stored procedures
Overview
Hive is a software layer of Hadoop used to run queries.
Hive is using the HiveQL language that is close to SQL.
The developer specifies his query by using HiveQL (syntax derived from SQL) and the Hive engine translates this query to interrogate the HBase database in native mode..
In version 21, you have the ability to run HiveQL queries by using the SQL functions of WLanguage.
How to handle a database with Hive in programming?
To handle a database with Hive, you must use the SQL functions of WLanguage.
You can:
ConnectionNum is int
ConnectionNum = SQLConnect("master2.hadoop1.myserver.com", "sa", "", "default", "HIVE")
IF ConnectionNum <> 0 THEN
// The connection was successful
// Use the connection to run SQL queries
IF SQLExec("SELECT * FROM TEAM WHERE NAME='HOU'") = True THEN
// Process the query
ELSE
// Query failure: display an error message
SQLInfo("FINDCUSTOMERBYNAME")
Error("Error" + SQL.Error + "in the query: ", SQL.MesError)
END
ELSE
// The connection failed: display an error message
SQLInfo()
Error("The connection to the data source failed." + CR + ...
"Error code: " + SQL.Error + CR + SQL.MesError)
END
// In any case (connection OK or not)
SQLDisconnect()

Caution: The access to the databases in HiveQL is available at run time from Windows Vista or Windows Server 2008.
Minimum version required
  • Version 21
This page is also available for…
Comments
Click [Add] to post a comment

Last update: 05/26/2022

Send a report | Local help