Collections:
NAME_CONST() - PS Thread ID of Given Connect
How to provide a column name for a constant in a SELECT statement using the NAME_CONST() function?
✍: FYIcenter.com
NAME_CONST(con) is a MySQL built-in function that
provides a column name for a constant in a SELECT statement.
For example:
SELECT NAME_CONST('domain', 'dba.fyicenter.com'); -- +-------------------+ -- | domain | -- +-------------------+ -- | dba.fyicenter.com | -- +-------------------+ SELECT NAME_CONST('length', LENGTH('dba.fyicenter.com')); ERROR 1210 (HY000): Incorrect arguments to NAME_CONST
Reference information of the NAME_CONST() function:
NAME_CONST(const): name Provides a column name for a constant in a SELECT statement. Arguments, return value and availability: const: Required. The constant to be named. name: Return value. The column name in the result set. Available since MySQL 4.0.
⇒ NULLIF() - NULL on Equal Values
⇐ LEAST() - Finding the Least/Minimum Value
2025-01-07, 855🔥, 0💬
Popular Posts:
What is SQL Server Transact-SQL (T-SQL)? SQL Server Transact-SQL, also called T-SQL, is an extension...
How To Update Multiple Rows with One UPDATE Statement in SQL Server? If the WHERE clause in an UPDAT...
How To Use SQL*Plus Built-in Timers in Oracle? If you don't have a stopwatch/timer and want to measu...
How To Format Time Zone in +/-hh:mm Format in SQL Server Transact-SQL? From the previous tutorial, y...
Where to find answers to frequently asked questions on INSERT, UPDATE and DELETE Statements in MySQL...