Hi,

You have been offered with at least two solutions. None of them is good 
to me, because your problem is probably not easy to solve :( You want to 
select part of the data from file and you want to avoid traversing of 
whole file.

Do you really need to store references of your LD contracts per 
CATEGORY? I would expect thousands of contracts for some of the 
(popular) LD categories. Just imagine that you store a lot of references 
under single CATEGORY key. Concat file record will be large and regular 
jBASE index will hash a lot of LD keys to single CATEGORY key (and this 
is poor in terms of performance). None of the solutions is therefore 
good.

1) Index cons
jBASE index may kill some of the multithreaded COB jobs. Imagine that 
there is core job that moves LD contracts to history file on maturity 
date. Usage of jBASE index may kill multithreaded nature of this job (a 
lot of multithreaded DELETEs will need to synchronize on index update). 
Expect some problems.

Usage of jBASE indexes is not a perfect solution. Maintenance of index 
data kills multithreaded jobs and introduces overhead in online.

We have found out also, that jBASE indexes may get out-of-sync in some 
scenarios. This is however fixed in one of the recent jBASE 4.1 releases 
I think. But still it seems to us that indexes may suffer from some kind 
of "fragmentation" problem. They are working slower and slower over 
time, so we regularly are rebuilding them to improve performance.

Jim could probably say some more info about indexes implementation. (As 
far as I remember from this group) They are organized as B-trees. There 
are different kinds of B-Trees, I am not sure which kind of B-Tree was 
used in jBASE implementation.

2) Concat file cons
Large concat file records may suffer from record size problem. I would 
however prefer this kind of solution over regular jBASE indexes.
Concat files are "application level" programmed indexes (independent 
tables, that need to be populated with user code).

Niels suggested some statements to retreive data when you use regular 
jBASE indexes. Here is my favourite (written from top of my head):
EXECUTE "KEY-SELECT FBNK.LD.LOANS.AND.DEPOSITS WITH CATEGORY EQ 'sth'". 
Simple and straightforward.

Kind regards
Pawel

Dnia 22-09-2009 o godz. 19:07 Niels napisał(a):
> I would problably just create an index on LD.
> 
> CREATE-INDEX FBNK.FBNK.LD.LOANS.AND.DEPOSITS CATEGORY BY CATEGORY
> 
> Retrieve would be somethink like , forgot coce
> 
> SELECTINDEX ?filename? ?indexname? ?selection? TO ID.LIST
> 
> FORMLIST ID.LIST
> Then use EB.READLIST TO do selection in selection

----------------------------------------------------
Wygraj wymarzony skuter!
Wyznacz najprostszą drogę - docelu.pl - Kliknij:
http://klik.wp.pl/?adr=http%3A%2F%2Fcorto.www.wp.pl%2Fas%2Fchapman1.html&sid=863



--~--~---------~--~----~------------~-------~--~----~
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 [email protected]
To unsubscribe, send email to [email protected]
For more options, visit this group at http://groups.google.com/group/jBASE?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to