pg.ddx.io  pgsql-general@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Adrian Klaver <adrian.klaver@aklaver.com>
To: ourdiaspora <ourdiaspora@protonmail.com>
To: pgsql-general@lists.postgresql.org <pgsql-general@lists.postgresql.org>
Subject: Re: use fopen unknown resource
Date: Fri, 27 Aug 2021 15:10:19 -0700
Message-ID: <d7b0f1c6-33b9-38f9-7a28-41e773ef7eee@aklaver.com> (raw)
In-Reply-To: <IrQH-v4UQGJ7mcslUIQnwwlMMpX8GGztHmZDKsBJbwFxhJyo_AYOTbzUug8pVzzvXjq7xfBB7MfPmvy1OcAB1Z5LjMoynM-PFYNP58c_IaI=@protonmail.com>
References: <IrQH-v4UQGJ7mcslUIQnwwlMMpX8GGztHmZDKsBJbwFxhJyo_AYOTbzUug8pVzzvXjq7xfBB7MfPmvy1OcAB1Z5LjMoynM-PFYNP58c_IaI=@protonmail.com>

On 8/27/21 2:59 PM, ourdiaspora wrote:
> Readers,
> 
> Objective, to import a csv file into postgresql database. If understood correctly, the manual section 'fopen' (https://www.php.net/manual/en/function.fopen.php) shows that the file has a "known resource" extant name.
> 
> Please what is the syntax to assign an unknown file name to the 'fopen' function?
> 

Why not use?:

https://www.php.net/manual/en/pdo.pgsqlcopyfromfile.php


-- 
Adrian Klaver
adrian.klaver@aklaver.com





view thread (8+ messages)  latest in thread

Message-ID: <d7b0f1c6-33b9-38f9-7a28-41e773ef7eee@aklaver.com>
Permalink:  ../d7b0f1c6-33b9-38f9-7a28-41e773ef7eee@aklaver.com/
Also on:    postgresql.org/message-id/d7b0f1c6-33b9-38f9-7a28-41e773ef7eee@aklaver.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-general@postgresql.org
  Cc: adrian.klaver@aklaver.com, ourdiaspora@protonmail.com
  Subject: Re: use fopen unknown resource
  In-Reply-To: <d7b0f1c6-33b9-38f9-7a28-41e773ef7eee@aklaver.com>
  References: <IrQH-v4UQGJ7mcslUIQnwwlMMpX8GGztHmZDKsBJbwFxhJyo_AYOTbzUug8pVzzvXjq7xfBB7MfPmvy1OcAB1Z5LjMoynM-PFYNP58c_IaI=@protonmail.com> <d7b0f1c6-33b9-38f9-7a28-41e773ef7eee@aklaver.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox