Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6104873
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T13:53:32+00:00 2026-05-23T13:53:32+00:00

I have a table on my jsp page that will have a column populated

  • 0

I have a table on my jsp page that will have a column populated by a database column with type CLOB. I am running into some trouble doing this, and have seen other questions asked about this, but the answers have not worked for me. Here is my statement where comments is a CLOB.

   stmt = conn.prepareStatement("SELECT DISTINCT restriction, person, start_date, end_date, comments "
                           + "  FROM restrictions WHERE person = ? "
                           + "   AND (start_date BETWEEN TO_DATE (? , 'yyyy/mm/dd') AND TO_DATE (? , 'yyyy/mm/dd') "
                           + "    OR start_date < TO_DATE (? , 'yyyy/mm/dd') AND end_date IS NULL) " );

        stmt.setString(1, Id);
        stmt.setString(2, StartRest);
        stmt.setString(3, EndRest);
        stmt.setString(4, EndRest);
        result = stmt.executeQuery();     

And then I will have the columns in a while loop:

   while (result.next()) {     
        restrictions = StringUtils.defaultString(result.getString("str_restriction"));
        .......
        // here is where I would get my Clob data from the query.

So, basically, I was wondering if there is a way to translate the CLOB in the query, or even in the java code, so it would be usable in my page.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T13:53:33+00:00Added an answer on May 23, 2026 at 1:53 pm

    The problem comes from the distint clause of the query, which can’t be applied to a CLOB.

    Check if the distinct keyword is really needed. Or maybe you could rewrite your query as

    select restriction, person, start_date, end_date, comments from restrictions 
    where id in (select distinct id from restrictions where <original where clause>)
    

    PS: next time, include the error message and your database in the question. I’ve been able to find the problem with a simple google search on “ora-00932 clob”.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a functional JSP page that accepts URL parameters and updates a table
I have table with some fields that the value will be 1 0. This
Hello i have a JSP page that displays records from animal table in my
I would like to have a single JSP page that will do the following:
I have a home page in JSP of my MVC application that have some
I have a JSP page that queries a MySQL database, I want to send
I'm running tomcat and have some jsp pages that display a subset of a
I have a .jsp page where I have a GUI table that displays records
I have a .jsp page that displays a payment table with 4 columns. Based
I have JSP page that contains table. when I click on one row of

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.