drizzle-team / drizzle-team/drizzle-orm
[FEATURE]: drizzle seed should support custom datatypes
- Dominant language
- TypeScript
- Stars
- 35.8k
- Forks
- 1.6k
- Avg merge
- 2d 7h
- Merged PRs (30d)
- 4
Description
### Feature hasn't been suggested before.
- [X] I have verified this feature I'm about to request hasn't been suggested before.
### Describe the enhancement you want to request
`drizzle-seed` should support seeding columns with custom dataypes - in my case, i have a `bytea` custom datatype (because postgres `bytea` is not yet natively supported by drizzle).
i had expected that i could just provide a custom refinement function for that column, like this:
```ts
await seed(db, schema).refine(() => {
return {
usersTable: {
columns: {
recoveryCode() {
return Buffer.from(encryptString(generateRandomRecoveryCode()));
},
},
},
};
});
```
but that still throws with "Error: column with type bytea is not supported for now."
Contributor guide
Assessment
This issue has not been assessed yet.