我想从我给列SELECT
查询返回的列的名称中的记录中引用数据。我试过这个,但它并不喜欢我试图连接到别名的额外SELECT
:
SELECT Table1.Field1 AS "Pick any " &
CAST((SELECT Table2.Field1
FROM Table2
WHERE Table2.ID = 1) AS VARCHAR(3))
FROM Table2
WHERE Table1.Field2 = "Value"
我想看到的是:
+------------+
| PICK ANY 4 |
+------------+
| Value1 |
| Value2 |
| Value3 |
| Value4 |
| Value5 |
| Value6 |
+------------+