You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Add support for generating insertable structs in diesel_ext
- Updated README.md to reflect the addition of insertable options.
- Modified main.rs to include command-line options for generating insertable structs.
- Enhanced parse.rs to handle insertable struct generation logic.
- Created expected output for insertable structs in schema_insertable.rs.
Insertable structs are perfect for database inserts as they omit auto-increment and default value columns. This follows Diesel's recommended pattern of using separate structs for querying and inserting data.
108
+
109
+
**Key Features:**
110
+
- Automatically skips common auto-generated fields (`id`, `created_at`, `updated_at`)
111
+
- Uses string references (`&'a str`) for better performance
112
+
- Supports custom field skipping and optional field configuration
0 commit comments