WITH RECURSIVE parts ( component, subcomponent, quantity ) AS
(
SELECT CAST( NULL AS VARCHAR ), -- CASTs must be used
'bookcase',
`enter code here` -- to declare the
CAST( 1 AS INT ) -- correct datatypes
UNION ALL
SELECT b.component,
b.subcomponent,
p.quantity * b.quantity
FROM parts p
JOIN bookcase b
ON p.subcomponent = b.component
)
update updte_date
set subcomponent='newdate'
FROM parts,update_date --error update
Request clarification before answering.
Please do not post garbage... please ask an actual question, with actual code, and an actual error message.
HOWEVER... you have a record on this forum of not even trying. In my opinion you should be banned for wasting everyone's time.
Could not execute statement.
Syntax error near 'CAST' on line 6
SQLCODE=-131, ODBC 3 State="42000"
Line 1, column 1
WITH RECURSIVE parts ( component, subcomponent, quantity ) AS
(
SELECT CAST( NULL AS VARCHAR ), -- CASTs must be used
'bookcase',
`enter code here` -- to declare the
CAST( 1 AS INT ) -- correct datatypes
UNION ALL
SELECT b.component,
b.subcomponent,
p.quantity * b.quantity
FROM parts p
JOIN bookcase b
ON p.subcomponent = b.component
)
update updte_date
set subcomponent='newdate'
FROM parts,update_date --error update
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
| User | Count |
|---|---|
| 5 | |
| 4 | |
| 4 | |
| 3 | |
| 2 | |
| 2 | |
| 2 | |
| 2 | |
| 2 | |
| 2 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.