في الكود اخطاء ماادري كيف اصححها بليز ساعدوني هذا مشروع ومطلوب اسلمه هذا الاسبوع وانا متوهقه
String text;
String [] text1,text2;
System.out.println("plz enter your statement");
Scanner input=new Scanner(System.in);
text=input.nextLine();
text1=text.split(" ");
int w=text1.length;
try{
Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
Connection c = DriverManager.getConnection("jdbc:odbc:oracle", "system", "123456");
Statement s = c.createStatement();
for(int n=0;n<w;++n)
{
ResultSet results = s.executeQuery(
"select path from word where name==text1[n] ");
String location =results.getString();//هنا الخطأ
ImageIcon icon = new ImageIcon(location);
JLabel lPhoto = new JLabel(icon);
setLayout(new GridLayout(1, 1));//وايضا هنا الخطأ
add(lPhoto);
if(location==null)//if the word is not found in [url="""]DataBase[/url]
{
//String t= text1.getText();
int j=text1[n].length();
String result="";
int i =0;
for(i=0; i<j;i++)
{
result += text1[n].substring(i,i+1)+" \n ";
}
jLabel2.setText(result);}}
}
catch( Exception a ) {
}