home / github

Menu
  • Search all tables
  • GraphQL API

issue_comments

Table actions
  • GraphQL API for issue_comments

6 rows where issue = 1424378012 and "updated_at" is on date 2022-10-27 sorted by updated_at descending

✖
✖
✖

✎ View and edit SQL

This data as json, CSV (advanced)

Suggested facets: reactions, created_at (date), updated_at (date)

user 2

  • simonw 4
  • CharlesNepote 2

author_association 2

  • OWNER 4
  • NONE 2

issue 1

  • SQL query field can't begin by a comment · 6 ✖
id html_url issue_url node_id user created_at updated_at ▲ author_association body reactions issue performed_via_github_app
1293939737 https://github.com/simonw/datasette/issues/1860#issuecomment-1293939737 https://api.github.com/repos/simonw/datasette/issues/1860 IC_kwDOBm6k_c5NH_QZ simonw 9599 2022-10-27T18:57:37Z 2022-10-27T18:57:37Z OWNER

The new code is now live at https://latest.datasette.io/fixtures

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
SQL query field can't begin by a comment 1424378012  
1293928738 https://github.com/simonw/datasette/issues/1860#issuecomment-1293928738 https://api.github.com/repos/simonw/datasette/issues/1860 IC_kwDOBm6k_c5NH8ki simonw 9599 2022-10-27T18:46:31Z 2022-10-27T18:46:31Z OWNER

I think mine has a better pattern for handling /* ... anything in here that isn't */ ... */

{
    "total_count": 1,
    "+1": 1,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
SQL query field can't begin by a comment 1424378012  
1293928230 https://github.com/simonw/datasette/issues/1860#issuecomment-1293928230 https://api.github.com/repos/simonw/datasette/issues/1860 IC_kwDOBm6k_c5NH8cm simonw 9599 2022-10-27T18:46:03Z 2022-10-27T18:46:03Z OWNER

Here's yours on Debuggex: https://www.debuggex.com/r/HjdJryTy9ezGsuWK

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
SQL query field can't begin by a comment 1424378012  
1293926417 https://github.com/simonw/datasette/issues/1860#issuecomment-1293926417 https://api.github.com/repos/simonw/datasette/issues/1860 IC_kwDOBm6k_c5NH8AR simonw 9599 2022-10-27T18:44:20Z 2022-10-27T18:45:21Z OWNER

Hah, I just came up with this one - we were clearly working on this at the same time!

^\s*((?:\-\-.*?\n\s*)|(?:\/\*((?!\*\/)[\s\S])*\*\/)\s*)*\s*select\b

https://www.debuggex.com/r/Rbw-UWD9PdOU2GyO

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
SQL query field can't begin by a comment 1424378012  
1293912781 https://github.com/simonw/datasette/issues/1860#issuecomment-1293912781 https://api.github.com/repos/simonw/datasette/issues/1860 IC_kwDOBm6k_c5NH4rN CharlesNepote 562352 2022-10-27T18:31:15Z 2022-10-27T18:31:15Z NONE

Here is my suggestion:

^\s*((?:\-\-.*?\n\s*)|(?:/\*.*?(?=\*/)\*/\s*))*select\b

See the following test: https://regex101.com/r/Doeqqa/1

And here I played all your tests: https://regexr.com/713ir

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
SQL query field can't begin by a comment 1424378012  
1293863145 https://github.com/simonw/datasette/issues/1860#issuecomment-1293863145 https://api.github.com/repos/simonw/datasette/issues/1860 IC_kwDOBm6k_c5NHsjp CharlesNepote 562352 2022-10-27T17:43:37Z 2022-10-27T17:43:37Z NONE

Sorry I forgot the -- comments like that.

I'm afraid there is an issue in your regexp, see: https://regex101.com/r/pyubJf/1

I guess I can fix it.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
SQL query field can't begin by a comment 1424378012  

Advanced export

JSON shape: default, array, newline-delimited, object

CSV options:

CREATE TABLE [issue_comments] (
   [html_url] TEXT,
   [issue_url] TEXT,
   [id] INTEGER PRIMARY KEY,
   [node_id] TEXT,
   [user] INTEGER REFERENCES [users]([id]),
   [created_at] TEXT,
   [updated_at] TEXT,
   [author_association] TEXT,
   [body] TEXT,
   [reactions] TEXT,
   [issue] INTEGER REFERENCES [issues]([id])
, [performed_via_github_app] TEXT);
CREATE INDEX [idx_issue_comments_issue]
                ON [issue_comments] ([issue]);
CREATE INDEX [idx_issue_comments_user]
                ON [issue_comments] ([user]);
Powered by Datasette · Queries took 23.401ms · About: github-to-sqlite
  • Sort ascending
  • Sort descending
  • Facet by this
  • Hide this column
  • Show all columns
  • Show not-blank rows