Search
 
SCRIPT & CODE EXAMPLE
 

SQL

Query the list of CITY names ending with vowels (a, e, i, o, u) from STATION. Your result cannot contain duplicates.

SELECT DISTINCT city FROM station WHERE city RLIKE '[aeiouAEIOU]$';
Comment

Query the list of CITY names from STATION that do not start with vowels and do not end with vowels. Your result cannot contain duplicates.

SELECT DISTINCT CITY FROM STATION WHERE CITY REGEXP '^[^aeiou].*[^aeiou]$';
Comment

Query the list of CITY names from STATION that either do not start with vowels or do not end with vowels. Your result cannot contain duplicates.

select distinct city from station where city not regexp '^[aeiou]' or city not regexp '[aeiou]$';
Comment

PREVIOUS NEXT
Code Example
Sql :: postgres cast as currency format 
Sql :: mysql add column after another 
Sql :: generate sequence number in sql server 
Sql :: replace string value in sql 
Sql :: pl/sql cursor 
Sql :: update from table tsql 
Sql :: mariadb add foreign key 
Sql :: SQL CREATE UNIQUE INDEX for Unique Values 
Sql :: postgresql export database 
Sql :: SQL Modify Column in a Table -MySQL 
Sql :: oracle nextval insert 
Sql :: to date oracle 
Sql :: sql declare table variable 
Sql :: oracle timestamp to date 
Sql :: select last row mysql 
Sql :: mysqldump ignore table 
Sql :: sqlite indexes 
Sql :: replace null in sql 
Sql :: call function sql oracle 
Sql :: mysql event last execution 
Sql :: postgres list users and roles 
Sql :: how to drop function in sql 
Sql :: how to change the auto increment in existing table mysql 
Sql :: sql line numbers 
Sql :: The local psql command could not be located 
Sql :: sum sqlalchemy 
Sql :: sql paging query 
Sql :: sqlite create tables 
Sql :: sql between operator 
Sql :: declare varchar sql server 
ADD CONTENT
Topic
Content
Source link
Name
3+3 =