title: Read csv file using fscanf in C
body: <p>I have to read a csv file using <code>fscanf</code> function (I cant use any other function like <code>strtok_s</code> to parse the line) and im having the following problem.</p>
  
  <p>Here is the code:</p>
  
  <pre><code>fp1 = fopen (argv [1],"r");
  
  var = fscanf (fp1,"%d,%d,%[^,]s,%[^,]s",&amp;aux.points,%aux.titles,aux.name,aux.nation);
  </code></pre>
  
  <p>I'm trying to print each parameter in the screen. There is no problem with the integers and even with the first string (name) but nothing is stored in the next string (nation).</p>
  
  <p>I assume that the first <code>%[^,]s</code> is stopping the execution of the whole <code>fscanf</code> function so the next string is never read. Any idea? I have tried everything but this is just not working.</p>