Win a copy of Java 9 Revealed this week in the Features new in Java 9 forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

unsupported encoding  RSS feed

 
aime ahmad
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hello..
i'm developing a program that allows users to find tutor and search by subject. i need help with the search section. i'm using a drop down list that displays the subject. but an internal server error occured.
"org.apache.jasper.JasperException: Unsupported encoding:"
no encoding specified.

this is a part of my program:

<select name="selectsubject" size="1">
<option value="0">--Select--</option>
<%! String sub_code,sub_name;%>
<%
Connection conn = null;
try{
Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
conn = DriverManager.getConnection("jdbc dbc:tutorfinder","","");
Statement stmt = conn.createStatement();
ResultSet rs = stmt.executeQuery("Select * from subject order by subject_code");

while (rs.next())
{
sub_code=rs.getString("subject_code");
sub_name=rs.getString("subject_name");
%>
<option value="<%=sub_code%>"><%=sub_name%></option>
<%
}
rs.close();
}
catch...
}
}
%>
</select>

thx in advance for all help.
 
Adeel Ansari
Ranch Hand
Posts: 2874
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by saif uddin:
tell me what datatype u specify of subject_code in ur database its an int, or double or char


Sorry mate, its not about the datatypes. And as far as I know we dont have double, or int kind of datatypes in databases. I guess you listed out java datatypes.

O.P. you can try this.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!