Skip to content

EXEC sql does not work from Notebook #23233

Open
@joli03

Description

Issue Type: Bug

  1. Create a new Notepbook
  2. Add Code Cell
  3. Declare dynamic SQL where database is built dynamically (different from selected database in Attach to)
  4. EXEC dynamic SQL

Expected

SQL runs and returns result

Actual

Msg 203, Level 16, State 2, Line 14
The name '' is not a valid identifier.

If I copy the SQL and run it from a query window connected to master it works fine

System info

Azure Data Studio version: azuredatastudio 1.43.0 (b790d70, 2023-04-10T23:14:27.236Z)
OS version: Windows_NT x64 10.0.22621
Restricted Mode: No
Preview Features: Enabled

System Info
Item Value
CPUs Intel(R) Xeon(R) E-2276M CPU @ 2.80GHz (12 x 2808)
GPU Status 2d_canvas: enabled
canvas_oop_rasterization: disabled_off
direct_rendering_display_compositor: disabled_off_ok
gpu_compositing: enabled
multiple_raster_threads: enabled_on
opengl: enabled_on
rasterization: enabled
raw_draw: disabled_off_ok
skia_renderer: enabled_on
video_decode: enabled
video_encode: enabled
vulkan: disabled_off
webgl: enabled
webgl2: enabled
webgpu: disabled_off
Load (avg) undefined
Memory (System) 31.73GB (9.81GB free)
Process Argv
Screen Reader no
VM 0%
Extensions: none

Activity

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

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions