mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-12-04 21:42:39 +00:00
23 lines
493 B
C++
23 lines
493 B
C++
|
#pragma once
|
||
|
|
||
|
#include <TableFunctions/ITableFunction.h>
|
||
|
|
||
|
|
||
|
namespace DB
|
||
|
{
|
||
|
|
||
|
/* numbers(limit)
|
||
|
* - the same as SELECT number FROM system.numbers LIMIT limit.
|
||
|
* Used for testing purposes, as a simple example of table function.
|
||
|
*/
|
||
|
class TableFunctionNumbers : public ITableFunction
|
||
|
{
|
||
|
public:
|
||
|
static constexpr auto name = "numbers";
|
||
|
std::string getName() const override { return name; }
|
||
|
StoragePtr execute(const ASTPtr & ast_function, const Context & context) const override;
|
||
|
};
|
||
|
|
||
|
|
||
|
}
|