Question : Doubt in maximum query size in Oracle

Hi,
   We are working on Oracle 8i on HP-UX 11. In the PL/SQL layer, we need to dynamically form a query using values that were input by the user.
   For e.g., the user is allowed to enter upto 10000 names.
   The query that would be constructed would be of the form:
   Select col1, col2 from table_name where col3 in ();

   The above mentioned query might grow to a size of around 70K or mroe depending on the user input.
   Two doubts that we have are:
   1. Is there a limit to the size of the query (length of the query string) that Oracle supports?
   2. Since this string (the query formed) may have a length of 70K or even more, which datatype can we use to store it. We believe the max. size of a VARCHAR2 datatype is 32767. What datatype can we use to store the query?

Regards,
Ram.

Answer : Doubt in maximum query size in Oracle

Hello!

I can't imagine that user will enter so large information (compare to book!).
I think  32K in large excess for this task.

Theoretically you may store your queries in CLOB datatype.

Best regards,
Yaroslav.
Random Solutions  
 
programming4us programming4us