Skip to content

Instantly share code, notes, and snippets.

@kylebrandt
Created November 7, 2024 16:20
Show Gist options
  • Save kylebrandt/56752939c02b9ae7a493ee3e3d8db29b to your computer and use it in GitHub Desktop.
Save kylebrandt/56752939c02b9ae7a493ee3e3d8db29b to your computer and use it in GitHub Desktop.
SQL Expression Notes

SQL Expression Notes

Getting some thoughts down...

PoC Outline (with go-mysql-server)

  • Goals

    • Main Goal: go-mysql-server end-to-end inside SSE over completion for discovery, supporting some subset of cases of combining other datasources
    • Run go-mysql-server without "server"
    • Use SDK for response
    • Integrate with SSE quickly (hack over duckdb code?)
  • Fow now, use memory

  • Response

SSE Integration

  • Misc
    • Since we have access to the SQL parser, we should be able to get the NeedsVars by parsing the "tables" from the query during pre execution
  • Interoperability with Grafana Platform: Alerting, Other SSE, Recorded Queries, Viz
    • Dataplane Types
      • We want a drop down that asserts the Dataplane response data "kind" (A type is Kind+Format, but since this is SQLish, we will be working with the Long Formats for each kind)
        • Options (Might be better names)
        • Time Series
        • Numeric
        • Raw (Default)
  • Integration with other SSE operations
    • Big picture SSE should be revisited so each operation can work on dataplane formats without changing the format (This gets a bit complicated design wise - e.g. A + B where A and B are different formats, what format should output be?)
    • For now it will probably be reformated into the "Multi" formats when it is going to alerting or other SSE operations

Longer Term

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment