Home Tutorialhelp Comment Hi, I am getting the following error when i try t

 
 

Comment

Alex
Hi, I am getting the following error when i try t,
January 25, 2007 at 2:41 AM

Hi,
I am getting the following error when i try to run FirstExample.

Exception in thread "main" java.lang.NullPointerException
at aruna.tutorial.hibernate.FirstExample.main(FirstExample.java:35)

Please help!!!


View All Comments | View Tutorial
Advertisement
Related Tutorial and Articles
Struts Questions

i am getting the problem when i am downloading the pdf file from oracle 10g database - Struts
i am getting the problem when i am downloading the pdf file from oracle 10g... but it is not downloading .Please help to me.i am getting the below error when downloading... into datbase and download the pdf file from database. but when i created the pdf file 

JavaMail Questions

when sending the mail from java I am getting the below error - JavaMail
when sending the mail from java I am getting the below error   when sending the mail from java I am getting the below error : Exception...(to)); // Set the "Subject" header field. message.setSubject("hi 

RMI Questions

:( I am not getting Problem (RMI)
I am not getting Problem (RMI)  When i am excuting RMI EXAMPLE 3,2 I am getting error daying nested exception and Connect Exception   

JSP Servlet Questions

I am getting Undefined in Text Box Very Urgent - JSP-Servlet
I am getting Undefined in Text Box Very Urgent  Respected Sir/Madam, I am R.Ragavendran.. Thanks for your superb reply. I got the coding. But I find... and clicking select button, The pop up window gets closes. But, i am getting 

JDBC Questions

I am getting error.How can i get details
I am getting error.How can i get details  Exception in thread "main" java.sql.SQLException: Listener refused the connecti n with the following error: ORA-12505, TNS:listener does not currently know of SID given in connect 

Spring Framework Questions

I am getting error org.springframework.beans.factory.NoSuchBeanDefinitionException: No bean named 'IS_AUTHENTICATED_ANONYMOUSLY' is defined - Spring
I am getting error org.springframework.beans.factory.NoSuchBeanDefinitionException: No bean named 'IS_AUTHENTICATED_ANONYMOUSLY' is defined  Hello, I am getting error 

JSP Servlet Questions

Getting error java.lang.ClassNotFoundException: com.mysql.jdbc.Driver.
Getting error java.lang.ClassNotFoundException: com.mysql.jdbc.Driver.  I am doing project in JSP with database WampServer and glassfish as server .when i done database connection then i get an error 

Hibernate Questions

I am getting this exception
I am getting this exception   Exception in thread "main" org.hibernate.exception.GenericJDBCException: Cannot open connection at org.hibernate.exception.ErrorCodeConverter.handledNonSpecificException(ErrorCodeConverter.java 

JSP Servlet Questions

i am getting multiple values in listbox
i am getting multiple values in listbox   hi sir, i am using... table group by stuname) order by a.name in a subquery multiple recdates i am getting its working fine, but in main query also i am getting multiple name 

Java Beginners

Nested try
Nested try  Hi, In eclipse without providing input i am getting... versa.pl explain me class Demo { static void nestedTry(String args[]) { try...("Div by zero error!"); } finally { System.out.println("Finally"); } } public 

Swing AWT

i am getting an error in adding a menu item to a menu.
i am getting an error in adding a menu item to a menu.   i am not able to execute the menu program. i am getting an error at menu.add(menuitem); it says add method is undefined for type menu. but as far as i know that is only way 

Hibernate Questions

hi i m new to hibernate..plzzzzzzzzzzzzzz help me.... - Hibernate
://www.roseindia.net/hibernate/selectclause.shtml Thanks.  hi deepak.. when i...hi i m new to hibernate..plzzzzzzzzzzzzzz help me....  hi friends i m new to hibernate..& i m stuck in one positon in my pgm.. its a simple select 

Development process Questions

hi
storing data in xml file using jsp  hi i am storing data in xml file using jsp.in this when i enter data into xml file i am getting xml declaration...; try { System.out.println(name); DocumentBuilderFactory 

Hibernate Questions

hi - Hibernate
hi  hi all, I am new to hibernate. could anyone pls let me know what is generic DAO class generated by MyEclipse while doing mapping. I want...(java.lang.Long id) { log.debug("getting Userin instance with id: " + id); try 

Hibernate Questions

getting following error org.hibernate.AnnotationException: No identifier specified for entity: inheritance_tutorial17.TwoWheeler
getting following error org.hibernate.AnnotationException: No identifier specified for entity: inheritance_tutorial17.TwoWheeler  when i am running following code i am getting following error... package inheritance_tutorial17 

Spring Framework Questions

Getting HTTP 404 error in Spring web MVC with Hibernate Integration
Getting HTTP 404 error in Spring web MVC with Hibernate Integration   Hi, i am Getting HTTP 404 error in Spring web MVC with Hibernate Integration...;Please visit the following links: http://www.roseindia.net/struts/hibernate-spring 

Struts Questions

Page is not getting loaded when I refresh the webpage???
Page is not getting loaded when I refresh the webpage???  **I am... when I refresh the page.* Note: Header section is getting loaded always Could... function in JSP. It will get all details of image section from database. *I am 

JDBC Questions

i cant find any compile time error but there is runtime error.
i cant find any compile time error but there is runtime error.  ... = res.getString("stud_name"); System.out.println(i + "\t\t" + s...){ System.out.println("Error:connection not created"); }   Hi 

Java Server Faces Questions

getting null value in my class when using t:inputFileUpload
getting null value in my class when using t:inputFileUpload  getting null value in my class when using t:inputFileUpload i have implemented all... changes in web.xml also still getting null value when i access in my bean Thanking 

Java Beginners

I/O Program output error
file, but I am getting incorrect output. I have been successfull with part of the program in that it reads the text file and analyzes it, however I need it to take...I/O Program output error  Hello All, I am working on a program 

JDBC Questions

i am inserting an image into database but it is showing relative path not absolute path
i am inserting an image into database but it is showing relative path not absolute path   hi my first page......... Image Enter your name..."); } catch(Exception e) { System.out.println(e); } %> when i compiled it i 

JDBC Questions

i am inserting an image into database but it is showing relative path not absolute path
i am inserting an image into database but it is showing relative path not absolute path   hi my first page......... Image Enter your name..."); } catch(Exception e) { System.out.println(e); } %> when i compiled it i 

IDE Questions

Nested try
Nested try  Each time when i execute this code in eclipse i get..., visit the following link: Nested Try Example...(String args[]) { try { int a = Integer.parseInt(args[0]); int b 

JDBC Questions

i am inserting an image into database but it is showing relative path not absolute path
i am inserting an image into database but it is showing relative path not absolute path   hi my first page......... <html> <head>...) { System.out.println(e); } %> </body> </html> when i compiled it i 

Hibernate Questions

Database Error - Hibernate
by multiple/single users I am getting the following errors. Lock wait timeout...Database Error  Hi, I am working with Struts 1.2---- AJAX...;Hi I am sending u a link where u can find lots of example which helps to solve 

JDBC Questions

hi, Everyone ,i'm learning jdbc, i got an nullpointerexception when execute this program.
hi, Everyone ,i'm learning jdbc, i got an nullpointerexception when execute...; static { prop=new Properties(); try { prop.load(new FileInputStream...); } } public static Connection getConnection() { Connection con=null; try 

Struts Questions

i am Getting Some errors in Struts - Struts
i am Getting Some errors in Struts   I am Learning Struts Basics,I am Trying examples do in this Site Examples.i am getting lot of errors.Please Help me 

Development process Questions

hi
hi   i want to develop a online bit by bit examination process as part of my project in this i am stuck at how to store multiple choice questions options and correct option for the question.this is the first project i am doing 

Struts Questions

Hi i am new to J2ee Technology and struts - Struts
Hi i am new to J2ee Technology and struts  what exatly will happen when we hit the Login button? Once we enter in to the application, what will happen. How the UserID and Password validations will done. Can any one help 

RMI Questions

using spring rmi+maven but i am getting this exception
using spring rmi+maven but i am getting this exception  D:\Nexustool... is: java.rmi.UnmarshalException: error unmarshalling arguments; nested exception... by: java.rmi.UnmarshalException: error unmarshalling arguments; nested exception 

Java Beginners

getting an error when set classpath
getting an error when set classpath  Hello Everyone! i have used hssf model for reading excel sheet in my project & i have set classpath for that jar file but when i compile the program it will compile correctly but when i 

JSP Servlet Questions

please help me solve this problem when i am create database connection using servlecontext
please help me solve this problem when i am create database connection using servlecontext  hi... I have create a database connection using servletcontext . in this code when i login first time it will exceute sucessfully 

Development process Questions

Jsp error when i run this a jsp file
Jsp error when i run this a jsp file  hi I got this error when i run the jsp file in IDE and outside also please help me java.lang.NullPointerException org.apache.jsp.insertjsp.jspInit(insert_jsp.java:22 

Spring Framework Questions

Null value when i set interface object in form controller - Spring
Null value when i set interface object in form controller   Hi all, i am very new about spring and hibernate. i got null value when i set...("ohbillManager "+this.ohbillManager); } and another error i unable 

Java Beginners

Hi ..I am Sakthi.. - Java Beginners
Hi ..I am Sakthi..  can u tell me Some of the packages n Sub Directories starts with... import javax.swing.*; import javax._________;  ...;Hi friend, package javacode; import javax.swing.*; import 

Hibernate Questions

java compilation error - Hibernate
java compilation error  hi i am getting org.hibernate.exception.GenericJDBCException: Cannot open connection exception when runnig the code why this exception is coming 

WebSevices Questions

I am from .net background, I want to learn SOA.
I am from .net background, I want to learn SOA.  Hi I am from .net background, I want to learn SOA. Could it possible for me to learn SOA, I suppose SOA includes Java. I dont have knowledge of java. Please help Thanks   

Development process Questions

Getting Error - Development process
Getting Error   Hi , i am getting error while executing this code. I just want to store date in to database. Dont mistake me for repeated questions. java.sql.SQLException: [Microsoft][ODBC Microsoft Access Driver] Number 

JDBC Questions

Listener refused the connectio n with the following error
Listener refused the connectio n with the following error  Hi I am getting the following error while trying to connect oracle database. I... the connection with the following error: ORA-12505, TNS:listener does not currently know 

Java Beginners

try catch method in java
try catch method in java  try catch method in java - when and how should i use the try and catch method in Java ?   Please visit the following links: http://www.roseindia.net/help/java/t/java-try.shtml http 

Java Beginners

Not sure what I am missing ? Any ideas?
Not sure what I am missing ? Any ideas?  import java.util.*; public...(System.in); static Random rand = new Random(); // The following...) { if(str.length()==0) return false; for(int i=0;i< 

Spring Framework Questions

Getting an error :(
Getting an error :(  I implemented the same code as above.. But getting this error in console... Console Oct 5, 2012 10:18:14 AM...:SpringMVC' did not find a matching property. Oct 5, 2012 10:18:14 AM 

Java Beginners

java i/o - Java Beginners
.   Hi Friend, Please try the following code which will solve your... gets closed. when i open the program again and enter text in this case previous...java i/o  Dear sir, i wrote a program where program asks "Enter your 

Java Beginners

i am unable to identify the error in my code
i am unable to identify the error in my code  class Program { public static void main(String[] args) { BufferedReader br=new BufferedReader(new InputStreamReader(System.in)); System.out.println("enter 

Java Beginners

i am unable to identify the error in my code
i am unable to identify the error in my code  class Program { public static void main(String[] args) { BufferedReader br=new BufferedReader(new InputStreamReader(System.in)); System.out.println("enter 

Java Beginners

Error
Error  Hi. I am getting error in the following code after the line I have commented as ERROR. How to solve this. Thanks in advance. package...(); String rollno=null; try { rollno=(String)request.getAttribute 

Java Beginners

Error
Error  Hi. I am getting error in the following code after the line I have commented as ERROR. How to solve this. Thanks in advance. package...(); String rollno=null; try { rollno=(String)request.getAttribute("rollno 

Java Beginners

Error
Error  Hi. I am getting error in the following code after the line I have commented as ERROR. How to solve this. Thanks in advance. package...(); String rollno=null; try { rollno=(String)request.getAttribute 

Java Beginners

Error
Error  Hi. I am getting error in the following code after the line I have commented as ERROR. How to solve this. Thanks in advance. package...(); String rollno=null; try { rollno=(String)request.getAttribute 

EJB Questions

I got build failed when deploying enterprise application - EJB
I got build failed when deploying enterprise application  I created web application with ejb moduless and stateless session beans. However, i am getting th errros:...please help pre-init: init-private: init-userdir: init 

JSP Servlet Questions

Getting an exception - JSP-Servlet
Getting an exception   sir i am Getting following exception when.../apache/poi/poifs/filesystem/POIFSFileSystem I have used ur code import... ReadCSV(String fileName) { Vector cellVectorHolder = new Vector(); try 

Java Beginners

hi.. i hv few error. pls. - Java Beginners
hi.. i hv few error. pls.  hi sir, i have few error. can u pls help...(""); System.out.println("\t "+title[i]+"\t"+author[i]+"\t\t"+publisher[i]+"\t\t"+quantity[i]+"\t\t"+price[i]); break 

XML Questions

hi
online multiple choice examination  hi i am developing online multiple choice examination for that i want to store questions,four options,correct... visit the following link: http://www.roseindia.net/answers/viewqa/JSP 

JDBC Questions

get UnsatisfiedLinkError when I try to use my JDBC driver.
get UnsatisfiedLinkError when I try to use my JDBC driver.  Why do I get UnsatisfiedLinkError when I try to use my JDBC driver 

Java Beginners

hi!
hi!  how can i write aprogram in java by using scanner when asking... to to enter, like(int,double,float,String,....) thanx for answering....   Hi, Try this: import java.util.*; class ScannerExample { public static void 

Java Beginners

I am new to programming and I am not sure what to do next? Any ideas?
I am new to programming and I am not sure what to do next? Any ideas? ...); static Random rand = new Random(); // The following routine will determin...()==0) return false; for(int i=0;i<=str.length();i 

JDBC Questions

HI!!!!!!!!!!!!!!!!!!!!!
;Hi Friend, Try this: import java.awt.*; import java.sql.*; import javax.swing....HI!!!!!!!!!!!!!!!!!!!!!  import java.awt.*; import java.sql....=text1.getText(); String t=text.getText(); String t2 

Java Beginners

hi.......
hi.......  import java.awt.; import java.sql.*; import javax.swing....){ String t1=text1.getText(); String t=text.getText(); String t2=text2.getText...) { try{ Class.forName("com.mysql.jdbc.Driver"); Connection con 

PHP Questions

getting error in your login form code
getting error in your login form code  i tried your code for login form but i am getting an error.the error is undefined index userid...   hi friend, your form's input must have following : <input type 

JSP Servlet Questions

hi..
hi..   I want upload the image using jsp. When i browse the file then pass that file to another jsp it was going on perfect. But when i read...); for(int i=0;i<arr.length-1;i++) { newstr=newstr 

JSP Servlet Questions

hi..
hi..   I want upload the image using jsp. When i browse the file then pass that file to another jsp it was going on perfect. But when i read...); for(int i=0;i<arr.length-1;i++) { newstr=newstr 

JSP Servlet Questions

hi..
hi..   I want upload the image using jsp. When i browse the file then pass that file to another jsp it was going on perfect. But when i read...); for(int i=0;i<arr.length-1;i++) { newstr=newstr 

JSP Servlet Questions

hi..
hi..   I want upload the image using jsp. When i browse the file then pass that file to another jsp it was going on perfect. But when i read...); for(int i=0;i<arr.length-1;i++) { newstr=newstr 

JSP Servlet Questions

hi..
hi..   I want upload the image using jsp. When i browse the file then pass that file to another jsp it was going on perfect. But when i read...); for(int i=0;i<arr.length-1;i++) { newstr=newstr 

JSP Servlet Questions

hi..
hi..   I want upload the image using jsp. When i browse the file then pass that file to another jsp it was going on perfect. But when i read...); for(int i=0;i<arr.length-1;i++) { newstr=newstr 

JSP Servlet Questions

hi..
hi..   I want upload the image using jsp. When i browse the file then pass that file to another jsp it was going on perfect. But when i read...); for(int i=0;i<arr.length-1;i++) { newstr=newstr 

Development process Questions

Getting connect error in Jmeter - Development process
Getting connect error in Jmeter  Hi, Am trying to run a simple application in Jakarta Jmeter using HTTP request sampler. I am getting the below error. Please help me in viewing the results. Pl specify if there is any possible 

JavaScript Questions

autocomplete(): Spring mvc with jquery: I am not getting correct value in the text filed. Please help me
autocomplete(): Spring mvc with jquery: I am not getting correct value... related birds whenever we give input in the text field. But i am getting the wrong... bird names , but whenever i selected any bird in the text filed the am getting 

Hibernate Questions

Hibernate - Hibernate
Hibernate  when I run Hibernate Code Generation wizard in eclipse I'm getting the following error. I added ojdbc14.jar to my build path. Still I'm getting this error. please let me know, how to resolve 

Hibernate Questions

hibernate
hibernate   i am using hibernate3.2.5 and oracle9i. First i set classpath to ojdbc14.jar and all the hibernate jar files to path env variable.After that when i try to execute the program i got an error "unknown oracle major 

Hibernate Questions

Hibernate error - Hibernate
Hibernate error  I had run hibernate first example but it an error appeared. Error is java.lang.NullPointerException.  Hi Friend... want more examples of Hibernate please visit the following link. http 

Hibernate Questions

Hibernate
not be resolved. How can i rectify that error?   Hi, The error comes when... of Hibernate. I followed all th steps as given in the tutorial, but a build error... the example from Hibernate Getting Started Tutorial. Please follow the steps 

JSP Servlet Questions

page is not getting loaded when refreshing???
page is not getting loaded when refreshing???  I am loading an image.... It will get all details of image section from database. I am getting header section always but page is not getting loaded after the header section when I 

Hibernate Questions

Hibernate error in eclipse
Hibernate error in eclipse   Hi... while running my application i got... code........ I will try to short out your problem... by java.lang.NullPointerException))   NullPointerException is an exception that occurs when you 

Hibernate Questions

jsp-Hibernate Error - Hibernate
jsp-Hibernate Error  hi, my problem is, I designed an Interface where i am tring to listing the all rows of a table using Iterator and putted a link for deleting each row. I am deleteing row using row id of that record.it delete 

Hibernate Questions

I am having problem with configuring Hibernate sessionfactory. Please Help
I am having problem with configuring Hibernate sessionfactory. Please Help  Sir, I am having problem with configuring Hibernate sessionfactory.. I was using the old version of Hibernate before now I am using Hibernate

Java Beginners

hi - Java Beginners
hi  hi sir, i am entering the values to jtable at run time...) to database when i am click on submit button .submit button is placed in below the table ,plz provide the solution for me .  Hi Friend, Try the following 

XML Questions

Error-
Error-   Hello, I would like to know about XSD file. I try to print XML file but I am getting error SAXException-- says Content is not allowed in prolog. Please help me 

Hibernate Questions

java compilation error - Hibernate
java compilation error  hi, i have made an registration page whosevalues should be inserted into database. i have used hibernate and eclipse it is working fine. but when i make a war file and deploy it using ant and then run 

JSP Servlet Questions

Getting an exception - JSP-Servlet
Getting an exception  sir i changed to that ie InputStream myInput1...(myInput1); but when i click on a browse button and attached a file... of showing a what i have attached(file), in server console i m gtting a following 

Hibernate Questions

Hibernate delete a row error - Hibernate
Hibernate delete a row error  Hello, I been try with the hibernate delete example (http://www.roseindia.net/hibernate/hibernate-delete.shtml) but keep receiving exceptions, not sure if I did some thing wrong, please help 

Security Questions

Will i be able to get the content of a webpage in a word document (Note:i don t have access to the source code)through java code?
am getting output to this code as html tags.... But what i want is in a word document to the webpage(for which i don t have access to source code...Will i be able to get the content of a webpage in a word document (Note:i don t 

Java Beginners

When i click on Monitor Tomcat, it shows
' and when i Open your Browser (Google Chrome) and type the following URL : http...When i click on Monitor Tomcat, it shows   To run servlet i have seen... installed java 7 and tomcat 7, when i click on Monitor Tomcat it shows 

Java Beginners

When i click on Monitor Tomcat, it shows
' and when i Open your Browser (Google Chrome) and type the following URL : http...When i click on Monitor Tomcat, it shows   To run servlet i have seen... installed java 7 and tomcat 7, when i click on Monitor Tomcat it shows 

Java Beginners

i/o
i/o  java program using inputstream and outputstream   Hi Friend, Try the following code: import java.io.*; class InputStreamAndOutputStream { public static void main(String[] args)throws Exception 

Java Beginners

i/o
i/o  java program using inputstream and outputstream   Hi Friend, Try the following code: import java.io.*; class InputStreamAndOutputStream { public static void main(String[] args)throws 

Java Beginners

i/o
i/o  java program using inputstream and outputstream   Hi Friend, Try the following code: import java.io.*; class InputStreamAndOutputStream { public static void main(String[] args)throws Exception 

Java Beginners

i/o
i/o  java program using inputstream and outputstream   Hi Friend, Try the following code: import java.io.*; class InputStreamAndOutputStream { public static void main(String[] args)throws Exception 

Java Beginners

can i know the error in this code... am unable to run this code
can i know the error in this code... am unable to run this code  ...}; int n=arr.lenght; System.out.println("length of array:"+n); for(int i=0;i System.out.println(arr[i]); } }   You have used incorrect symbol in your 

JavaMail Questions

problem getting password - JavaMail
problem getting password  hi i am trying to get password but igot following error Error sending mail:javax.mail.MessagingException: Could not connect to SMTP host: 192.168.10.14, port: 25;nested exception 

Hibernate Questions

hibernate firstexample - Hibernate
hibernate firstexample  Hi all. i m new with hibernate,when i m trying to run my first application i m getting following exception. Error reading resource: Employee.hbm.xml give me the solution. Thank you 

Applet Questions

I am new to java applets. When i run this code on applet viewer status is displayed that applet not initialized
I am new to java applets. When i run this code on applet viewer status is displayed that applet not initialized  import java.awt.*; import java.awt.event.*; import java.applet.*; public class Textfields extends Applet implements 

Java Beginners

Am i convetrting the code right ? - Java Beginners
Am i convetrting the code right ?  C# private void button... (IOException ex) { }// i also tried the code below// try... && cpi.getName().compareTo("COM1") == 0) { try { CommPort port = cpi.open 

Hibernate Tutorial Example

Hibernate Getting Started
with the fast track Hibernate Getting Started tutorial. What is required? I am... Hibernate Getting Started       Hibernate Getting Started In this Hibernate Getting 

Hibernate Questions

error in hibernate example
error in hibernate example  i am getting error in this.... log4j:WARN No appenders could be found for logger (org.hibernate.cfg.Environment). log4j:WARN Please initialize the log4j system properly. Resource: Contact.hbm.xml 

Java Beginners

try catch
try catch  why following code gives compile time error.please reply. class ThreadDemo1 extends Thread { public void run() { for(int i=1;i<=3;i++) { System.out.println(i); try 

JSP Servlet Questions

jsp-Hibernate Error - JSP-Servlet
jsp-Hibernate Error  hi, my problem is, I designed an Interface where i am tring to listing the all rows of a table using Iterator and putted a link for deleting each row. I am deleteing row using row id of that record.it delete 

JDBC Questions

hi
hi   I have connected mysql with jsp in linux and i have used JDBC connectivity but when i run the program, its not working the program is displaying 

Struts Questions

Hi
Hi  Hi All, I am new to roseindia. I want to learn struts. I do not know anything in struts. What exactly is struts and where do we use it. Please help me. Thanks in advance. Regards, Deepak 

Java Beginners

Hi.... - Java Beginners
Hi....  Hi Friends when i compile jsp file then got the error "code to large for try statement" I am inserted 177 data please give me solution and let me know what is the error its very urgent  Hi Ragini 

Advertisements Advertisements
 

 

 

DMCA.com