这是indexloc提供的服务,不要输入任何密码
Skip to content

Inject current date when using www.mycli.net/commands ? #1172

@HtwoO

Description

@HtwoO

Is it possible to inject current date/time when using https://www.mycli.net/commands

Concrete example, when exported data to a file:

tableformat csv; \once ~/data.dump.<generated.date>.csv;
select ... from ... where ...;
notee; tableformat ascii;

One would like to inject the current date/time into the filename, either by a SQL query like

select substring(now(), 1, 10);

or by mycli's system command and generate date from date command in the shell like the following

tableformat csv; \once ~/data.dump.$(system date +%F).csv;
...

Maybe it's supported, but not documented in a guide? I can not find an example.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions