zoukankan      html  css  js  c++  java
  • oracle-01427

    Oracle / PLSQL: ORA-01427

    Learn the cause and how to resolve the ORA-01427 error message in Oracle.

    Description

    When you encounter an ORA-01427 error, the following error message will appear:

    • ORA-01427: single-row subquery returns more than one row

    Cause

    You tried to execute a SQL statement that contained a SQL subquery that returns more than one row.

    Resolution

    The option(s) to resolve this Oracle error are:

    Option #1

    Rewrite your query so that the subquery only returns one row.

    Option #2

    Change your query to use one of the following with your subquery results:

    For example, if you tried to execute the following SQL statement:

    SELECT *
    FROM orders
    WHERE supplier_id = (SELECT supplier_id
                         FROM suppliers
                         WHERE supplier_name = 'IBM');

    And there was more than one record in the suppliers table with the supplier_name of IBM, you would receive the following message:

    Oracle PLSQL

    The most common way to correct this SQL statement is to use the IN conditionas follows:

    SELECT *
    FROM orders
    WHERE supplier_id IN (SELECT supplier_id
                          FROM suppliers
                          WHERE supplier_name = 'IBM');
  • 相关阅读:
    CNN网络改善的方法——池化
    tensorflow 卷积层
    CNN输出维度的计算
    CNN滤波器
    CNN如何识别一幅图像中的物体
    什么是卷积?
    windows 和 linux 安装 tensorflow
    终端安装opencv
    css3圆形光环闪烁效果
    微信小程序
  • 原文地址:https://www.cnblogs.com/zqyanywn/p/5856430.html
Copyright © 2011-2022 走看看