SQL HELLO WORLD
SQL HELLO WORLD is a SQL statement in the SELECT Queries category. The simplest SQL query — a literal SELECT statement. Works in every SQL database. The syntax is SELECT 'Hello, World!';. It returns greeting string. A typical example: SELECT 'Hello, World!' AS greeting; -- Returns: Hello, World! SELECT 'Hello, World!'; -- Simpler form (ANSI SQL requires FROM, but most DBs allow without) -- With FROM DUAL (Oracle): SELECT 'Hello, World!' FROM DUAL; -- With FROM (MySQL, PostgreSQL, SQL Server): SELECT 'Hello, World!'; -- No FROM clause needed A close relative is SELECT, which retrieves data from a table. The most fundamental SQL statement. A close relative is SELECT *, which selects all columns from a table. A close relative is SELECT DISTINCT, which returns only distinct (unique) values from the specified columns. More about this category: Core SELECT query clauses — SELECT, FROM, WHERE, GROUP BY, HAVING, ORDER BY, LIMIT.