-
Notifications
You must be signed in to change notification settings - Fork 590
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor(expr): separate user-facing
rw_vnode
from the internal one (…
…#18815) Signed-off-by: Bugen Zhao <[email protected]>
- Loading branch information
Showing
11 changed files
with
120 additions
and
44 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
query error takes at least 2 arguments \(0 given\) | ||
select rw_vnode(); | ||
|
||
query error takes at least 2 arguments \(1 given\) | ||
select rw_vnode(256); | ||
|
||
query I | ||
select rw_vnode(256, 114, 514); | ||
---- | ||
97 | ||
|
||
query I | ||
select rw_vnode(4096, 114, 514); | ||
---- | ||
1377 | ||
|
||
# VirtualNode::MAX_COUNT | ||
query I | ||
select rw_vnode(32768, 114, 514); | ||
---- | ||
21857 | ||
|
||
query error the first argument \(vnode count\) must not be NULL | ||
select rw_vnode(NULL, 114, 514); | ||
|
||
query error the first argument \(vnode count\) must be in range 1..=32768 | ||
select rw_vnode(0, 114, 514); | ||
|
||
query error the first argument \(vnode count\) must be in range 1..=32768 | ||
select rw_vnode(32769, 114, 514); | ||
|
||
statement ok | ||
create table vnodes (vnode int); | ||
|
||
statement ok | ||
insert into vnodes values (256), (4096); | ||
|
||
statement ok | ||
flush; | ||
|
||
query error the first argument \(vnode count\) must be a constant | ||
select rw_vnode(vnode, 114, 514) from vnodes; | ||
|
||
statement ok | ||
drop table vnodes; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters