Skip to content

Conversation

@joshbwlng
Copy link
Contributor

@joshbwlng joshbwlng commented Jul 9, 2025

Change-type: patch


Note: Just a PoC for now

@joshbwlng joshbwlng self-assigned this Jul 9, 2025
Comment on lines +753 to +764
const sortWeightByType: Record<string, number> = {
'Big Integer': 1,
'Big Serial': 1,
'Date Time': 1,
Integer: 2,
Serial: 2,
'Short Text': 3,
File: 4,
Text: 4,
// eslint-disable-next-line id-denylist
Boolean: 5,
} as const;
Copy link
Contributor Author

@joshbwlng joshbwlng Jul 10, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We could potentially also store sorting weights as a property of the types themselves in sbvr-types. Although from what I understand MySQL doesn't have similar padding issues so it would probably only make sense for Postgres.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants