i have a database which contains an arabic tables , i can read it from Netbeans good so i can see and write arabic chars to the tables but i want to read and write using eclipse, i tried like this:
String unicode1 = "?useUnicode=yes&characterEncoding=UTF-8";
Class.forName("com.mysql.jdbc.Driver");
Connection con = (Connection) DriverManager.getConnection(
"jdbc:mysql://localhost:3306/searchengine"+unicode1, Username, Password);
PreparedStatement statement = (PreparedStatement) con
.prepareStatement("select * from invertedindex");
ResultSet results = statement.executeQuery();
while (results.next()) {
System.out.println(results.getString(1));
}
but i still see the arabic chars like question marks , what am i doing wrong
**Note:** the tables is support arabic chars because i can read and write to the same table using Netbeans
EDIT
i tried System.out.println("يييي"); but i got questions marks , it seems like i have had arabic chars but eclipse doesn’t display it
try
select convert(name using UTF8) from invertedIndex