rename_all | Renames all the struct's fields according to the given case convention. The possible values are "lowercase", "UPPERCASE", "PascalCase", "camelCase", "snake_case", "SCREAMING_SNAKE_CASE". | string | Y |
table | Explicitly define the table name. By default, it must correspond with the struct name in snake_case. Use relax_table if you want to opt out of this but not encouraged. | Option | Y |
relax_table | Determines whether the struct's name is matched to the table name as the snake case by default. This is not encouraged. Using your struct 1:1 to your database tables helps to ensure uniquness and prevent confusion. | Option | Y |
schemafull | Make the table enforce a schema struct. | Option | Y |
drop | Drop the table if it exists and create a new one with the same name. | Option | Y |
as | Inline statement e.g select(All).from(user) for creating a projection using the DEFINE TABLE statement. This is useful for copying data from an existing table in the new table definition. This is similar to making a view in a RDBMS. | A select statement | Y |
as_fn | Same as above as but defined as external function from the struct e.g select_reading_from_user for creating a projection using the DEFINE TABLE statement. This is useful for copying data from an existing table in the new table definition. This is similar to making a view in a RDBMS. | A function name | Y |
permissions | Specify permissions that apply to the table using the for statement. | ForStatement | Y |
permissions_fn | Same as permission but as an external function from the struct. Specify permissions that apply to the table using the for statement. | ForStatement | Y |
define | Generates a DEFINE TABLE statement for the table. This overrides other specific definitions to prevent confusion and collision. You can also invoke an external function directly rather than inlining the function e.g define = "define_student()" | inline code string | Y |
define_fn | Generates a DEFINE TABLE statement for the table. This overrides other specific definitions to prevent confusion and collision. Same as define attribute but expects the function name instead rather than invocation i.e define_student instead of define_student() . You can also invoke an external function directly rather than inlining the function e.g `define = "def | | |