Focal Point
[SOLVED] concatenating Tables

This topic can be found at:
https://forums.informationbuilders.com/eve/forums/a/tpc/f/7971057331/m/1137005616

February 10, 2012, 08:21 AM
ChristianP
[SOLVED] concatenating Tables
Hi,
in my fex i have 3 alpha files and i want to bring them together in one table. The first two files have only one value, and i want to place them on the first two places as constants. The third alpha has the main data.

Alpha1 Aplha2 Alpha3
Q42010/11 100100 1. TRANSPORTKOSTEN INBOUND 111.000
Q42010/11 100100 1.1. SCHIENE 0
Q42010/11 100100 1.2. STRASSE 0
Q42010/11 100100 1.2.1. LKW - Nahverkehr 0
Q42010/11 100100 1.2.2. LKW - Fernverkehr 0
Q42010/11 100100 1.2.2.1. LKW - Fernverkehr National 0

Regards

Christian

This message has been edited. Last edited by: ChristianP,


WF Production Version: 7.7.02M
WF Test Version: 7.7.02M
Developer Studio: 7.7.02
HTML, EXL2K, FLEX, PDF,PPT
February 10, 2012, 10:48 AM
njsden
So you're not really "concatenating" tables.

What you need is to JOIN them *if* there is any value in ALPHA3 you can use to join to ALPHA1 and ALPHA2.

If you don't have such a value, you could make it up using a DEFINE-based JOIN.

A perhaps simpler approach would be to -READ each value from ALPHA1 and ALPHA2 into a couple of &variables.

Then, DEFINE 2 fields in ALPHA3 giving each the value of each &variable you read above.

Now you'll have everything there.

-READ ALPHA1 &ALPHA1_VAL.A9.
-READ ALPHA2 &ALPHA2_VAL.A6.

DEFINE FILE ALPHA3
ALPHA1_KEY/A9 = '&ALPHA1_VAL';   <=== 'Q42010/11'
ALPHA2_KEY/A6 = '&ALPHA2_VAL';   <=== '100100'
END

TABLE FILE ALPHA3
PRINT ALPHA1_KEY
      ALPHA2_KEY
      ALPHA3.FIELD1
      ALPHA3.FIELD2
      ...
END


quote:
The first two files have only one value


That approach I suggested should work based on your statement above, which I interpret as: ALPHA1 and ALPHA2 have *1* record/line each.

Hope that helps.



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.
February 13, 2012, 03:24 AM
ChristianP
Hi njsden,
perfect!!!!! The problem with webfocus is that nearly everything is possible and our internal costumer knows that!!!

Regards

Christian


WF Production Version: 7.7.02M
WF Test Version: 7.7.02M
Developer Studio: 7.7.02
HTML, EXL2K, FLEX, PDF,PPT
February 13, 2012, 10:07 AM
njsden
Glad it helped! I like customers like that ... challenging yet reasonable (I hope the latter applies to yours Wink ).

Would you please prefix your original post's title with [SOLVED]?

This message has been edited. Last edited by: njsden,



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.