shell

format your shell script automatically

To create a shell script that converts another shell script into a well-formatted one, we can use the awk command, a powerful text-processing tool. This script will help you format and clean up the...

Convert your hive output to Json format

Using CONCAT and string manipulation functions: SELECT CONCAT(‘{ “column1”: “‘, column1, ‘”, “column2”: “‘, column2, ‘”, “column3”: “‘, column3, ‘” }’) AS json_data FROM your_table; Using a custom UDF (User-Defined Function): If the built-in...