memread/write is more powerfull because you can make structures.
I had a look at your code, you have
memget(0, 9999, 60); ` this will make a block with 9999 times 60 bytes
char s[99];
...
memwrite(0, i, &s);
The size of the parts in the block is 60 bytes but you are using a string of 99 bytes. So i hope you know what you are doing. Those functions are meant for things like this:
int a[10], b;
real c[6];
char s[100];
In total this 'structure' is 10 * 4 + 4 + 6 * 8 + 100 = 500 bytes, so you do memget(0, 9999, 500) and now you can do
memread(0, i, &a);
because the structure starts with int a.
Take a good look at this, i'\m not sure you understand these functions correct.
If you do maybe you can do something else in stead of just using one string with strset(s, "%20s,%d,%d,%d,%d,%.2f,%.2f,0",jdx,aa,aaa,a,graf,p1,p2);
This is also why i can only help to a certain point, it is your work

.
I will make a memsearch()