How to import data from .CSV file using a Report
dilla
Member Posts: 31
Hi All,
I'm using Navision 3.70 and I have a requirement to import data from a .csv file in to General Journal. The.CSV file includes the fields Posting Date, Doc. No., G/L Acc type, Acc No. and Amount.
I created a table to define the format of the .CSV file because the order of fields in .CSV file are different from one file to other.
By using a Report,now I need to import data from .csv file in to General Journal.
Can any of you please help me, how can I create a Report in order to import the data.
Thanks in advance.
With Regards,
Dilla
I'm using Navision 3.70 and I have a requirement to import data from a .csv file in to General Journal. The.CSV file includes the fields Posting Date, Doc. No., G/L Acc type, Acc No. and Amount.
I created a table to define the format of the .CSV file because the order of fields in .CSV file are different from one file to other.
By using a Report,now I need to import data from .csv file in to General Journal.
Can any of you please help me, how can I create a Report in order to import the data.
Thanks in advance.
With Regards,
Dilla
0
Comments
-
Hi,
Can I ask why You want to use Report for this import (instead of Dataport)?
Create One dataport per one file format is not good solution?0 -
I agree. Using a report doesn't make any sense. You can do the same thing with a Dataport (even the different column order).0
-
Hi All,
Thanks to all of you for your valuable inputs.
As per the requirement I should use only Report, I created a new Report and by using Excel Buffer Table some how I mangaged to import the data from .CSV file in to General Journal. .CSV file contains data for 21 fields for each record in a single shell seperated by ";".
Two problems I have now are:
1. If I have 2 records in .CSV file, first record is getting imported first and then it is over written by the second record.
2. If .CSV file does not contain data for all 21 fileds, emty fields are seperated by a ";" and I'm receiving an error message. How can I handle the empty fields.
Kindly revert for further information0 -
In the properties of the report (go to the lowest, blank line in the dataport and press Shift+F4) set FieldStartDelimiter <None> FieldEndDelimiter <None> and FieldSeperator ; (write it as exactly seen)Cem Karaer @ Pargesoft
Dynamics NAV Developer since 20050 -
dilla wrote:As per the requirement I should use only Report
The requirement is to get the data into NAV and use a method that still works in NAV 2009 from what I understand. The requirement is NOT to use a report to get the data. You could just as easily use a codeunit or a dataport. Functionality is a requirement; how you build that functionality usually is not.
Why are you using the Excel Buffer table? You're writing dataport functionality from scratch so you should have File Streams and be checking for delimiters in your code.0
Categories
- All Categories
- 73 General
- 73 Announcements
- 66.7K Microsoft Dynamics NAV
- 18.8K NAV Three Tier
- 38.4K NAV/Navision Classic Client
- 3.6K Navision Attain
- 2.4K Navision Financials
- 116 Navision DOS
- 851 Navision e-Commerce
- 1K NAV Tips & Tricks
- 772 NAV Dutch speaking only
- 617 NAV Courses, Exams & Certification
- 2K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 333 Dynamics CRM
- 111 Dynamics GP
- 10 Dynamics SL
- 1.5K Other
- 991 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 35 Design Patterns (General & Best Practices)
- 1 Architectural Patterns
- 10 Design Patterns
- 5 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1.1K General Chat
- 1.6K Website
- 83 Testing
- 1.2K Download section
- 23 How Tos section
- 252 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions

