This step-by-step tutorial will show how to use Microsoft Excel to retrieve data from the HiveSQL database and present your result in a simple but nice pivot chart.
Writing a SQL query
Let’s say for example you want to see how many transactions have been issued each month on the blockchain. The SQL query to get such information will be:
SELECT
YEAR(Blocks.timestamp) AS [Year],
MONTH(Blocks.timestamp) AS [Month],
COUNT(*) AS [Transactions]
FROM
Transactions
INNER JOIN Blocks ON Transactions.block_num = Blocks.block_num
GROUP BY
YEAR(Blocks.timestamp),
MONTH(Blocks.timestamp)
Retrieving data with Excel
Start Excel, go to the Data tab and select SQL Server as your data source
The Data Connection Wizard will be displayed
Enter the connection information in the wizard dialog box as shown and click "Next"