Certain conditions are checked with the WHEN Statement when using the CASE Statement, and certain results are returned if the condition is met. We can …
Read More »While Loop in SQL Server(TSQL)
By creating a loop, we can perform certain operations as long as this loop continues. We can use While Loop as follows. As long as …
Read More »GOTO Statement in SQL Server(TSQL)
If a specific condition occurs, you can use the GOTO statement to run the code in a given label. The use is as follows. [crayon-674512280fabb252706743/]
Read More »Break and Continue Statements in SQL Server(TSQL)
BREAK Statement: You may want to terminate while loop by using the BREAK statement. You can use it as follows. [crayon-674512280fc18205255729/] Continue Statement: Usually …
Read More »IF…ELSE Statement in SQL Server(TSQL)
If the condition in the IF block is provided, operations between the BEGIN and END blocks are performed. If the condition in the IF block …
Read More »IF Statement in SQL Server(TSQL)
If the condition in the “IF” block is provided, we perform operations between the “BEGIN” and “END” blocks. You can use it as follows. …
Read More »String or binary data would be truncated
When we want to add data to a table, we get this error if the size of the column in the table is smaller …
Read More »How To Export Tables to csv in Oracle
It is possible to export the data in tables in the database in csv format depending on a specific condition. We can use the …
Read More »How To Hide Database Names From Unauthorized Logins in SQL Server Management Studio
If you are using a consolidated SQL Server environment, there is more than one database and login on an instance. When the logins connect to …
Read More »Must declare the scalar variable “@variable”
If there is a variable in the script we run and we have not declared this variable, we will get this error. For example, …
Read More »