I Dict entry multivalue

12 views
Skip to first unread message

JOSE L MARTINEZ-AVIAL

unread,
Nov 20, 2009, 6:28:42 AM11/20/09
to jb...@googlegroups.com
Hello,
   I'm using Jbase 5.0.14 on HPUX 11.11. I'm trying to create a I Dict record for a table that works as a multivalue The I dict record is composed of three fields. Two of the fields form part of a multivalue, but the first one is the @ID. I am unable to get the @ID to spread over the multivalue, so I only see the @ID in the first multivalue. My I Dict record is as follows:

File ../bnk.dict/F.SC.POS.001]D , Record 'SC.POSITION.ID'                                                      Insert      21:23:44
Command->
0001 I
0002 @ID:".":SECURITY.NO:".":DEPOSITORY:"...."
0003
0004 SC.POSITION.ID
0005 35L
0006 M
0007
0008
0009
0010
0011
0012
0013
0014 @ID:".":SECURITY.NO:".":DEPOSITORY:"...."

And the result I'm obtaining is the following:
@ID...........................    SECURITY.NO....    DEPOSITORY........    SC.POSITION.ID.....................

                27488-4.320.20         0071708124    19313                 27488-4.320.20.0071708124.19313....
                                       0041071915    60061                 0041071915.60061....              
                                       0009113120    19313                 0009113120.19313....              
                                       0002470226    19313                 0002470226.19313....              
                                       0000359701    19313                 0000359701.19313....  
As you can see, the field SC.POSITION.ID only has the @ID in the first multivalue, but I need all of them to have it. How can I do it?

TIA

JL
jsh miadev02 ~ -->jdiag
        jdiag - jBASE diagnostic '$Revision: 1.15 $'

System Information
==================

System                      : HP-UX miaux02 B.11.11.U 9000/800
UNIX User                   : miadev02 (uid 107, euid 107)
Tty name                    : /dev/pts/te
Time                        : Wed Nov 18 21:33:23 2009

Environment
===========

JBCPORTNO                   : Not Set
JBCRELEASEDIR               : '/apps/jbase5.0.14'
JBCGLOBALDIR                : '/apps/jbase5.0.14'
JBCDATADIR                  : '/ve8/miadev02/bnk/bnk.run/../bnk.data'
HOME                        : '/ve8/miadev02/bnk/bnk.run'
JEDIFILEPATH                : '/ve8/miadev02/bnk/bnk.run'
JEDIFILENAME_MD             : '/ve8/miadev02/bnk/bnk.run/VOC'
JEDIFILENAME_SYSTEM         : '/apps/jbase5.0.14/src/SYSTEM'
SYSTEM File is (DICT)       : '/apps/jbase5.0.14/src/SYSTEM]D'
RELEASE Information         : Major 5.0 , Minor 14 , Patch 0287 (Change 73758)
Spooler dir (JBCSPOOLERDIR) : '/ve8/miadev02/bnk/bnk.run/jspooler'
JBCEMULATE                  : 'prime'
WARNING: Cannot access Executable path '/ve8/miadev02/bnk/bnk.run/globuspatchbin', error 2
WARNING: Cannot access Library path '/apps/jbase5.0.14/jdk/jre/lib', error 2
Object path (JBCOBJECTLIST) : '/ve8/miadev02/bnk/bnk.run/globuspatchlib:/ve8/miadev02/bnk/bnk.run/lib:/ve8/miadev02/bnk/bnk.run/glo'
jBASE Compiler Run-time     : '/apps/jbase5.0.14/config/system.properties'
Program dir (JBCDEV_BIN)    : '/ve8/miadev02/bnk/bnk.run/bin'
Subroutine dir (JBCDEV_LIB) : '/ve8/miadev02/bnk/bnk.run/lib'
Max open files              : 2048



Daniel Klein

unread,
Nov 20, 2009, 7:35:18 AM11/20/09
to jb...@googlegroups.com
REUSE(@ID)

Dan
> --
> Please read the posting guidelines at:
> http://groups.google.com/group/jBASE/web/Posting%20Guidelines
>
> IMPORTANT: Type T24: at the start of the subject line for questions specific
> to Globus/T24
>
> To post, send email to jB...@googlegroups.com
> To unsubscribe, send email to jBASE-un...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/jBASE?hl=en

JOSE L MARTINEZ-AVIAL

