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] Split Alpha Field to Individual Records?

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[CLOSED] Split Alpha Field to Individual Records?
 Login/Join
 
Platinum Member
posted
I have a data field that appears to be A255 format, but it is holding multime records in the single field.

There appears to be a record delimiter of "", and a field delimiter of "".

Is it possible to create a new hold file that would split the A255 field into indivisual records?

Once I split them into individual records, I'm guessing I can use GETTOK to split the record into individual fields.

Thank you.

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


Production - 7.6.4
Sandbox - 7.6.4
 
Posts: 241 | Location: Bethesda, MD | Registered: August 14, 2007Report This Post
Silver Member
posted Hide Post
You can do that before you take it to a HOLD file. Use DEFINE fields to break the large field into individual fields.
FIELD2/An=GETTOK(FIELD1,len1,tno,'delim',olen,format); .... separate fieldname at delimiter
FIELD1: .... alphanumeric fieldname or 'literal' to be separated
len1: .... length of FIELD1
tno: .... divide at which delimiter instance (n=from left, -n=from right)
delim: .... separate at this character
olen: .... maximum length of the output value
FIELD2: .... string extracted from tno-1 to tno
format: 'An' .... specify the receiving format
format: fieldname .... specify a fieldname having the required format
From the WebFOCUS Keysheet.



WebFOCUS 8.0.2, FOCUS since 1977 - John@Aviter.com
PDF , Excel, FOCUS, Author of the Keysheets and Dates book.
www.Aviter.com
 
Posts: 40 | Registered: April 19, 2013Report This Post
Virtuoso
posted Hide Post
Breaking your 1 field into multiple records will require the use of the McGyver technique (look it up) which allows you to "multiply" a single record into many based on some condition of your choice.



Prod/Dev: WF Server 8008/Win 2008 - WF Client 8008/Win 2008 - Dev. Studio: 8008/Windows 7 - DBMS: Oracle 11g Rel 2
Test: Dev. Studio 8008 /Windows 7 (Local) Output:HTML, EXL2K.
 
Posts: 1533 | Registered: August 12, 2005Report This Post
Expert
posted Hide Post
i can't tell what the record delimiter is, in your post above,
but another approach might be to write an MFD that declares this file as a DFIX with a delimiter set to be whatever that record character is.
then read and write out as records
then repeat using another master with another delimiter to separate the records into fields.
Lather ,rinse, repeat.
I prefer POSIT and SUBSTR functions to POSIT, (but i'm just stuck in my ways.)




In Focus since 1979///7706m/5 ;wintel 2008/64;OAM security; Oracle db, ///MRE/BID
 
Posts: 3811 | Location: Manhattan | Registered: October 28, 2003Report This Post
Platinum Member
posted Hide Post
The delimiter appears to be the ascii equivilent of decimal 192. I tried copy/pasting it from the data and it does not appear to have worked.


Production - 7.6.4
Sandbox - 7.6.4
 
Posts: 241 | Location: Bethesda, MD | Registered: August 14, 2007Report This Post
Silver Member
posted Hide Post
Old trick - may still work:
Hold down the ALT key then press 192 on the numeric keypad. Used to insert the ascii 192 character.



WebFOCUS 8.0.2, FOCUS since 1977 - John@Aviter.com
PDF , Excel, FOCUS, Author of the Keysheets and Dates book.
www.Aviter.com
 
Posts: 40 | Registered: April 19, 2013Report This Post
Silver Member
posted Hide Post
Building on the suggestion of susannah, if the field is truly A255 (not A255V) and all the data elements are of a fixed length within the field, you can just write another Master File describing each of the individual elements as A12, A24 A64 etc.. You can then issue the USE FILENAME AS NewMaster to access the individual elements within the large field.
The total length must be the same (A255) and you must allow for the delimiters (usually A1).



WebFOCUS 8.0.2, FOCUS since 1977 - John@Aviter.com
PDF , Excel, FOCUS, Author of the Keysheets and Dates book.
www.Aviter.com
 
Posts: 40 | Registered: April 19, 2013Report 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] Split Alpha Field to Individual Records?

Copyright © 1996-2020 Information Builders