Monitor table rows

Hello all, I want to monitor the SalesForce Lightning queue, so that every time the queue is populated by a new row, I get a notification … the queue itself is table html element, I tried selecting it using the selector but it notified me with every update. How can I do that ? Thanks

Hello @imamo, are you able to select a cell with td tag in that table?

Hi there, I have the exact same query. Can anyone help? I am not knowledgable on coding or anything else but would appreciate any help here! Thanks

1 Like

Feel free to share details of your use case @trishmulvihill. We will be happy to help.

Hi @ajitk , @trishmulvihill and @imamo - where you able to solve this?
I am also looking to get a notification when a new row is added to a basic HTML table where the text contains a specific string. If you were ale to solve this could you please share your method?

Thank you!

@sbcgc here is a quick video that shows how to monitor any changes to a table.

Does this help in your use case? Feel free to share more details about what the problem is and I will be happy to help.

Cheers!

Thanks so much Ajit!

Part of my issue is that the table I am attempting to monitor updates regularly, can vary in the number of rows it has and pushes previous items lower down on the table. For my purposes I only want to receive notifications when the element contains “52 Div”

The website I’m monitoring is https://gtaupdate.com/ and I’d like to receive a notification when a new item is added for “52 Div” and see what that row is.

I’m new to coding but tried the below JSON:

{
  "selections": [
    {
      "frames": [
        {
          "index": 0,
          "excludes": [
            {
              "expr": "table tr",
              "type": "css",
              "fields": [
                {
                  "name": "text",
                  "type": "builtin"
                }
              ],
              "filters": [
                {
                  "name": "text",
                  "type": "not_contains",
                  "value": "52 Div"
                }
              ]
            }
          ],
          "includes": [
            {
              "expr": "table tr",
              "type": "css",
              "fields": [
                {
                  "name": "text",
                  "type": "builtin"
                }
              ],
              "filters": [
                {
                  "name": "text",
                  "type": "contains",
                  "value": "52 Div"
                }
              ]
            }
          ]
        }
      ],
      "dynamic": true,
      "delay": 2
    }
  ],
  "regexp": null,
  "ignoreEmptyText": true,
  "includeStyle": false,
  "viewport": {},
  "dataAttr": "text"
}

No luck so far.
Anything guidance you have is appreciated :slight_smile:

I think I may have figured it out @ajitk using an XPath Selector?

//table/tbody/tr[td[contains(., '52 Div')]]

1 Like

This is a good approach to filter rows in a table. Checkout following thread for a discussion on similar problem and solution:

Hey guys,

i want to monitor a table in a website to check for new rows/entries. I selected only the table instead of whole page. The problem is i get too many false positives. I get notification even if there arent any changes in the table. How can i narrow the selection so that i get a notification only if there is a new row?

I can select any cell with td if that helps

When i select first 2 rows, this shows on the configuration menu. Does it mean that it checks for first 2 rows or exactly the rows i marked for changes?
tr.hand:first-child
tr:nth-child(2)

Regards

1 Like

A notification is triggered only on a change. What does the change history show? Maybe it is something minor that could be deselected.

When a new row is added to the table, is it added to the top of the list or at any position?

tr.hand:first-child selects the first tr element
tr:nth-child(2) selects the second tr element irrespective of their content