table: Add SelectAll
This commit is contained in:
committed by
Michal Jan Matczuk
parent
5a48acca36
commit
bc762ebc01
@@ -130,6 +130,11 @@ func (t *Table) SelectBuilder(columns ...string) *qb.SelectBuilder {
|
|||||||
return qb.Select(t.metadata.Name).Columns(columns...).Where(t.partKeyCmp...)
|
return qb.Select(t.metadata.Name).Columns(columns...).Where(t.partKeyCmp...)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// SelectAll returns select * statement.
|
||||||
|
func (t *Table) SelectAll() (stmt string, names []string) {
|
||||||
|
return qb.Select(t.metadata.Name).ToCql()
|
||||||
|
}
|
||||||
|
|
||||||
// Insert returns insert all columns statement.
|
// Insert returns insert all columns statement.
|
||||||
func (t *Table) Insert() (stmt string, names []string) {
|
func (t *Table) Insert() (stmt string, names []string) {
|
||||||
return t.insert.stmt, t.insert.names
|
return t.insert.stmt, t.insert.names
|
||||||
|
|||||||
Reference in New Issue
Block a user