Focal Point Banner


As of December 1, 2020, Focal Point is retired and repurposed as a reference repository. We value the wealth of knowledge that's been shared here over the years. You'll continue to have access to this treasure trove of knowledge, for search purposes only.

Join the TIBCO Community
TIBCO Community is a collaborative space for users to share knowledge and support one another in making the best use of TIBCO products and services. There are several TIBCO WebFOCUS resources in the community.

  • From the Home page, select Predict: WebFOCUS to view articles, questions, and trending articles.
  • Select Products from the top navigation bar, scroll, and then select the TIBCO WebFOCUS product page to view product overview, articles, and discussions.
  • Request access to the private WebFOCUS User Group (login required) to network with fellow members.

Former myibi community members should have received an email on 8/3/22 to activate their user accounts to join the community. Check your Spam folder for the email. Please get in touch with us at community@tibco.com for further assistance. Reference the community FAQ to learn more about the community.


Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [CLOSED] How skip the first n lines on a flat file

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[CLOSED] How skip the first n lines on a flat file
 Login/Join
 
Member
posted
I have a flat file that I want to read, but start the read at line 5 of the file, is this possible on the meta definition?

The first 4 lines contain header information that is not delimited. Here is what I currently have:

  
FILE=ff_uhro_backgroundchecks, SUFFIX=DFIX, REMARK='background checks per day per store'
SEGNAME=ROOT_SEG, SEGTYPE=S1, $
  FIELD=DELIMITER, ALIAS=|, USAGE=A1, ACTUAL=A1, $
  FIELD=STORE_NUM, ALIAS=STORE_NUM, USAGE=I4L, ACTUAL=A4, DESCRIPTION='Store Number', $
  FIELD=CHECK_DATE, ALIAS=CHECK_DATE, USAGE=YYMD, ACTUAL=A8, DESCRIPTION='Date', $
  FIELD=CHECK_COUNT, ALIAS=FILE_NAME, USAGE=A4, ACTUAL=I4, DESCRIPTION='Number of Background checks ran that day', $

This message has been edited. Last edited by: <Kathryn Henning>,


WF 7.6
 
Posts: 1 | Registered: May 30, 2014Report This Post
Virtuoso
posted Hide Post
John,

Firstly, I think CHECK_COUNT has the incorrect ACTUAL & USAGE. Should the line be:
  FIELD=CHECK_COUNT, ALIAS=FILE_NAME, USAGE=I4, ACTUAL=A4, DESCRIPTION='Number of Background checks ran that day', $

with the ACTUAL & USAGE reversed.

OK. As the heading lines are not delimited, all you need to know is the maximum length of the longest heading lines. For this example I use 80 characters, but almost anything above the maximum heading length will do:
FILE=ff_uhro_backgroundchecks, SUFFIX=DFIX, REMARK='background checks per day per store'
SEGNAME=ROOT_SEG, SEGTYPE=S1, $
  FIELD=STORE_NUM, ALIAS=STORE_NUM, USAGE=I4L, ACTUAL=A80, DESCRIPTION='Store Number', $
  FIELD=CHECK_DATE, ALIAS=CHECK_DATE, USAGE=YYMD, ACTUAL=A8, DESCRIPTION='Date', $
  FIELD=CHECK_COUNT, ALIAS=FILE_NAME, USAGE=I4, ACTUAL=A4, DESCRIPTION='Number of Background checks ran that day', $

use the ACTUAL in STORE_NUM to be the maximum length.

Then the file should TABLE correctly.


Alan.
WF 7.705/8.007
 
Posts: 1451 | Location: Portugal | Registered: February 07, 2007Report This Post
  Powered by Social Strata  

Read-Only Read-Only Topic

Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [CLOSED] How skip the first n lines on a flat file

Copyright © 1996-2020 Information Builders