About 3,970,000 results
Open links in new tab
  1. Run a PostgreSQL .sql file using command line arguments

    Mar 16, 2012 · Walk through on how to run an SQL on the command line for PostgreSQL in Linux: Open a terminal and make sure you can run the psql command: psql --version which psql …

  2. CSE P544: Using PostgreSQL - University of Washington

    This means that an absolute pathname like D:\subdir\query.sql must be written either by doubling the backslashes, as in 'D:\\subdir\\query.sql', or turning them into forward slashes, as in …

  3. How to execute a SQL script (.sql file) in Postgres - SysOpsPro

    Apr 11, 2023 · In this guide, we covered two methods for executing SQL scripts in PostgreSQL and redirecting their output to a file: Using the psql prompt with \i and \o commands. Executing …

  4. How to Run a PostgreSQL .sql File from the Command Line?

    Dec 23, 2024 · In PostgreSQL, you can execute SQL scripts stored in .sql files directly from the command line using the psql command-line tool. This is especially useful for running complex …

  5. Run a PostgreSQL .sql file using command line arguments

    Sep 2, 2023 · How to Run a PostgreSQL .sql File using Command Line Arguments 💻. Are you struggling to run those massive .sql files with thousands of INSERT statements in your …

  6. How To Execute SQL Statements From A File On A PostgreSQL

    Jan 29, 2023 · How To Run A PSQL File With psql. How to execute multiple SQL statements stored in a file on a specified PostgreSQL database using the psql command. Also, how to …

  7. How to Run SQL File in PSQL - Delft Stack

    Feb 2, 2024 · This article explains how to run a SQL file direct from terminal/command-line or psql shell. For that, you need to specify the hostname, port, username, and database name.

  8. postgreSQL - psql \i : how to execute script in a given path

    i did try this and its working in windows machine to run a sql file on a specific schema. psql -h localhost -p 5432 -U username -d databasename -v schema=schemaname < e:\Table.sql. See …

  9. How to Run a .SQL File in PostgreSQL: A Step-by-Step Guide for ...

    Oct 30, 2023 · It allows you to connect to PostgreSQL and execute queries, SQL scripts, and other commands interactively. Follow these steps to run a .sql file using psql: Step 1 – …

  10. postgresql - How to execute SQL statement from command line …

    Jul 19, 2018 · Running psql -U username databasename will allow you to connect to that, and execute SQL queries via that command-line interpreter. If you're asking about running …

  11. Some results have been removed
Refresh