var sidebar_align = 'right';
var content_container_margin = parseInt('290px');
var sidebar_width = parseInt('270px');
Unanswered: How do I: SELECT * FROM (1, 2, 3, 4, 5)
Is there an easy way to do this:
I want to get 5 rows with one column each. I can do this with some more complex T-SQL and table variables, but is there an easy way to do this with basic SQL?
SELECT * FROM (1, 2, 3, 4, 5)
You mean you want to split (\ normalise) a csv string?
Something like this one:
ur codings are working excelent.
No, I wanted a small list of hard coded values in a query. I figured it out. I knew this already but my mind was just moving a little slowly this morning:
Originally Posted by pootle flump
SELECT * FROM
(SELECT 1 AS Value UNION
SELECT 2 AS Value UNION
SELECT 3 AS Value UNION
SELECT 4 AS Value UNION
SELECT 5 AS Value) AS ValueTable
Well if your doing that, you might as well make a numbers table
Well, this query is actually part of an INSERT command that's only run once during db setup. It populates a constant configuration table.
If this was a more general query, I would definitely make a separate table, but for this, that's just more work than necessary.