I would like to take a list of names (e.g. john, mary, paul) and create a SQLite "select" query that will return this list in a column of rows. Based on this, the following was stated:
"According to the SQL92 standard, a VALUES expression should be able to stand on itself. For example, the following should return a one-column table with three rows:"
VALUES 'john', 'mary', 'paul';
In theory, the result set would look like:
john
mary
paul
But as the page seems to indicate, this is an unsupported feature in SQLite. The only way that I can figure out how to do this is by unioning a series of select statements like so:
SELECT 'john' AS name
UNION ALL SELECT 'mary' AS name
UNION ALL SELECT 'paul' AS name;
Is this the only way to do this in SQLite or is there an easier way?
JavaScript questions and answers, JavaScript questions pdf, JavaScript question bank, JavaScript questions and answers pdf, mcq on JavaScript pdf, JavaScript questions and solutions, JavaScript mcq Test , Interview JavaScript questions, JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)