Re: Sort question - Fractions, Metric etc - Mailing list pgsql-general

From Bret Stern
Subject Re: Sort question - Fractions, Metric etc
Date
Msg-id 434282c4-dc47-d5f2-9ade-c493bdb09074@machinemanagement.com
Whole thread Raw
In response to Re: Sort question - Fractions, Metric etc  (Adrian Klaver <adrian.klaver@aklaver.com>)
Responses Re: Sort question - Fractions, Metric etc
List pgsql-general
Yep,

I provide the UI for the user to select the vendor supplied unit value 
from the list.

I don't want anyone entering (manually) any value, they must select from 
my list (fed from a PG table).

(and since some units don't translate exactly, they pick the one that is 
closest).

It's Tile (floor, shower etc), not the tightest tolerance of dimensions, 
so it's not catastrophic if it's off

a 32nd or so.

cheers





On 8/14/2021 1:43 PM, Adrian Klaver wrote:
> On 8/14/21 1:24 PM, Bret Stern wrote:
>> Here's the clip of the UI. The user selects whatever value the vendor 
>> provides for unit thickness. The data entry
>
> So the vendors supply the measurements in all the various units for a 
> given item?
>
>>
>> people aren't comfortable converting.
>>
>> At this point the sort_order column managed to do the trick....but 
>> going forward on my next
>>
>> application, I can see a different approach.
>>
>> Are you suggesting a function like this shellsort used with an array.
>
>



pgsql-general by date:

Previous
From: Adrian Klaver
Date:
Subject: Re: Sort question - Fractions, Metric etc
Next
From: Adrian Klaver
Date:
Subject: Re: Sort question - Fractions, Metric etc