Re: beginners question : how to import textfiles into databases
Posted in 1996
Hi Jeroen,
You can't use the dbimport command. It can only be used with the complementary
dbexport command [ Gurus, am I right ??? ].
To upload such a text file, use the dbaccess utility and the "load from" sql
command as follows. This has been tested on Informix 7.10.UC1 on SCO ONS.
load from "datafile" delimiter "^I" insert into tablename
The delimiter keyword is necessary and you should type the tab character
there. [ It is Ctrl-I for me and is easily done in vi ]
Also, if you could provide the Informix and your OS version, it would be easy
for the ng to help you out.
Cheers,
Ravi .....
-------------------------------------------------------------------------------------
On 6 Aug 96 , jeroen clarysse <jeroen@hypervision.be> wrote
} Sorry for this really stupid question, but we haven't got the manuals yet
} (the machine is only on trial. Once the decision to buy it has been made
} (which will surely happen, only I don't know when (I'm the one working
} with it, so I have no say in purchase decisions ;-)) we'll get the paper
} truck... until then this newsgroup is my only resort
}
} Here goes : how can I, using the dbimport tool get some tab-delimited
} text-file data into my database ? (the file comes over from PC access
} database)
}
} all I get is
}
} $ dbimport
} Usage:
} dbimport <database> [-X] [-c] [-q] [-d <dbspace>]
} [-l [{ buffered | <log-file> }] [-ansi]]
} [{ -i <dir> | -t <tapedev> [ -b <blksz> -s <tapesz> ] [-f <script-file>] }]
} NOTE: <log-file> must be a complete path
} arguments to dbimport are order independent
}
} and when trying harder :
}
}
} $ dbimport customer
} Cannot open sql script file
}
}
} anyone a suggestion for me ?
}
} thanks
} jeroen
}
} jeroen@hypervision.be
} \