Skip to content
Cloudflare Docs

WranglerCommand

WranglerCommand is used 0 times on 0 pages.

Pages which use WranglerCommand

Used 0 times.

Pages

    Partials

      The WranglerCommand component documents the available options for a given command.

      Import

      import { WranglerCommand } from "~/components";

      Usage

      wrangler d1 execute

      Execute a command or SQL file

      Terminal window
      npx wrangler d1 execute [DATABASE]

      Arguments

      • database string required

        The name or binding of the DB

      • yes boolean

        Answer "yes" to any prompts

      • local boolean

        Execute commands/files against a local DB for use with wrangler dev

      • remote boolean

        Execute commands/files against a remote DB for use with wrangler dev

      • file string

        A .sql file to ingest

      • command string

        A single SQL statement to execute

      • persist-to string

        Specify directory to use for local persistence (for --local)

      • json boolean default: false

        Return output as clean JSON

      • preview boolean default: false

        Execute commands/files against a preview D1 DB

      import { WranglerCommand } from "~/components";
      <WranglerCommand command="d1 execute" />