table-creator-macro2-0.1.1 has been yanked.
A simple macro to generate a specified sql when we have a struct A
For example:
#[derive(TableCreator)]
struct A {
#[table_ignore]
a: i32,
b: String,
}
printfln!("{}", A.table_creat_sql()}
the output is :
'''CREATE TABLE IF NOT EXISTS A (id SERIAL PRIMARY KEY, b TEXT )
the element , with #[table_ignore], will be ignored