Illegal date when importing txt file

For notifying us of what you believe are bugs or errors in EViews.
Please ensure your copy of EViews is up-to-date before posting.

Moderators: EViews Gareth, EViews Moderator

patrice
Posts: 18
Joined: Tue Oct 12, 2010 2:10 am

Illegal date when importing txt file

Postby patrice » Tue Feb 11, 2025 8:56 am

Hello,

When trying to import this txt file, I have this error message: Illegal date ?.

Here my code:

Code: Select all

wfcreate m 2010 2025 import(type=txt, resize) "c:\temp\eviews_issue.txt" ftype=ascii rectype=crlf skip=0 fieldtype=delimited custom=";" colhead=1 namepos=custom eoltype=pad badfield=NA @smpl @all
If I remove the last row, it's working fine.

I tested this under all these version, with same bug:
- Eviews 13 Jun 20 2024 build
- Eviews 14 Dec 26 2024 build

Thanks for your help.
Attachments
issue.png
issue.png (4.44 KiB) Viewed 48765 times

startz
Non-normality and collinearity are NOT problems!
Posts: 3796
Joined: Wed Sep 17, 2008 2:25 pm

Re: Illegal date when importing txt file

Postby startz » Tue Feb 11, 2025 9:06 am

If you could post that last row in the text file there's better chance someone might catch what's wrong.

patrice
Posts: 18
Joined: Tue Oct 12, 2010 2:10 am

Re: Illegal date when importing txt file

Postby patrice » Tue Feb 11, 2025 9:19 am

The attached txt file in the ticket contains this row, I have the error message using this txt file.
Attachments
eviews_issue.txt
(3.47 MiB) Downloaded 21909 times

startz
Non-normality and collinearity are NOT problems!
Posts: 3796
Joined: Wed Sep 17, 2008 2:25 pm

Re: Illegal date when importing txt file

Postby startz » Tue Feb 11, 2025 9:30 am

If it helps, I get the same error you do. But if I use File/Open it appears to work. No idea why.

patrice
Posts: 18
Joined: Tue Oct 12, 2010 2:10 am

Re: Illegal date when importing txt file

Postby patrice » Tue Feb 11, 2025 12:00 pm

Thanks, but unfortunatly I'm using this in an eviews program.

EViews Gareth
Fe ddaethom, fe welon, fe amcangyfrifon
Posts: 13583
Joined: Tue Sep 16, 2008 5:38 pm

Re: Illegal date when importing txt file

Postby EViews Gareth » Tue Feb 11, 2025 7:17 pm

You're trying to import panel data (I think?) into a dated workfile, and it is failing.

Rather than create the workfile and then import, just open the text file as a new workfile.

Code: Select all

wfopen "c:\temp\eviews_issue.txt" ftype=ascii rectype=crlf skip=0 fieldtype=delimited custom=";" colhead=1 namepos=custom eoltype=pad badfield=NA @smpl @all
Then manipulate it after opening.

startz
Non-normality and collinearity are NOT problems!
Posts: 3796
Joined: Wed Sep 17, 2008 2:25 pm

Re: Illegal date when importing txt file

Postby startz » Tue Feb 11, 2025 7:25 pm

Some of the dates look like 201001. Is there a good way to handle that?

patrice
Posts: 18
Joined: Tue Oct 12, 2010 2:10 am

Re: Illegal date when importing txt file

Postby patrice » Wed Feb 12, 2025 12:30 am

You're trying to import panel data (I think?) into a dated workfile, and it is failing.

Rather than create the workfile and then import, just open the text file as a new workfile.

Code: Select all

wfopen "c:\temp\eviews_issue.txt" ftype=ascii rectype=crlf skip=0 fieldtype=delimited custom=";" colhead=1 namepos=custom eoltype=pad badfield=NA @smpl @all
Then manipulate it after opening.
Thanks for this, but do-you know why there is this error message ? is-it a eviews bug ? (It's not an easy task to change my program)

EViews Gareth
Fe ddaethom, fe welon, fe amcangyfrifon
Posts: 13583
Joined: Tue Sep 16, 2008 5:38 pm

Re: Illegal date when importing txt file

Postby EViews Gareth » Wed Feb 12, 2025 8:25 am

The last line of your file has no date.


Return to “Bug Reports”

Who is online

Users browsing this forum: No registered users and 2 guests