Sorting and secondary index 
Author Message
 Sorting and secondary index

Subject: [P4W] Sorting and secondary index?
Keywords:

I have a table in which the primary key is 'CustNo'.
I know this means the table will always sort on CustNo
unless I define another way for it to sort.  

Well, I needed to add a Tracking number since the user
will be adding and deleting customers.  This would require
keeping all the customers in a sequential order and if
there are three other tables linked to the main table,
all of which use CustNo, then changingg that number wouldn't
be a very good idea.  Not to mention, that I'm not allowed
to enter duplicate customer numbers.

Having added the Tracking number, I wanted to have the
table sort on Tracking number.  I can get it to sort alright,
but once I quit from the table, the sort that I set up
won't save and I'm back to sorting by CustNo.  This is
very frustrating since, if a customer is inserted at
a certain spot (say between Customers 103 and 104), I assign
the new customer a number of 999 and a sequential tracking
number.  The customer goes to the end of the list, however,
because of the current sort.

I tried defining TrackNo as a secondary index and then
having it sort by that index, but, like I mentioned
before, once you quit from the table, it doesn't save
the declaration.  Bring the table back up and look
at it's structure and my primary key, defined as
referential integrity, is now the default and TrackNo
is no longer secondary index, but the default.

I tried making the TrackNo the first field and thus the
primary key, but now, duplicate customer numbers are
allowed to be entered and I can't enter duplicate
Tracking numbers.  

Any ideas on how to change the sort and SAVE the
damn thing??? I tried calling Borland for support
but was told 'it's $129 for 1 year of support'.  That's
almost as much as I paid for this package!!  

The manual is more than clear about changing the sort
and order/range, but it mentions nothing about making sure
it stays that way.

Thanks in advance for any help.
Rick

--
==========================================================
Rick Savoia                     | "I'm just very selective


==========================================================

--
==========================================================
Rick Savoia                     | "I'm just very selective


==========================================================



Wed, 21 Aug 1996 02:05:09 GMT
 
 [ 1 post ] 

 Relevant Pages 

1. Sort on secondary index in TDBLookupCombo

2. PDW 5.0 How to redo sort with secondary index?

3. Sorting on secondary index? Advice Please!

4. Secondary indexing ...sort of ?

5. Help! Sorting Detail Table by secondary Index

6. Question: Secondary Index Sorting...

7. Secondary index sort order

8. Sorting the view via secondary index

9. Sorting Secondary Indexes P4W

10. Sorting a report by secondary index

11. Adding Secondary Indexes without a Primary Index

12. Primary Index Vs Secondary Indices


 
Powered by phpBB® Forum Software