Search
 
SCRIPT & CODE EXAMPLE
 

SQL

sql as

Renames a table or column with an alias value which only exists for the
duration of the query.
Example: Aliases north_east_user_subscriptions column
SELECT north_east_user_subscriptions AS ne_subs
FROM users
WHERE ne_subs > 5;
Comment

sql as

SELECT CustomerID AS ID, CustomerName AS Customer
Comment

sql asc

Used with ORDER BY to return the data in ascending order.
Example: Apples, Bananas, Peaches, Raddish
Comment

sql as

-- AS is a keyword that allows you to rename a column or table using an alias
SELECT column_name AS 'Alias'
FROM table_name;
Comment

sql as

SELECT NAME AS "Employee Name" FROM PEOPLE;

SELECT p.NAME AS "Employee Name", s.SALARY 
FROM PEOPLE p
JOIN SALARIES s ON p.ID = s.ID;
Comment

PREVIOUS NEXT
Code Example
Sql :: import sql file to mysql db using shell commands 
Sql :: not equal in mysql query 
Sql :: postgres copy table 
Sql :: what is subquery in sql 
Sql :: wp sql to update admin email 
Sql :: syntax error at or near "AUTO_INCREMENT" 
Sql :: automate mysql cli query 
Sql :: into in sql 
Sql :: mysql select field if condition 
Sql :: find in set in postgresql 
Sql :: oracle no data found error code 
Sql :: mysql sleep connections 
Sql :: Kill session in SQL Developer 
Sql :: foreign key sql 
Sql :: sql server synonym 
Sql :: join multiple tables in sql 
Sql :: data types mysql vs postgresql 
Sql :: sql ignore 
Sql :: mac docker mysql 
Sql :: postgres ERROR: relation "user" does not exist 
Sql :: mysql insert into multiple tables 
Sql :: delete join sql server 
Sql :: update view sql 
Sql :: cardinality example sql 
Sql :: primary key auto increment in postgresql 
Sql :: oracle exchange subpartition 
Sql :: psql list view rules 
Sql :: hou to run job from cmd .exe sql server jop 
Sql :: fonction stockée sql*plus 
Sql :: oracle synonym package dblink 
ADD CONTENT
Topic
Content
Source link
Name
4+2 =