aiaiDBA

加微信获取免费职业规划+学习资料,了解年薪50万的DBA是如何练成的

13718043309

010-86462881

PLS-00359: assignment target in 'string' must have components

PLS-00359: assignment target in 'string' must have components
Cause: An assignment target was declared that lacks the components needed to store the assigned values. For example, this error occurs if you try to assign a row of column values to a variable instead of a record, as follows: DECLARE dept_rec dept%ROWTYPE; my_deptno dept.deptno%TYPE; ... BEGIN SELECT deptno, dname, loc INTO my_deptno -- invalid FROM dept WHERE ...
Action: Check the spelling of the names of the assignment target and all its components. Make sure the assignment target is declared with the required components and that the declaration is placed correctly in the block structure.

请先 登录 后评论

1 个回答

小智
PLS-00359:“ string ”中的赋值目标必须有组件,
.原因:分配目标被声明为缺少存储分配值所需的组件。例如,如果您尝试将一列列值分配给变量而不是记录,则会发生此错误,如下所示:DECLARE dept_rec dept%ROWTYPE; my_deptno dept.deptno%TYPE; ... BEGIN SELECT deptno,dname,loc INTO my_deptno - invalid FROM dept WHERE ...,
.操作:检查分配目标及其所有组件名称的拼写。确保使用所需组件声明分配目标,并将声明正确放置在块结构中。,
.
请先 登录 后评论