<html>
  <head>
    <meta content="text/html; charset=windows-1252"
      http-equiv="Content-Type">
  </head>
  <body text="#000000" bgcolor="#FFFFFF">
    <div class="moz-cite-prefix">Hello Philipp,<br>
      <br>
      Le 14/10/2016 00:08, Philipp Mühlmann a écrit :<br>
    </div>
    <blockquote
cite="mid:CACf7ODv4XbywHn_JzvKhMpS=pfFU2X8kmxu+trsSNJNVFzhoXQ@mail.gmail.com"
      type="cite">
      <div dir="ltr">
        <div>
          <div>
            <div>Dear Scilab users,<br>
              <br>
            </div>
            having a data file (*.cvs) containg following format:<br>
            <br>
            <br>
          </div>
          HEADER-Line<br>
        </div>
        dd.mm.yyyy, HH:MM:<a moz-do-not-send="true" href="http://SS.MS">SS.MS</a>,
        value01, value02<br>
        <br clear="all">
        <div>
          <div>
            <div>
              <div>
                <div>dd = day<br>
                </div>
                <div>mm = month<br>
                </div>
                <div>yyyy = year<br>
                  <br>
                </div>
                <div>HH = hour<br>
                </div>
                <div>MM = minute<br>
                </div>
                <div>SS = second<br>
                </div>
                <div>Ms = milli second<br>
                  <br>
                </div>
                <div>ValueXY = numerical value<br>
                </div>
                <div><br>
                </div>
                <div>Is it possible to use cvsRead in such a way to
                  define the separator beeing ',' and ':' at the same
                  time?<br>
                </div>
              </div>
            </div>
          </div>
        </div>
      </div>
    </blockquote>
    .<br>
    Yes and no: Yes because each character of the "separator" option is
    (sometimes) considered as a<br>
    separator. And no, because it sometimes fails.<br>
    I was designing an example to add to the csvRead() page, when a
    found this bug:<br>
    <br>
    <tt>--> mputl("12.08.2016, 13:54:18.45, 3.145, 548.4",
      TMPDIR+"/test.csv")</tt><tt><br>
      <br>
    </tt><tt>--> r = "''"+csvRead("test.csv","8.",[],"string")+"''"</tt><tt><br>
    </tt><tt> r  = </tt><tt><br>
    </tt><tt>!'12'  '0'  '2016, 13:54:1'  '45, 3'  '145, 54'  '4'  !</tt><tt><br>
    </tt><tt>--> // it works: both "8" and "." are <b>separately</b>
      considered as separators<br>
      <br>
      --> // now trying with "," and ":":</tt><br>
    <tt>--> r = "''"+csvRead("test.csv",",:", [], "string")+"''"</tt><tt><br>
    </tt><tt>--> r = "''"+csvRead("test.csv",",:", [], "string")+"''"<br>
       r  = <br>
       '12.08.2016, 13:54:18.45, 3.145, 548.4'<br>
      --> // The row is kept as is: no splitting!<br>
      --> // We could expect: [</tt><tt><tt>'12.08.2016' ' 13' '54' '18.45'
        ' 3.145' ' 548.4']<br>
        --> //  (with leading spaces, since they are not set as
        separators)<br>
        --> </tt></tt><br>
    <br>
    There are already 10 pending reported bugs about csvRead(). One
    more.<br>
    <br>
    Samuel<br>
    <br>
  </body>
</html>