ATProto Browser

ATProto Browser

Experimental browser for the Atmosphere

Post

#TIL #PostgreSQL's "WITH ORDINALITY", to add the number of the row in the output

Nov 20, 2024, 9:13 AM

Record data

{
  "cid": "bafyreif5ynqvbfn4mvemmt2mcn6kx2citqjo7f7i5ywngw7u3i4pt6kpju",
  "uri": "at://did:plc:rm4n6dkpshyzhsg2bcb36eyu/app.bsky.feed.post/3lbemd3s34ks2",
  "value": {
    "$type": "app.bsky.feed.post",
    "bridgyOriginalText": "<p><a href=\"https://mastodon.social/tags/TIL\" class=\"mention hashtag\" rel=\"tag\">#<span>TIL</span></a> <a href=\"https://mastodon.social/tags/PostgreSQL\" class=\"mention hashtag\" rel=\"tag\">#<span>PostgreSQL</span></a>&#39;s &quot;WITH ORDINALITY&quot;, to add the number of the row in the output</p>",
    "bridgyOriginalUrl": "https://mastodon.social/@riffraff/113514514767918498",
    "createdAt": "2024-11-20T09:13:56.000Z",
    "embed": {
      "$type": "app.bsky.embed.images",
      "images": [
        {
          "$type": "app.bsky.embed.images#image",
          "alt": "running \n\nselect * from generate_series(0, 10, 2) with ordinality AS series(item, index);\n\ngenerates a table with the series items and ordinals",
          "image": {
            "$type": "blob",
            "ref": {
              "$link": "bafkreia66uxnjzvomzmk2k74qnpyh3n4vxng7i3jgkkvn2zrunnpljsilm"
            },
            "mimeType": "image/png",
            "size": 34428
          }
        }
      ]
    },
    "facets": [
      {
        "$type": "app.bsky.richtext.facet",
        "features": [
          {
            "$type": "app.bsky.richtext.facet#tag",
            "tag": "til"
          }
        ],
        "index": {
          "byteEnd": 4,
          "byteStart": 0
        }
      },
      {
        "$type": "app.bsky.richtext.facet",
        "features": [
          {
            "$type": "app.bsky.richtext.facet#tag",
            "tag": "postgresql"
          }
        ],
        "index": {
          "byteEnd": 16,
          "byteStart": 5
        }
      }
    ],
    "langs": [
      "en"
    ],
    "text": "#TIL #PostgreSQL's \"WITH ORDINALITY\", to add the number of the row in the output"
  }
}