New and Improved NEAR Labels
A plethora of new labels have been added to Flipside's NEAR labels table. Using the labels, dive into which specific projects and project types (defi, nfts, etc) generate the most gas fees, have the most users, and have the highest number of transactions per user. Next, dig a little deeper and see if you can find which project types and which projects have the stickiest(repeat) users!
NEAR Protocol is an open-source blockchain platform designed to enable the creation and execution of decentralized applications (dApps). It aims to provide a scalable and developer-friendly environment for building decentralized applications that offer high throughput, low latency, and low transaction costs.
The NEAR Protocol takes a sharded approach to scalability, where the network is divided into smaller pieces called shards that can process transactions and execute smart contracts in parallel. This design allows NEAR to handle a large number of transactions concurrently, improving the overall throughput of the network.
One of the key features of NEAR is its focus on usability and developer experience. It provides a developer-friendly environment with familiar programming languages such as Rust, AssemblyScript, and TypeScript. This approach aims to lower the barrier for developers to build decentralized applications by leveraging their existing skills and knowledge.
NEAR Protocol also incorporates a consensus mechanism called "Proof of Stake" (PoS) to secure the network and validate transactions. In the PoS model, validators are chosen based on the number of tokens they hold and are willing to "stake" as collateral. This design incentivizes validators to act honestly and helps maintain the security and integrity of the network.
The native cryptocurrency of the NEAR Protocol is called NEAR, which is used for various purposes within the network, such as paying for transaction fees and participating in the consensus mechanism.
Overall, NEAR Protocol aims to provide a scalable, user-friendly, and developer-centric blockchain platform for building decentralized applications and fostering innovation in the blockchain ecosystem.

-
The query begins by defining a common table expression (CTE) named "lst_price." This CTE calculates the average price of the Wrapped NEAR fungible token on each date based on the data from the "near.core.fact_prices" table.
-
The query continues with another CTE named "tbl_all." This CTE joins multiple tables to retrieve information about transactions, including the date, transaction hash, wallet address, transaction fee (in NEAR), fee converted to USD, label type, project name, and the previously calculated average price. The "near.core.dim_address_labels" table is used to associate transaction receivers with their corresponding addresses.
-
The "WHERE" clause filters the data based on the specified conditions, including a dynamic number of days denoted by the placeholder "{{Days}}". It retrieves transactions that occurred within the specified number of days prior to the current date and have a status of "Success."
-
The final part of the query is the "GROUP BY" and "SELECT" clauses. The data from the "tbl_all" CTE is grouped by the project name (or "Other" if the project name is null) and calculates various metrics for each group. These metrics include the count of distinct wallets, count of distinct transaction hashes, the sum of transaction fees in NEAR, the sum of transaction fees converted to USD, and the cumulative count of wallets for each project.
-
The result is then sorted in descending order based on the fee in USD.
Overall, this query aims to provide insights into transaction activity for different projects on the NEAR protocol, including the number of wallets, number of transactions, transaction fees in NEAR and USD, and cumulative wallet count for each project.
