![]() | ![]() Products ![]() ![]() ![]() ![]() |
Home » Technical Support » ElevateDB Technical Support » Support Forums » ElevateDB SQL » View Thread |
Messages 1 to 7 of 7 total |
![]() |
Mon, Oct 15 2018 9:14 AM | Permanent Link |
Iztok Lajovic (1) | I want to import data from text file with different field structure as my ElevateDB table, Text file has headers in first columns, and it has more fields that my table and its fields order is different regarding fields order in my table. How can I map fields on both tables to get appropriate data in my table? What is philosophy of IMPORT statement regarding this problem?
Regards Iztok Lajovic |
Mon, Oct 15 2018 10:18 AM | Permanent Link |
Roy Lambert NLH Associates ![]() | 1
When you say text file what is its structure: ie fixed length, csv or other delimited, xml all of which are text files. If its fixed length I'd guess you have a problem, if its delimied or xml then the appropriate bit from the OLH is << For delimited text files, the USE HEADERS clause determines whether ElevateDB interprets the first line in the import file as a list of column names that are included in the import file. If any column specified in this line is not a valid column for the table, then it is simply ignored. For XML text files, the USE HEADERS clause determines whether ElevateDB looks for the following tags in the import file to control which columns are imported: >> If it doesn't work then you may need a 3rd party tool - I'd recommend scalabium's import wizard Roy Lambert |
Mon, Oct 15 2018 4:35 PM | Permanent Link |
Iztok Lajovic (1) | Roy, thank you.
Text file is csv delimited. IMPORT statement has possibility to list fields to determine fields and their order. Regarding the fact that there is no possibility of mapping I presumed that field names must be the text file's field names. Unfortunately this does not work. For example, in text file there are seven fields and three fields in ma table. In IMPORT I have same three fields listed and these fields correspond to names of three fields of seven in text file. After importing only one field was recognized and the other two had assigned null value. Scalabium does not support ElevateDB recently. Thank you for hint. Regards Iztok Lajovic |
Tue, Oct 16 2018 2:55 AM | Permanent Link |
Roy Lambert NLH Associates ![]() | 1
>IMPORT statement has possibility to list fields to determine fields and their order. Regarding the fact that there is no possibility of mapping I presumed that field names must be the text file's field names. > >Unfortunately this does not work. For example, in text file there are seven fields and three fields in ma table. In IMPORT I have same three fields listed and these fields correspond to names of three fields of seven in text file. After importing only one field was recognized and the other two had assigned null value. Can you post a sample of the csv file and the table's structure and I'll have a play here >Scalabium does not support ElevateDB recently. Thank you for hint. I don't know where you get that from. His website says <<SMImport suite 2.92 is a set of components that can import data into TDataSet (any descendant) from a variety of different file formats as described in following table:>> Just because he doesn't have a direct parser for ElevateDB doesn't mean it doesn't work. It certainly does in my apps. Roy |
Tue, Oct 16 2018 7:17 AM | Permanent Link |
Iztok Lajovic (1) | Roy,
attached are three files: table definition, import txt file and import statement. In import statement I use list of field names of import txt file in order of appropriate fields in my table. I must have overlooked something because this import does not work properly. Thank you Iztok Attachments: temp1.zip |
Tue, Oct 16 2018 7:58 AM | Permanent Link |
Roy Lambert NLH Associates ![]() | 1
Only one field name matches the column headings: koda. The rest do not which is why nothing is imported. Tim does not have a facility to map something like ident -> iden. You'll have to but an import utility. Again I recommend Scalabium - inexpensive, good and well supported. Alternatively you can edit the source file and alter the headers prior to import. Roy Lambert |
Tue, Oct 16 2018 9:33 AM | Permanent Link |
Iztok Lajovic (1) | Roy, thank you
Iztok Lajovic |
This web page was last updated on Wednesday, August 14, 2024 at 07:31 PM | Privacy Policy![]() © 2024 Elevate Software, Inc. All Rights Reserved Questions or comments ? ![]() |