SQL Language (MOSC)

MOSC Banner

sqlcl alias does not work with bind variable

edited Aug 2, 2022 9:47PM in SQL Language (MOSC) 5 commentsAnswered ✓

I have and alias userinfo

alias userinfo=select 1 from dual where 1 = :1;

userinfo 1 - does not return any row for command userinfo 1

I use the same SQL on the SQL prompt it gives

SP2-0552: Bind variable "1" not declared.

What I am doing wrong?

I tried on sqlcl version 21.2 and 22.2 (latest version)

Tagged:

Howdy, Stranger!

Log In

To view full details, sign in to My Oracle Support Community.

Register

Don't have a My Oracle Support Community account? Click here to get started.

Category Leaderboard

Top contributors this month

New to My Oracle Support Community? Visit our Welcome Center

MOSC Help Center