Microsoft KB Archive/70829: Difference between revisions
From BetaArchive Wiki
(importing KB archive) |
m (Text replacement - ">" to ">") |
||
Line 10: | Line 10: | ||
<pre> select @veryhigh=price from titles | <pre> select @veryhigh=price from titles | ||
where price | where price > 10 compute max(price)</pre> | ||
CAUSE This syntax is incorrect. | CAUSE This syntax is incorrect. | ||
RESOLUTION Use the following syntax to assign a computed value to a local variable: | RESOLUTION Use the following syntax to assign a computed value to a local variable: | ||
<pre> select @veryhigh = max(price) from titles where price | <pre> select @veryhigh = max(price) from titles where price >10</pre> |
Revision as of 10:50, 21 July 2020
PRSQL9103009: Cannot Assign a Local Variable a Computed Value ID Number: Q70829
1.10 OS/2 buglist1.10
Summary:
PROBLEM ID: PRSQL9103009
SYMPTOMS Using the following syntax to assign a computed value to a local variable causes SQL Server to GP-fault:
select @veryhigh=price from titles where price > 10 compute max(price)
CAUSE This syntax is incorrect.
RESOLUTION Use the following syntax to assign a computed value to a local variable:
select @veryhigh = max(price) from titles where price >10