---
title: "Discussion on \"Add Records that Meet the Criteria before Each Group after Grouping — From SQL to SPL #39\" | Hashnode"
description: "Discussion on \"Add Records that Meet the Criteria before Each Group after Grouping — From SQL to SPL #39\". Problem Description & Analysis:\nIn a certain view of the PostgreSQL database, the row_index field is an underscore separated string and also a grouping field. Some groups’ row_index can be divided into 3 parts, while others can be divided into 2 part..."
url: "https://hashnode.com/posts/add-records-that-meet-the-criteria-before-each-group-after-grouping-from-sql-to-spl-39/684f8f1177ed991dcfbd293a"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [Add Records that Meet the Criteria before Each Group after Grouping — From SQL to SPL #39](https://esproc-desktop.hashnode.dev/add-records-that-meet-the-criteria-before-each-group-after-grouping-from-sql-to-spl-39?utm_source=hashnode&utm_medium=feed)

Problem Description & Analysis: In a certain view of the PostgreSQL database, the row\_index field is an underscore separated string and also a grouping field. Some groups’ row\_index can be divided into 3 parts, while others can be divided into 2 part...

Jun 16, 2025 · 2 min read · esproc-desktop.hashnode.dev  
Read the article

-   [#sql](https://hashnode.com/tag/sql)
-   [#sqltutorial](https://hashnode.com/tag/sqltutorial)
-   [#databases](https://hashnode.com/tag/databases)
-   [#data-structures](https://hashnode.com/tag/data-structures)
-   [#database](https://hashnode.com/tag/database)
-   [#productivity](https://hashnode.com/tag/productivity)
-   [#coding](https://hashnode.com/tag/coding)
-   [#esproc-spl](https://hashnode.com/tag/esproc-spl)
-   [#opensource](https://hashnode.com/tag/opensource)
-   [#data-analysis](https://hashnode.com/tag/data-analysis)
-   [#data-analytics](https://hashnode.com/tag/data-analytics)

## Written by

[esProc](https://hashnode.com/@esProcDesktop)

@esProcDesktop

  
[View profile](https://hashnode.com/@esProcDesktop)

esProc SPL is a JVM-based programming language designed for structured data computation, serving as both a data analysis tool and an embedded computing engine. FREE download👉🏻: https://www.esproc.com/download-esproc

## Responses 1

Markdown supported · ⌘↵ to post

[esProc](https://hashnode.com/@esProcDesktop)

[Jun 16, 2025](https://hashnode.com/posts/add-records-that-meet-the-criteria-before-each-group-after-grouping-from-sql-to-spl-39/684f8f1177ed991dcfbd293a/comment/684f948b2e4314d82bf33f7b)

Get Started with esProc SPL! And share your thoughts with us!

💡Discord: [discord.gg/sxd59A8F2W](https://discord.gg/sxd59A8F2W) 💡Reddit:[reddit.com/r/esProc\_Desktop](https://www.reddit.com/r/esProc_Desktop/)
