There is a way :) not the best but can solve your problem.
simply use "sqlite" . sqlite doesn't need a server.
so first you have to save sql of your database,
and with an sqlite-browser create a database and import your sql.
your database is saved as a single file. and you can change localhost by relative path to database.
here is some examples :
Class.forName("org.sqlite.JDBC").newInstance(); c
stat = con.createStatement();
stat.executeUpdate("create table if not exists user(Name varchar(50),Email varchar(50));");
data = FXCollections.observableArrayList();
ResultSet rs = con.createStatement().executeQuery("select * from user");
while (rs.next()) {
data.add(new UserData(rs.getString("Name"), rs.getString("Email")));
}
source : http://www.javafxapps.in/tutorial/Persisting-TableView-datas-in-Database.html