What is the Oracle equivalent of this MS SQL Server notation?
DECLARE @Variable INT SET @Variable = 1
In PL / SQL, you have a declaration block:
declare x integer := 1; ... begin ... end;
If you write an SQL * Plus script, you use variable to declare a variable
variable
variable x integer := 1;
It is also possible to define variables.
In PL / SQL:
DECLARE a number; BEGIN a := 1; END;
You can paste this code into SQLPlus to run it.
Source: https://habr.com/ru/post/1307943/More articles:General things a developer should know with 2+ years of experience? - databaseQuestions related to the design of C ++ - c ++How do Hex editors display data so fast? - c ++Calling the method n times: should I use a for-each loop or traditional for a loop? - javaWhat is an effective way to get the smallest non-negative remainder modulo n in C? - cHow to find the smallest positive integer comparable to the module m? - mathPython script to calculate aded combinations from a dictionary - pythonCreate a Delicious Bookmarklet in Firefox with the Delicious API - javascriptUsing floating point numbers to print - cAuthorization skip for specific methods - filterAll Articles