title: MySQLDump error code 6 when running MySQLDump via Java
body: <p>This is my code:</p>
  
  <pre><code>String cmd = "\"C:\\Program Files\\MySQL\\MySQL Server 5.6\\bin\\mysqldump\" -h www.anonymizeddomain.com -u root -proot anon_thisdb &gt; anon_thisdb.sql\"";
              Process proc = Runtime.getRuntime().exec(cmd);
              Print(cmd);
  
              InputStream stdin = proc.getInputStream();
              InputStreamReader isr = new InputStreamReader(stdin);
              BufferedReader br = new BufferedReader(isr);
  
              String line = null;
              System.out.println("&lt;OUTPUT&gt;");
  
              while ( (line = br.readLine()) != null)
                   System.out.println(line);
  
              System.out.println("&lt;/OUTPUT&gt;");
              int exitVal = proc.waitFor();
              System.out.println("Process exitValue: " + exitVal);
  </code></pre>
  
  <p>It exits with error code 6 and idk why. The output i get from the console is this:</p>
  
  <pre><code>&lt;OUTPUT&gt;
  -- MySQL dump 10.13  Distrib 5.6.13, for Win64 (x86_64)
  --
  -- Host: www.anonymizeddomain.com    Database: anon_thisdb
  -- ------------------------------------------------------
  -- Server version   5.5.32-cll-lve
  
  /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
  /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
  /*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
  /*!40101 SET NAMES utf8 */;
  /*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
  /*!40103 SET TIME_ZONE='+00:00' */;
  /*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
  /*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
  /*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
  /*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
  &lt;/OUTPUT&gt;
  Process exitValue: 6
  </code></pre>
  
  <p>What the popsicle slices am i doing wrong?!</p>
  
  <p>I put the escape characters in the string so i wouldn't get errors, but yet i got errors :\ what the fudge? :\</p>