mysql - How can I upload a text file the best into a database as I want it to? (in C) -
at first need do: need input text file database.
that not hard, text file gave me kinda strange.
i modified looks in database, don't want change every file hand time. thought why not splitting text file separate text files or in arrays , upload bit o should belong in database.
but after searching long time in internet couldn't find on how (or maybe found didn't :p).
so question is:
what best way split text file can upload chunks in database? best split in lot of text files , upload every text file or in array , upload arrays database.
the text file self divided text , numbers , want numbers uploaded database , text in column names of database.
here example of such text file (normally without spaces between it):
usindsvorigecall = -1.0000;0.0000;0.0000;0.0000; weersindsvorigecall = -1.0000;10.1000;7.5200;10.4000; 0.0000;10.4000;7.6740;10.7000; klimaatsindsvorigecall = -1.0000;7.4000;8.8000;6.6000;-99.0000;-99.0000;-99.0000;-99.0000;-99.0000;-99.0000; 0.0000;7.4000;8.9000;6.7000;-99.0000;-99.0000;-99.0000;-99.0000;-99.0000;-99.0000; klimaatcompusettings = 8.0000 21.0000 0.0000 0.0000 -4.0000 2.0000 5.0000 0.0000 4.0000 30.0000 0.4000 -99.0000 -99.0000 -99.0000 -99.0000 -99.0000 -99.0000 -99.0000 -99.0000 -99.0000
if there other option open , try out.
this output have:http://nl.tinypic.com/view.php?pic=30ue5pd&s=8 (this self edited text file)
use blob type instead of text, allows write whatever want.
but don't approve fact of writing files in db, it's not made that: these relational databases, not garbage.
you should write files directly on filesystem, in specific folder, , use database list paths , store data used research queries.
Comments
Post a Comment