BookmarkSubscribeRSS Feed
Choose Language Hide Translation Bar
lwx228

Not applicable

Joined:

Aug 14, 2018

How do I use JSL to control the bulk import of each column data format of TXT text?

Dear all:
There are multiple TXT format table data in the same path, but I only import one file into JMP at a time.

 

Since each TXT file has different column names and number of columns, how to use JSL to unify the data to be imported from column 8 to the last column to be set to consecutive number format?Thank you very much!

5 REPLIES 5
lwx228

Not applicable

Joined:

Aug 14, 2018

Re: How do I use JSL to control the bulk import of each column data format of TXT text?

I think this way of recording with JMP is too complicated.

 

2018-09-05_18-13-04.png

txnelson

Super User

Joined:

Jun 22, 2012

Re: How do I use JSL to control the bulk import of each column data format of TXT text?

I would suggest that you try just using the Open() function with just the path as input.  That way, JMP will use the defaults, and examine the file and open the table.  You can then use your JSL to determine what has been input, and to modify the data table down to what you need.

Jim
lwx228

Not applicable

Joined:

Aug 14, 2018

Re: How do I use JSL to control the bulk import of each column data format of TXT text?

Well, that's all. Thank you very much!

The actual data of my TXT file are all over 600 columns, some of which may have a lot of null values. JMP automatically determines that these columns are in text format, and as a result, these columns do not have data import, which is troublesome to deal with.
txnelson

Super User

Joined:

Jun 22, 2012

Re: How do I use JSL to control the bulk import of each column data format of TXT text?

I would like a bit more detail on what you mean by "troublesome".  Having JMP parse across a data table with lots of blank columns, and determining which ones to delete, etc. ia a relatively easy thing to do.  So in the past, I have typically taken this approach.

Jim
lwx228

Not applicable

Joined:

Aug 14, 2018

Re: How do I use JSL to control the bulk import of each column data format of TXT text?

This allows me to write the JSL way of importing files in a one-to-one way, which gives me more open() code.A single file has 50, 000 characters of open() code.