select Query result display problem

select Query result display problem

Hi,

String SQL_QUERY ="from Cc";
 Query query = session.createQuery(SQL_QUERY);
 for(Iterator it=query.iterate();it.hasNext();){
       Object[] row = (Object[]) it.next();
       System.out.println("ID: " + row[0]);

       System.out.println("Name: " + row[1]);

     }

when I am executing the above query the following error will happend

Hibernate: select cc0.id as col00 from cc cc0_ Cc$$EnhancerByCGLIB$$2235676a cannot be cast to [Ljava.lang.Object;

can any one suggest the solution for this

Thanks

View Answers









Related Tutorials/Questions & Answers:
select Query result display problem
select Query result display problem  Hi, String SQL_QUERY ="from Cc"; Query query = session.createQuery(SQL_QUERY); for(Iterator it=query.iterate...]); } when I am executing the above query the following error will happend
how to forward select query result to jsp page using struts action class
how to forward select query result to jsp page using struts action class  how to forward select query result to jsp page using struts action class
Advertisements
display result
display result  i want a code that takes input from user through dropdown box and display the result into table.all the values regarding the user input must be displayed. i am using mysql database   hi i want study
result problem
result problem  sir,i have written program given below...=con.createStatement(); ResultSet rs=stmt.executeQuery("select * from studentbase where...=stmt.executeQuery("select * from data where name='"+name1
Display Problem
Display Problem  i am creating a small window application , i want to fetch data from ms-access(db) and want to display it on tables. what options are there to show result on table. is CSS helpfull
select query
select query  how to write select query with where clause having multiple variables. example: i want to select the data from DB in which i want to check againest two variable in where cluase. String sql = "select * from
select query
select query  how to retrieve a single image from mysql table using $row[] value
select query in mysql
select query in mysql  Select query in mysql. Can anyone
query problem
", "root", "root"); String query = "select Ename from employee where Designation...query problem  how write query in jsp based on mysql table field? i have employee table it contain designation field, how write query in jsp
select result from three tables using sql.
select result from three tables using sql.  I want to get a result from three tables. i dont how to write the sql query. Please help me. "I want to display Name,Username and Product_Name where Id=007" table "register" Name
JSP - Problem of displaying result at webpage
JSP - Problem of displaying result at webpage  Can anyone please help to solve my problem below. My webpage has problem in displaying result position. The result should be display below my title. How do i solve it? Thank you so
how can i display a editable result of form?
how can i display a editable result of form?  how can i display a editable result of form? i know how to display form result but the result... to display form result in same page i have alredy created a hidden div which
Select from select list + display
Select from select list + display  i have a select list containing... select EmpCode from the select list, the corresponding EmpName and DeptName should...;/div> <tr><td><b>Select:</b></td><td><
select query using hibernate
select query using hibernate  Hi, can any one tell me to select records from table using hibernate. Thanks   Please visit the following link: Hibernate Tutorials The above link will provide you different
query regarding multiple select
query regarding multiple select  i have a select in jsp with multiple options.When i select multiple values i am not able to insert it into database and how do i retrieve them..please help me with an example code
Jfreechart chart display problem
(request.getParameter("q")); String query="select dateof,dayinprice,company from stockprice...Jfreechart chart display problem  Using JSP and Jfreechart displays the chart fine on an internal browser in eclipse but doesnt display it on Chrome
iterator display problem - Struts
iterator display problem   in action class i store database data in arrraylist but after success how can i display those data in jsp page using... friend, Code to help in solving the problem : Iterator Tag
display sql query in hibernate
display sql query in hibernate  If you want to see the Hibernate generated SQL statements on console, what should we do
Problem to display checkbox item
Problem to display checkbox item  Hi, Following is my code: <...; Statement st=null; st=conn.createStatement(); rs = st.executeQuery("select...; I want to display records, when i click on submit button or any dumy button
PHP SQL Result
; This example illustrates how to display result on the browser and how to use the result in the php application. To understand how to display the result...;* FROM users" is executed using mysql_query() method to select
delete query problem - Hibernate
correctly , the problem is only delete query. 2) query.executeUpate(); ->...delete query problem  SessionFactory fact = new Configuration...'"; Query query = sess.createQuery(hql) query.executeUpate(); // int row
Jsp not display desired result - JSP-Servlet
Jsp not display desired result  Hello all, I want to be able to display picture from Ms Sql 2000 using JSP. Below is the code I used but does not display anything. Please assist me. Thanks
Integer display problem
Integer display problem  class Bean{ int n1,n2; public Bean(){ } public Bean(int n1, int n2){ this.n1=n1; this.n2=n2; } public...); } } In above program value of n1 should display 10. But it is displaying 8. what
Problem in executing query....
Problem in executing query....  Suppose there is a textbox or a text... this data with request.getParameter() but when I execute the query to store in oracle it is showing error because of the '.I understand where the problem is.If
JSP:select image for db and display in image tag
JSP:select image for db and display in image tag  Hi, i am new to this forum. My query is that, i am trying to display image in tag but i am...); response.getOutputStream().flush(); } i think, this code will display image
JSP:select image for db and display in image tag
JSP:select image for db and display in image tag  Hi, i am new to this forum. My query is that, i am trying to display image in tag but i am...); response.getOutputStream().flush(); } i think, this code will display image
JSP:select image for db and display in image tag
JSP:select image for db and display in image tag  Hi, i am new to this forum. My query is that, i am trying to display image in image tag but i am...); response.getOutputStream().flush(); } i think, this code will display
Problem with display of images in applets - Applet
Problem with display of images in applets  Hi all, When I run... in figuring out the problem....  Hi frined, import java.applet.*; import..., this); } } --------------------------------------- Display image in Java Applet
JComboBox Display Problem - Java Beginners
JComboBox Display Problem  I am create one program that contain two combo boxes. If first combo box i am display all date. If i select one date from first combo box then the second combo box display some dates based on first
SELECT query using executeUpdate() instread of executeQuery()
SELECT query using executeUpdate() instread of executeQuery()  can we execute SQL SELECT query using executeUpdate() instread of executeQuery() method   Hi Friend, No, You cannot. Thanks
Problem in updating query in Hibernate - Hibernate
Problem in updating query in Hibernate  Hi, I have used a query to update the existing columns of one table. The query updates the records in the main table but it does not update the tables that are mapped from the main table
Write a query to display a row using index
Write a query to display a row using index  Write a query to display a row using index
Select query in JSP
Select query in JSP We are going to describe select query in JSP... that we use SELECT query. SELECT query is a retrieve the data from database than... interface. Syntax of select query:- SELECT * FROM TableName; Now we have
problem in insert query - JSP-Servlet
problem in insert query  Hi! I am using this statement for data...   Hi friend, We check your Query it is correct .If you have problem plz give full details with source code and visit to : http
display from select box - JSP-Servlet
display from select box  I am doing a jsp project. In this jsp project i have to show the photos in one cell depending on the selection from other selection box which is in the same page. The photos are stored
MS-ACCESS Query Problem - SQL
MS-ACCESS Query Problem  hi sir i have table which is initially... tables Course and Class wise Ex..Query like: if we execute this Query "Select * from Student where Course="BCA" and Class="I"; it may contain many
how to export the query result in SQL Server to .csv file?
how to export the query result in SQL Server to .csv file?  how to write table data into CSV file using SQL SERVER 2008
SQL display date in between query
SQL display date in between query  how to get ( 15 march 2011) and (15/03/2011) output using SQL
SELECT query using executeUpdate() instread of executeQuery()
SELECT query using executeUpdate() instread of executeQuery()  for Ex...{ st.executeUpdate("select * from EMP"); //gives us Exception... executeUpdate() method with select quesry then you can't be able to retrieve data from
i have problem with this query... please tell me the resolution if this .........
i have problem with this query... please tell me the resolution if this .........  select length(ename)||' charecters exist in '||initcap(ename)||'s name' as "names and length" from emp
i have problem with this query... please tell me the resolution if this .........
i have problem with this query... please tell me the resolution if this .........  select initcap(ename),job from emp where substr(job,4,length(job,4,3)))='age
how to display(update) current date and month in select box on selecting the year.
how to display(update) current date and month in select box on selecting the year.  how to display(update) current date and month in select box on selecting the year
display records with images problem - JSP-Servlet
display records with images problem  hello, i am developing HR application whereby i want to display employee records and their pictures on web... with a unique id. Also i wrote i jsp that link to servlet in order to display
Php Sql Result
a select query by using mysql_query method and stored it in the result variable which indicate by $ (dollar sign). Here we display the result in form of html...Php Sql Result This example illustrates how to display result on the browser
php problem
php problem  Hello!! I have a problem ,i want to display the data... not connect: ' . mysql_error()); } $sql = 'SELECT * FROM users WHERE username="'.$username.'" LIMIT 1'; $result = mysql_query( $sql); if(! $result) { die('Could
The query used to display all tables names in SQL Server.
The query used to display all tables names in SQL Server.  What is the query used to display all tables names in SQL Server (Query analyzer
Select Employee and display data from access database in a jtable
Select Employee and display data from access database in a jtable  I there Iam a java beginner. I have to create a application where I can select a employee's name from a comboBox and the jtable will be filled with all
SQL Select, HQL Select Example, HQL Select Query
to load the Entity objects. The HQL Select query is used to load Entity based...). Writing HQL Select query: Here is the simple HQL Select example that loads all the customer. String HQL_QUERY = "select c from Customer c"; Here
Hibernate Select Query
This tutorial contain the explanation of Select clause
How to display all the rows in JSP ,MySQL select condition statement IN dept_table
How to display all the rows in JSP ,MySQL select condition statement IN dept_table  I iam unable to display all the rows in JSP select statement from... is displayed.@select * from department where dept_no=10;My display code in JSP

Ads