To me it sounds like you'd want to read a line as a string using fgets and then scan this formatted string with sscanf. Something like this?
#include <stdio.h>
struct record
{
int a, b;
double c, d, e;
};
int main(void)
{
const char filename[] = "file.csv";
FILE *file = fopen(filename, "r");
if ( file != NULL )
{
char line [ 80 ];
struct record record [ 750 ];
size_t count, i = 0;
while ( i < sizeof record / sizeof *record )
{
if ( fgets(line, sizeof line, file) == NULL )
{
break;
}
if ( sscanf(line, "%d,%d,%lf,%lf,%lf", &record[i].a, &record[i].b,
&record[i].c, &record[i].d, &record[i].e) == 5 )
{
++i;
}
}
fclose(file);
for ( count = i, i = 0; i < count; ++i )
{
printf("record[%lu]: a = %d, b = %d, c = %g, d = %g, e = %g\n",
(long unsigned)i, record[i].a, record[i].b, record[i].c,
record[i].d, record[i].e);
}
}
else
{
perror(filename);
}
return 0;
}
/* file.csv
301,36,0.285,2.88,15.000
302,88,0.247,2.88,75.500
*/
/* my output
record[0]: a = 301, b = 36, c = 0.285, d = 2.88, e = 15
record[1]: a = 302, b = 88, c = 0.247, d = 2.88, e = 75.5
*/