Skip to content

Red squiggly lines for SYSTEM_TIME in MS SQL #1027

@rickythefox

Description

@rickythefox

Bug Description

MS SQL temporal table expressions seem not to be supported, e.g. SYSTEM_TIME is underlined in red.

Repro steps

  1. Create a new SQL file or notebook
  2. Paste this:
SELECT TOP 20
      curr.wdp_uuid,
      curr.email,
      prev.email_type AS email_type_at_phase1,
      curr.email_type AS email_type_now,
      prev._modifieddate_ts AS modified_at_phase1,
      curr._modifieddate_ts AS modified_now
  FROM dbo.dim_email AS curr
  CROSS APPLY (
      SELECT TOP 1 *
      FROM dbo.dim_email
      FOR SYSTEM_TIME AS OF '2026-03-16T17:35:00'
      WHERE wdp_uuid = curr.wdp_uuid
  ) AS prev
  WHERE curr.email LIKE '%@fake.com'
    AND curr._modifieddate_ts >= '2026-03-16 21:55:00'
    AND ISNULL(curr.email_type, '') <> ISNULL(prev.email_type, '')
  ORDER BY curr.wdp_uuid

  1. See error

Expected Behavior

No red lines for valid SQL.

Actual Behavior

Red lines present.

Environment

  • DBCode version: 1.29.2
  • VS Code (or fork) version: VS Code 1.111.0
  • OS: MacOS
  • Database: Azure SQL
  • Connection: (direct/SSH/SSL) direct

Screenshots

Image

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions