'Unable to utilize a field resulting from CAST sub-query
Summarize the problem: I need to capture the result of the CAST sub-query. When executing both SELECT statements only, the query is successful and I can see the returned value in DT_CONV (2022-03-17).
However, when I attempt to utilize DT_CONV or current_date_yyyy_mm_dd_conv, in a lower part of the query, the system does to recognize it.Syntax error: Expected end of input but got identifier "DT_CONV" at [1:1] Unrecognized name: current_date_yyyy_mm_dd at [24:82]
Describe what you’ve tried: Looked at many, many syntax examples
When appropriate, show some code: SELECT (SELECT CAST(CURRENT_DATE() AS STRING) AS current_date_yyyy_mm_dd_conv) AS DT_CONV , Office_Location , Pole_NBR etc......
Thanks!
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
