code: public static PreparedStatement createWayTable(Connection connection, String wayTableName, boolean isH2) throws SQLException {
          try (Statement stmt = connection.createStatement()) {
              StringBuilder sb = new StringBuilder("CREATE TABLE ");
              sb.append(wayTableName);
              sb.append("(ID_WAY BIGINT PRIMARY KEY, USER_NAME VARCHAR, UID BIGINT, VISIBLE BOOLEAN, VERSION INTEGER, CHANGESET INTEGER, LAST_UPDATE TIMESTAMP, NAME VARCHAR);");
              stmt.execute(sb.toString());
          }
          return connection.prepareStatement("INSERT INTO " + wayTableName + " VALUES (?,?,?,?,?,?,?,?);");
      }
docs: Create the ways table that will be used to import OSM ways
  Example :
  <way id="26659127" user="Masch" uid="55988" visible="true" version="5"
  changeset="4142606" timestamp="2010-03-16T11:47:08Z">
  
  @param connection
  @param wayTableName
  @return
  @throws SQLException