{'fraction_non_alphanumeric': 0.022582921665490474, 'fraction_numerical': 0.0, 'mean_word_length': 5.165217391304348, 'pattern_counts': {'":': 0, '<': 0, '<?xml version=': 0, '>': 0, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
Creation of Datasets for Data Mining Analysis by Using Horizontal Aggregation in SQL

Data mining is widely used domain for extracting trends or patterns from historical data. In a relational database, especially with normalized tables, a significant effort is required to prepare a summary data set that can be used as input for a data mining algorithm. In general, a significant manual effort is required to build data sets, where a horizontal layout is required. The existing aggregations performed through SQL functions such as MIN, MAX, COUNT, SUM, AVG return a single value output which is not suitable for making datasets meant for data mining. We propose simple, yet powerful, methods to generate SQL code to return aggregated columns in a horizontal tabular layout, returning a set of numbers instead of one number per row. This new class of functions is called horizontal aggregations. The result of the queries is the data which is suitable for data mining operations. It does mean that this paper achieves horizontal aggregations through some constructs builds that includes SQL queries as well. We propose three fundamental methods to evaluate horizontal aggregations: CASE: Exploiting the programming phase construct; SPJ: Based on standard relational algebra operators (SPJ Queries); PIVOT: Using the PIVOT operator, which is offered by some DBMSs. Keywords—Aggregations, SQL, data sets and data mining