Oracle PL/SQL ORA-00947 Not Enough Values Error ¿À¶óŬÀº PL / SQL ¿À¶ó - 00947 ÃæºÐÇÏÁö ¾ÊÀº °ª ¿À·ù

In Oracle database, the following error message may appear when an incorrect SQL statement is used, in SQL Plus or in anywhere that send SQL queries to the databases such as stored procedure or external programs. Oracle µ¥ÀÌÅͺ£À̽º¿¡¼­´Â ´ÙÀ½°ú °°Àº ¿À·ù ¸Þ½ÃÁö°¡ ³ªÅ¸³¯ ¼öÀÖ½À´Ï´Ù À߸øµÈ SQL ¹®À» »ç¿ëÇÏ´Â °æ¿ì SQL Ç÷¯½º¿¡¼­ ¶Ç´Â ¾îµð¿¡¼­ ±× µ¥ÀÌÅͺ£À̽º¿¡ ÀúÀå ÇÁ·Î ½ÃÀú ¶Ç´Â ¿ÜºÎ ÇÁ·Î±×·¥°ú °°Àº SQL Äõ¸®¸¦ º¸³¾ ¼öÀÖ½À´Ï´Ù.

PL/SQL: SQL Statement ignored Àº PL / SQL : SQL ¹® ¹«½Ã
PL/SQL: ORA-00947: not enough values Àº PL / SQL : ORA - 00947 : ÃæºÐÇÏÁö °ª


The reason for ORA-00947 error is when a SQL statement requires two sets of value, ie number of number of columns and its value that are specified in the SQL to be equal in number. ORA - 00947 ¿¡·¯¿¡ ´ëÇÑ ÀÌÀ¯´Â ±× ¶§ SQL ¹®À» °¡Ä¡ÀÇ SQL¿¡ ÁöÁ¤µÈ ¹øÈ£¿¡ µ¿µîÇØÁú µÎ ¼¼Æ®¸¦ ¿­ ¹× °¡Ä¡ÀÇ °³¼ö, Áï ¹øÈ£¸¦ ÇÊ¿ä·ÎÇÑ´Ù´Â °ÍÀÔ´Ï´Ù. But the second part of the query which is column values contains fewer items than the first part which is the number of columns. ÇÏÁö¸¸ ¿­ÀÇ °ªÀº Äõ¸®ÀÇ µÎ ¹øÂ° ºÎºÐÀº ¿­À»ÀÇ ÀüÈ­ ¹øÈ£´Â ù ºÎºÐº¸´Ù ÀûÀº Ç׸ñÀÌ Æ÷ÇԵǾîÀÖ½À´Ï´Ù. The error may happens in all kind of SQL statements - Insert, Update or Select - and it can also occur in a WHERE or HAVING clause in which a nested sub-SELECT returns too few columns. ¼öµµ SQL ¹®À»¿¡¼­ ÀϾ´Â ¸ðµç Á¾·ùÀÇ ¿À·ù - »ðÀÔ, ¾÷µ¥ÀÌÆ® ¶Ç´Â ¼±Åà - ±×°Íµµ ¾îµð°Å³ªÇÏ´Â µ¥ Á¶Ç׿¡¼­ ¹ß»ýÇÒ ¼öÀÖ´Â ÁßøµÈ ÇÏÀ§ - ¼±Åõµ ¸î ¿­À» ¹ÝȯÇÕ´Ï´Ù. If the SQL does not specify columns, it means that the values entered are less that the columns existed in the table in database. °æ¿ì´Â SQL ¿­À» ÁöÁ¤ÇÏÁö ¾ÊÀ¸¸é, ±× °ªÀ» ÀÔ·Â ¿­À» ´ú µ¥ÀÌÅͺ£À̽º¿¡¼­ Å×ÀÌºí¿¡ Á¸ÀçÇÏ´Â °ÍÀ» ÀǹÌÇÕ´Ï´Ù.

For example, the ORA-00947 error will be returned if you try to execute the following SQL statements: ´ÙÀ½ SQL ¹®À» ½ÇÇàÇÏ·Á°íÇÏ¸é ¿¹¸¦ µé¾î, ORA - 00947 ¿À·ù°¡ ¹ÝȯµË´Ï´Ù :

INSERT INTO Customers (Customer_ID, Customer_Name, Birthday) VALUES (¡¯1¡Ç, ¡®My Customer¡¯); ('1 ','³» °í°´ ') (Customer_ID, Customer_Name, »ýÀÏ) °ªÀ¸·Î °í°´À» »ðÀÔ;

or ¶Ç´Â

SELECT * FROM Customers WHERE (Customer_ID, Customer_Name) IN (SELECT Customer_ID FROM Orders); * ¼Õ´ÔÀº ¾îµð¿¡ (Customer_ID, Customer_Name) (¼±Åà ÁÖ¹® Customer_ID¿¡¼­) ¼±ÅÃ;

