• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: CUSTOM ORDERING IDEA
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: CUSTOM ORDERING IDEA


  • Subject: Re: CUSTOM ORDERING IDEA
  • From: Robert Walker <email@hidden>
  • Date: Thu, 27 Apr 2006 10:24:24 -0400

Amedeo,

I think we may need bit more background here. If you are talking about the order that the database engine inserts records onto the physical disk then that would be very impractical. Typically databases insert new records at the end. If they were to insert records somewhere in the middle they would have to move all the records that follow the insertion. Obviously this is not what you're talking about.

So you must be referring to using an indexed column to provide a sort ordering. One case that comes to mind, is that I had a customer who wanted to keep line items on an order in the same order they were entered into the system. Viewing an order later needed to show line items in the same order. The solution for this was to add an integer column to the line item (visible to the user). Then a routine was added to maintain this ordering during save. The routine was responsible for generating the next number on an appended item, and reordering the line numbers on an insert or delete.

If you are talking about keeping a custom ordering for an entire table that could be a real performance nightmare causing you to have to update a lot of rows each time a record is inserted (this would only be plausible if your table has just a few rows). I've used something similar to this for enumerated strings that I wanted to keep in a particular order in the database. I used a similar approach as above to support this. Again this table had only a few rows, not more than 20 in my case. Plus this only had to be maintained on a very occasional bases.

On Apr 27, 2006, at 9:34 AM, Amedeo Mantica wrote:

Hello friends!

does anyone have an idea how to implement a custom row ordering in a database?

My customers want to custom order row in database

i can create an ordering column with a double type (number) so i can always move a row between two others...

Actually I don't know how to graphically impement this (user interface)

do you have ideas? or other methods?

Thanks
Amedeo
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
40mac.com


This email sent to email@hidden

-- Robert Walker email@hidden



_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >CUSTOM ORDERING IDEA (From: Amedeo Mantica <email@hidden>)

  • Prev by Date: Re: Switch Component question...
  • Next by Date: Re: Switch Component question...
  • Previous by thread: Re: CUSTOM ORDERING IDEA
  • Next by thread: Flat file subversion EOF adaptor
  • Index(es):
    • Date
    • Thread