Search
 
SCRIPT & CODE EXAMPLE
 

SQL

declare variables sql

--      name         type               value
DECLARE @PersonId AS UNIQUEIDENTIFIER = 'ddb7bfff-9ce8-4651-6973-08d9a46c90b6'
Comment

sql declare table variable

DECLARE @TABLE TABLE( COL1 INT, COL2 VARCHAR(30))
Comment

sql declare variable

DECLARE @datecurrent datetime2
set @datecurrent = CAST(getdate() AS smalldatetime)
Comment

declare value in sql

DECLARE  { @LOCAL_VARIABLE[AS] data_type  [ = value ] } 
Comment

declare table variable sql

DECLARE @TableVariable TABLE (Id INT)

INSERT INTO @TableVariable
SELECT Id
FROM TableName
WHERE....

SELECT *
FROM TableName
WHERE Id IN ( SELECT Id FROM @TableVariable)
Comment

how to declare a variable in sql

DECLARE @COURSE_ID AS INT, @COURSE_NAME VARCHAR (10);
Comment

PREVIOUS NEXT
Code Example
Sql :: sql server check whether column has same equal values 
Sql :: how to tun mysql on ubunto 
Sql :: format the money fied with comma in international system using sql 
Sql :: SQL Updating a View 
Sql :: convert columns to rows in sql server 
Sql :: sqlalchemy get schema from database 
Sql :: sql online 
Sql :: sql to array of objects 
Sql :: SQL SELECT DISTINCT Statement 
Sql :: distinct in sql server 
Sql :: pl sql case 
Sql :: mysql timestamp vs datetime 
Sql :: what is a unique key in sql 
Sql :: mysql disable triggers 
Sql :: postgresql backup and restore globals and data 
Sql :: homebrew install mysql 
Sql :: mysql add hours to time field 
Sql :: sql order by with where 
Sql :: how to make case insensitive in sql 
Sql :: insert in sql 
Sql :: postgresql héritage 
Sql :: power bi union columns 
Sql :: Add a new column into table 
Sql :: max length found in mysql 
Sql :: alter boolean column postgresql 
Sql :: How to check if a column exists in a SQL Server table? 
Sql :: postgres copy command 
Sql :: sqlalchemy case insensitive like 
Sql :: Select All From A Table In A MySQL Database 
Sql :: sql float 3 decimal places 
ADD CONTENT
Topic
Content
Source link
Name
4+5 =