ORA-01795: the maximum number of expressions in the list is 1000

Source: Internet
Author: User

A developer encountered an error: ORA-01795: the maximum number of expressions in the list is 1000

Statement is a select xxx from xxx where xxx in (xx, xx ,.....);

Let's take a look at the error:

01795,000 00, "maximum number of expressions in a list is 1000"
// * Cause: Number of expressions in the query exceeded than 1000.
// Note that unused column/expressions are also counted
// Maximum number of expressions that are allowed are 1000.
// * Action: Reduce the number of expressions in the list and resubmit.

 

It can be seen from this that a list contains a maximum of 1000 values, that is to say, a maximum of 1000 values in. This error is reported if there are more than 1000 values in brackets.

The solution is simple, that is, to split an in statement into multiple in statements. If it exceeds 1000, it is split into two in statements. If it exceeds 4000, it is split into five in statements.

Change to SQL as follows: select xxx from xxx where xxx in (xx, xxx ...) or xxx in (xx, xx ,...) or xxx in (xx, xx ,...);

GoldenGate performs two-way Oracle-Oracle replication without using a Data Pump

One-way Oracle-Oracle Replication Using the GoldenGate Data Pump

How to debug Oracle Data Pump (expdp/impdp)

Oracle Database Export data pump (EXPDP) file storage location

Export of Oracle 10g Data Pump Partition Table

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.