title: Passing file name with spaces to SPOOL command using SQL Plus gives SP2-0768 Illegral SPOOL command error
body: <p>My sql file contains</p>
  
  <pre><code>`SPOOL &amp;1;
  //sql code to execute
  SPOOL OFF;`
  </code></pre>
  
  <p>The sql file is executed using SQL Plus and SQL Plus is being called from C# code using Process.Start... Code snipped</p>
  
  <pre><code>`var m_StartInfo = new ProcessStartInfo();
  m_StartInfo.FileName = "SQLPLUS.EXE";
  m_StartInfo.CreateNoWindow = true;
  m_StartInfo.UseShellExecute = false;
  m_StartInfo.Arguments = String.Format("{0}\"{1}\" \"{2}\"", connectionString, sqlfile, sqlLogFileName);
  m_Process = Process.Start(m_StartInfo);
  Other code.....`
  </code></pre>
  
  <p>It works fine and the sqlplus log is created fine at sqlLogFileName location. However if the sqlLogFileName has spaces in between (say like "C:\My Application\log.txt"), then the log file is not created, instead gives the error SP2-0768 Illegal SPOOL command on SQL Plus window</p>
  
  <p>Any suggestion how to resolve this? I am using Oracle 11GR2</p>