mirror of
https://github.com/vlang/v.git
synced 2023-08-10 21:13:21 +03:00
orm: limit
This commit is contained in:
@ -168,6 +168,12 @@ fn test_orm_sqlite() {
|
||||
}
|
||||
assert no_user.name == '' // TODO optional
|
||||
assert no_user.age == 0
|
||||
//
|
||||
two_users := sql db {
|
||||
select from User limit 2
|
||||
}
|
||||
assert two_users.len == 2
|
||||
assert two_users[0].id > 0
|
||||
}
|
||||
|
||||
struct User {
|
||||
|
Reference in New Issue
Block a user