To solve the error and correct the problem, check that the number of values provided in the column values part is equal that the columns specified, or the number of columns in table, and change the SQL statement to make them equal. ¿À·ù¸¦ ÇØ°áÇÏ·Á¸é ¹®Á¦°¡ ÇØ°áµÇ¾ú´ÂÁö È®ÀÎ °ªÀº ¿­ °ªÀ» ºÎºÐ¿¡ Á¦°øµÈÀÇ ¼ýÀÚ ¿­, ¶Ç´Â Å×ÀÌºí¿¡ÀÖ´Â Ä÷³ÀÇ ¼ö¸¦ ÁöÁ¤ÇÏ°í ±×µéÀ» µ¿µîÇÏ°Ô SQL ¹®À» º¯°æ ÆòµîÀÌ´Ù.

You can either reduce the number of columns, or increase the number of values provided to the column to make the SQL statement equaled. ´ç½Åµµ Ä÷³ÀÇ ¼ýÀÚ¸¦ ÁÙÀÏ ¼öÀÖ½À´Ï´ÙÀ̳ª °ªÀº Ä÷³ Á¦°øÀÇ ¼ö¸¦ Áõ°¡ÇÏ°Ô SQL ¹®À» È®ÀÎÇÕ´Ï´Ù. This applies to the nested SQL statements with HAVING or WHERE clause too. ¶Ç´Â ³Ê¹« Á¶Ç×ÀÌ °®´Â ÁßøµÈ SQL ¹®À»¿¡ Àû¿ëµË´Ï´Ù. For example, the correct SQL statements should be like the following: ¿¹¸¦ µé¾î, ¿Ã¹Ù¸¥ SQL ¹®À» ´ÙÀ½°ú °°ÀÌÇØ¾ßÇÑ´Ù :

INSERT INTO Customers (Customer_ID, Customer_Name, Birthday) VALUES (¡¯1¡Ç, ¡®My Customer¡¯, ¡®08/08/1988¡Ç); (Customer_ID, Customer_Name, »ýÀÏ) °ªÀ¸·Î °í°´À» »ðÀÔ ('1 ','³» °í°´ ', '08 / 1,988ºÐÀÇ 08');

or ¶Ç´Â

INSERT INTO Customers (Customer_ID, Customer_Name) VALUES (¡¯1¡Ç, ¡®My Customer¡¯); ('1 ','³» °í°´ ') (Customer_ID, Customer_Name) °ªÀ¸·Î °í°´À» »ðÀÔ;

or ¶Ç´Â

SELECT * FROM Customers WHERE (Customer_ID, Customer_Name) IN (SELECT Customer_ID, Customer_Name FROM Orders); * °í°´À¸·ÎºÎÅÍ ¼±Åà (Customer_ID, Customer_Name) (¼±Åà Customer_ID, Customer_Name¿¡¼­ ÁÖ¹®);

or ¶Ç´Â

SELECT * FROM Customers WHERE (Customer_ID) IN (SELECT Customer_ID FROM Orders); * °í°´¿¡¼­ ¼±Åà () (¼±Åà Customer_ID¿¡¼­ ÁÖ¹®)¿¡ Customer_ID;

IMPORTANT : This is a machine translated page which is provided "as is" without warranty. Áß¿ä :ÀÌ ±â°è´Â "º¸Áõµµ¾øÀÌÀÖ´Â ±×´ë·Î"Á¦°øµË´Ï´Ù ÆäÀÌÁö¸¦ ¹ø¿ªÇß´Ù. Machine translation may be difficult to understand. ±â°è ¹ø¿ªÀ» ÀÌÇØÇϱ⠾î·Á¿ï ¼öÀÖ½À´Ï´Ù. Please refer to À» ÂüÁ¶ÇϽñ⠹ٶø´Ï´Ù original English article ¿ø·¡ ¿µ¾î ¹®¼­ whenever possible. ¾ðÁ¦µç °¡´ÉÇÕ´Ï´Ù.

Share and contribute or get technical support and help at °øÀ¯¿Í ±â¿©Çϰųª ±â¼ú Áö¿ø°ú¿¡ µµ¿òÀÌ My Digital Life Forums ³» µðÁöÅÐ »ýȰ Æ÷·³ .



Leave a Reply ȸ½ÅÀ» ³²°ÜÁÖ¼¼¿ä

You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> ÀÌ·¯ÇÑ ÅÂ±× : title="">Àº <a href="" »ç¿ëÇÒ ¼öÀÖ½À´Ï´Ù <abbr title=""> <acronym title="">ÀÇ <b> <blockquote cite=""> <cite>ÀÇ <code> <¹ã ³¯Â¥ = "">Àº <em>°¡ <i> <q cite=""> <strike>ÀÇ <strong>

Subscribe without commenting ÄÚ¸àÆ®¸¦ ±¸µ¶ÇÏÁö ¾Ê°í


Custom Search

New Articles »õ ¹®¼­

Incoming Search Terms for the Article ¿¡ ´ëÇÑ °Ë»ö ¾à°ü¹Þ´Â Á¦

