Red icon indicating copy to clipboard operation
Red copied to clipboard

Create default column type for Rat

Open FCO opened this issue 7 years ago • 2 comments

FCO avatar Oct 11 '18 05:10 FCO

What's important to preserve with this type, numerical query operators or the precision and exact round trip reproduction of the Rat? Ideally this would be a composite derived type in the implementing DBMS with bigint numerator, bigint denominator, derived double precision numerator / denominator. It feels like if you explicitly defined a Rat type in your models over Num as a column you are likely keen for the precision to be stored exactly, which suggests using a text type and inflating/deflating.

MattOates avatar Nov 04 '18 09:11 MattOates

I was thinking about it and I think it would make difficult to search for columns of that type... I needed a Rat and implemented as real, but it was only to solve a problem I was having. We should find a better way to do that.

FCO avatar Dec 27 '18 15:12 FCO