Import Action not working

If you think that something doesn't work in Aware IM post your message here
Post Reply
kklosson
Posts: 1665
Joined: Sun Nov 23, 2008 3:19 pm
Location: Virginia

Import Action not working

Post by kklosson »

I have an import function for end users that employs the IMPORT action:

IMPORT [object] FROM [file] WITH VALIDATION

This has worked fine for years and I have not altered anything since instituting it. It gets used but I am unsure how often but I recently got a report that it was claiming the header column did not match the attribute name:

Screenshot_8.png
Screenshot_8.png (11.72 KiB) Viewed 35824 times

I checked and it's fine. When I moved a different column to the first column, I got the same error on that column. This validates it is reading the correct file.

Here's the file...
Screenshot_9.png
Screenshot_9.png (4.33 KiB) Viewed 35824 times
No starting or trailing spaces. It's perfect.

Can anyone validate it's working for you?
Can support confirm this action is working on your own test applications?
V8.8
MySQL, AWS EC2, S3
PDFtk Toolkit
Heavy on AwareIM Reports
PointsWell
Posts: 1476
Joined: Tue Jan 24, 2017 5:51 am
Location: 'Stralya

Re: Import Action not working

Post by PointsWell »

What does the CSV file look like when opened in a text editor? Excel hides many sins.
kklosson
Posts: 1665
Joined: Sun Nov 23, 2008 3:19 pm
Location: Virginia

Re: Import Action not working (RESOLVED]

Post by kklosson »

Good on you!
You got me thinking. The doc looked fine in a text editor. However, I saved it as TXT using ANSI (usually cleans our the boogers). renamed it to .csv. Then it worked.

Good job and many thanks!
V8.8
MySQL, AWS EC2, S3
PDFtk Toolkit
Heavy on AwareIM Reports
PointsWell
Posts: 1476
Joined: Tue Jan 24, 2017 5:51 am
Location: 'Stralya

Re: Import Action not working

Post by PointsWell »

If that is the case then check the text encoding of the database and the csv file (and if it was extracted from a database then the encoding of the source database)
kklosson
Posts: 1665
Joined: Sun Nov 23, 2008 3:19 pm
Location: Virginia

Re: Import Action not working

Post by kklosson »

This file is from a customer who got it from some other unknown source. I'm just happy to close the case with a lesson learned.
V8.8
MySQL, AWS EC2, S3
PDFtk Toolkit
Heavy on AwareIM Reports
Post Reply