unread,
Nov 20, 2009, 9:48:35 AM11/20/09
to jb...@googlegroups.com
Hi Dan,
   Thanks for the suggestion, but it doesn't seem to work. I keep getting the ID only in the first field. Any idea?

Regards

Jose

2009/11/20 Daniel Klein <daniel...@gmail.com>

JOSE L MARTINEZ-AVIAL

unread,
Nov 21, 2009, 11:36:21 AM11/21/09
to jb...@googlegroups.com
Hi Dan,
   Thanks for the suggestion, but it doesn't seem to work. I keep getting the ID only in the first field. Can you give an example?

Regards

Jose

2009/11/20 Daniel Klein <daniel...@gmail.com>
REUSE(@ID)

JOSE L MARTINEZ-AVIAL

unread,
Nov 22, 2009, 5:49:25 PM11/22/09
to jb...@googlegroups.com

Daniel Klein

unread,
Nov 23, 2009, 9:50:54 PM11/23/09
to jb...@googlegroups.com
Well, it works for me.

Saying 'it doesn't seem to work' is not enough.

What does your I-type look like now?

What are the dictionary definitions for 'SECURITY.NO' and 'DEPOSITORY' ?

What is the data structure it is operating on? Can you post an example
of a record in the file?

An example? Ok, here you go:

Data item ID: xyz
0001 A]B]C
0002 1]2]3

I-types:

ID: REUSEID
0001 I
0002 REUSE(@ID:"." ):OTHERSTUFF
0003
0004
0005 10L

ID: OTHERSTUFF
Command->
0001 I
0002 @RECORD<1>:".":@RECORD<2>
0003
0004
0005 L10

And the output ( using the statement 'LIST TESTFILE REUSEID ID-SUPP' )
is...<drum roll>...


REUSEID...

xyz.A.1
xyz.B.2
xyz.C.3

1 Records Listed

Dan


On Sat, Nov 21, 2009 at 11:36 AM, JOSE L MARTINEZ-AVIAL
technical_support.jpg

JOSE L MARTINEZ-AVIAL

unread,
Nov 23, 2009, 11:25:54 PM11/23/09
to jb...@googlegroups.com
Hi Dan,
   You are right, doesn't work doesn't mean anything. I just got the same result as when I don't use the REUSE. I should have sent the definition of the I-Desc I was creating. But with the example you sent, I recreated it, and it did work. So I started to modify it until I got what I wanted. And then I figured what was my error:

Your I-Dict was
File TESTFILE]D , Record 'REUSEID'                                                                             Insert      23:12:57
Command-> EXIT

0001 I
0002 REUSE(@ID:"." ):OTHERSTUFF
0003
0004
0005 10L

Mine was
NEW *File TESTFILE]D , Record 'REUSEID2'                                                                       Insert      23:13:37
Command-> FI
0001 I
0002 REUSE(@ID:"." );FIELD(@1,".",1):OTHERSTUFF
0003
0004
0005 10L

The result was:
jsh miadev02 ~ -->LIST TESTFILE REUSEID REUSEID2

LIST TESTFILE REUSEID REUSEID2                                                                 PAGE    1 23:13:50  23 NOV 2009

TESTFILE......    REUSEID...    REUSEID2..

XYZ               XYZ.A.1       XYZA.1   
                  XYZ.B.2       B.2      
                  XYZ.C.3       C.3 

It seems that it doesn't like the FIELD (Although I am pretty sure I've seen I-Desc with that syntax). Since in this table there is other single field that already does the FIELD(@ID,".",1), my final I-Desc is:

0001 I
0002 REUSE(PORTFOLIO.NO:"." ):SECURITY.NO:".":DEPOSITORY:"...."

0003
0004 SC.POSITION.ID
0005 35L

And it works:
@ID...........................    SECURITY.NO....    DEPOSITORY........    SC.POSITION.ID.....................

                27488-4.320.20         0071708124    19313                 27488-4.0071708124.19313....      
                                       0041071915    60061                 27488-4.0041071915.60061....      
                                       0009113120    19313                 27488-4.0009113120.19313....      
                                       0002470226    19313                 27488-4.0002470226.19313....      
                                       0000359701    19313                 27488-4.0000359701.19313....      
                42276-4.106.25         0094946182    19012                 42276-4.0094946182.19012.... 

Thank you for your help. By the way, I had a lot of troubles sending mails to the list this weekend. All of them got delayed. Anybody knows why?
Jose


2009/11/23 Daniel Klein <daniel...@gmail.com>
Reply all
Reply to author
Forward
0 new messages