SQL Alter Table

The SQL ALTER TABLE is used to add, delete or modify columns in an existing table. SQL Alter Table:- ALTER TABLE table_name ADD column_name datatype Drop Column:- ALTER TABLE table_name DROP COLUMN column_name; Add Unique Constraint:- ALTER TABLE table_name ADD CONSTRAINT MyUniqueConstraint UNIQUE(column1, column2…); Add Primary Key:- ALTER TABLE table_name ADD CONSTRAINT PrimaryKey PRIMARY KEY […]

SQL Indexes

Indexes are extraordinary lookup tables that the database web crawler can use to accelerate information recovery. Basically, a list is a pointer to information in a table. An index speeds up SELECT questions and WHERE provisions, yet it backs off information data, with UPDATE and INSERT proclamations. Lists can be made or dropped with no […]

SQL Joins

SQL joins are used to combine rows from two or more tables. The following SQL statement of INNER JOIN:- Example:- SELECT Orders.OrderID, Visitors.CustomerName, Orders.OrderDate FROM Orders INNER JOIN Visitors ON Orders.CustomerID= Visitors.CustomerID; Different SQL JOINs:- The types of the different SQL JOINs you could use:- INNER JOIN: Returns all rows when there is at least […]

SQL Aliases

SQL aliases are used for the moment rename a table or a column title. Mainly aliases are created to make column names more clear. Syntax for Columns:- SELECT column_name AS alias_name FROM table_name; Syntax for Tables:- SELECT column_name(s) FROM table_name AS alias_name; Example:- SELECT VisitorName AS Visitor, ContactName AS [Contact Person] FROM Visitors; Example2:- SELECT […]

SQL Between

The BETWEEN operator is used to select values within a collection. The values could be numbers, text, or dates. Syntax:- SELECT column_name(s) FROM table_name WHERE column_name BETWEEN value1 AND value2; BETWEEN Example:- The subsequent SQL statement selects all wears with a price BETWEEN 100 and 200:- SELECT * FROM Wears WHERE Price BETWEEN 100 AND […]

SQL Injection

At the point when SQL is utilized to show information on a site page, it is regular to let web clients enter their own particular pursuit values. SQL explanations are content just, it is simple, with a little bit of PC code, to progressively change SQL articulations to give the client chose information. SQL Injection […]