Closed 0x5487 closed 10 years ago
I think this is you want.
type Table struct {
A string `xorm:"unique(1) unique(2)"`
B string `xorm:"unique(1)"`
C string `xorm:"unique(2)"`
D string
}
Hi Lunny,
Wow, awesome!! That is the feature I am looking for. Thanks for helping me. I appreciate your help.
Thanks, Jason
HI All,
I have a table with 4 columns. For example, a, b, c, d columns. I would like to create two unique indexs. One is called "unique1" based on a and b columns. Another is called "unique2" based on a and c columns. On the other hands, a columns has been used by two unique indexs. However, please correct me if I am wrong. It seems we can't create multiple indexs cross different columns at this moment. If the feature will be added that will be very useful.
Thank you Jason