psql Verified for current stable LTS

Psql Command: Execute Sql Query On Database

Use for execute sql query on database with Psql. Exact CLI syntax to execute sql query on database using Psql.

When to use this: Use for execute sql query on database with Psql.

Command Syntax

psql -c '<query>' <database>

Command Breakdown

-c
Command Option
Tool-specific option used by this command invocation.

FAQ

Purpose: Exact syntax to execute sql query on database using Psql.

Test path: Replace placeholders and run destructive commands in a disposable workspace first.

Flag behavior: Tool version, platform, and shell can change behavior.

Improve This Command

Suggest a correction, safer default, or version-specific note for this entry.

Related Operations

Back to Psql directory