Featured
-
Find out a particular column throughout the database in Postgresql
Previously got a situation where I needed to get t
by Nitika.Verma
Tags
Except Clause in SQL
Except Clause:
It combines two select statements and return tuples from first SELECT statement which are not returned by second SELECT statement. It is used to achieve Distinct and Not In queries operation in a single clause(Except).
S...
INTERSECT Clause
INTERSECT Clause:
It works similar like union clause as it is used to combine two SELECT statements, but it returns tuples only from first SELECT statement which are common to tuples in the second SELECT statement.
Syntax:
S...
EXISTS Operator
EXISTS Operator:
Exists operator is a special type of operator which is used in a subquery. It is used to check whether a subquery returns something or not. If a subquery returns some row then outer query get executed otherwise the whole query...
SELECT INTO Statement
SELECT INTO Statement:
SELECT INTO statement is used to copy data from one table into another table. We can provide a condition while using SELECT INTO statement.
Syntax:
SELECT columnname(s)
INTO new_tablename
FROM t...
Case Expression in SQL
Case Statement:
Case Statement is used to provide IF-ELSE functionality in a SQL query to fetch result. We provide multiple conditions and according to condition matches the value will change for that that column value.
Syntax:
SELECT ...
TOP Clause in SQL
SELECT TOP clause:
TOP clause is used to fetch specific
number of records from a table.
This clause is very handy when we
have huge table of thousands of
record in it . And fetching data
from these tables are quite
time-consuming , in ...
How to use Right Join on two tables
Right Join:
Right Join is used to join two tables and it return all rows from right table(table 2) and matching rows from table 1(left table). The result is NULL for unmatched rows for table 1(left table). Right Join keyword is used to apply R...
Combining Results of two or more SELECT Statements
Combining Results of two or SELECT Statements using UNION OPERATOR:
UNION Operator is used to combine the results of two or more SELECT statements. But UNION operator does not return duplicate rows so to return duplicate rows UNION ALL operato...
ALIAS Keyword
ALIAS Keyword:
It is used to give temporary names to table and columns. It is very useful for situations where column or table names are too long.
Synatx:
SELECT columnname AS alias_name FROM tablename;
This syntax is used ...
IN operator
IN Operator use:
It allows us to put multiple values in a where clause . With the help of this we can compare multiple values wtih where.
Syntax:
Select columnname(s) from Tablename where columnname IN(value1,value 2, .... value n);
...
Restricting data in Oracle
This blog will help you to restrict data from a database.
You can restrict the rows returned from the query by using the WHERE clause. A WHERE clause contains a condition that must be met, and it directly follows the FROM clause. If the condi...