PL/SQL: ORA-00947: not enough values Àº PL / SQL : ORA - 00947 : ÃæºÐÇÏÁö °ª - - ora-00947 ¿À¶ó - 00947 - - ORA-00947: not enough values ORA - 00947 : ÃæºÐÇÏÁö °ª - - not enough values ÃæºÐÇÏÁö ¾ÊÀº °ª - - oracle sql not in '¿À¶óŬ SQL ¾È¿¡ - - PL/SQL: SQL statement ignored Àº PL / SQL : SQL ¹®À» ¹«½Ã - - insert into + values + plsql »ðÀÔÇÒ + °¡Ä¡ + plsql - - not in sql oracle ¿À¶óŬÀº SQL ¾È¿¡ - - oracle not enough values ¿À¶óŬÀÌ ÃæºÐÇÏÁö °ª - - ORA-00947: insert into ORA - 00947 : »ðÀÔ·Î - - pl/sql statement ignored PL / SQLÀº ¼º¸íÀ» ¹«½Ã - - PL/SQL: ORA-00947: not enough values + pl sql Àº PL / SQL : ORA - 00947 : ÃæºÐÇÏÁö ¾ÊÀº °ªÀ» + ¿ÍÁà´Â SQL - - select into ora 00947 ¿À¶ó 00,947·Î ¼±ÅÃÇÕ´Ï´Ù - - sql insert not enough values ÃæºÐÇÏÁö °ªÀº SQL »ðÀÔ - - Insert statement PL/SQL: ORA-00947: not enough values »ðÀÔ ¼º¸íÀº PL / SQL : ORA - 00947 : ÃæºÐÇÏÁö °ª - - nested sub-select oracle ÁßøµÈ ÇÏÀ§ - ¼±Åà Oracle - - oracle error : not enough value ¿À¶óŬ ¿À·ù : ÃæºÐÇÏÁö °ª - - sql STATEMENT IGNORED ORACLE ¿À¶óŬ SQL ¹®À» ¹«½Ã - - SQL select not numbers ´Â SQL ¼ýÀÚ¸¦ ¼±ÅÃÇÏÁö - - sql not in ¿¡¼­ SQLÇÏÁö - - sql error -942 oracle ¿À¶óŬÀº SQL ¿À·ù -942 - - sql ORA-00947: not enough values ´Â SQL ORA - 00947 : ÃæºÐÇÏÁö °ª - - "ora-00947: not enough values" "¿À¶ó - 00947 : ÃæºÐÇÏÁö °ªÀº" - - oracle select not number ¿À¶óŬÀÇ ¹øÈ£¸¦ ¼±ÅÃÇÏÁö - - ora-00947 insert ¿À¶ó - 00947 »ðÀÔ - - orcale ORA-00947 orcale ORA - 00947 - - pl/sql ORA-00947 insert into select PL / SQLÀ» ORA - 00947·Î »ðÀÔÀ» ¼±Åà - - SQL NOT ENOUGH VALUE ÃæºÐÇÏÁö ¾ÊÀº °¡Ä¡´Â SQL - - SQL Error: ORA-00947: not enough values ´Â SQL ¿À·ù : ORA - 00947 : ÃæºÐÇÏÁö °ª - - INSERT INTO SELECT +PL/SQL »ðÀÔÀ» ¼±ÅÃÇϽʽÿÀ + PL / SQLÀ» - - not enough values ORA-00947: not enough values ÃæºÐÇÏÁö ¾ÊÀº °ªÀ» ORA - 00947 : ÃæºÐÇÏÁö °ª - - not enough values in sql ¿¡ ÃæºÐÇÏÁö ¾ÊÀº °¡Ä¡´Â SQL - - not enough values+sql ÃæºÐÇÏÁö ¾ÊÀº °ªÀ» +ÀÇ SQL - - oracle not enough values error ¿À¶óŬÀÌ ÃæºÐÇÏÁö ¾Ê¾Æ ¿À·ù °ª - - oracle "PL/SQL: Statement ignored" ¿À¶óŬ "Àº PL / SQL : Á¤Ã¥ ¹«½Ã" - - oracle pl sql checking equals ¿À¶óŬÀº SQL üũ ¿ÍÁà ¾ß - - pl/sql : ora-00947 Àº PL / SQL : ¿À¶ó - 00947 - - PL/SQL not enough values PL / SQLÀº ÃæºÐÇÏÁö °ª - - PL/SQL ORA-00947 PL / SQLÀ» ORA - 00947 - - pls-00947 PLS - 00947 - - SQL IN number of values ´Ù¼öÀÇ SQL °ª - - PL/SQL: ORA-00947: not enough values Àº PL / SQL : ORA - 00947 : ÃæºÐÇÏÁö °ª - - all ¸ðµÎ - - ora 00947 ¿À¶ó 00,947 - - oracle sql From "sub Select" "Àá¼öÇÔ"À» ¼±Åÿ¡¼­ '¿À¶óŬ SQL - - error : not enough values on Oracle 8i ¿À·ù : ¿À¶óŬ 8i¿¡ ÃæºÐÇÏÁö ¾ÊÀº °ª - - not in no plsql ¾Æ´Ï ¾Æ´Ï plsql - -