One Star

[resolved] postgresql bulk loading is erroring out if the DB is on remote server.

I am trying to load a txt file on my Desktop into a remote DB server. It is erroring out with following messege.
"org.postgresql.util.PSQLException: ERROR: could not open file "E:/projects/Talend/clients.txt" for reading: No such file or directory".
It works if i copy the file manually to the remote server and provide the path it works.
Can postgres bulkload operations work with file located on the Client machine (Where Talend is installed) & the DB is on a different server?
Thanks
Srinivas
1 ACCEPTED SOLUTION

Accepted Solutions
Employee

Re: [resolved] postgresql bulk loading is erroring out if the DB is on remote server.

Hi sbethi, you are correct ... bulkloading is available only when the bulkload file resides on the same server as the db.
4 REPLIES
Community Manager

Re: [resolved] postgresql bulk loading is erroring out if the DB is on remote server.

Hello
Can postgres bulkload operations work with file located on the Client machine (Where Talend is installed) & the DB is on a different server?

The file must exist on the server, so now you can use a ftp componnet to put the file to server first. eg:
tFileInputDelimited--->tPostgresOutputBulk
|
onsubjobok
|
tFtpPut
|
onSubjobok
|
tPostgreOutputBulkExec
Best regards
shong
----------------------------------------------------------
Talend | Data Agility for Modern Business
One Star

Re: [resolved] postgresql bulk loading is erroring out if the DB is on remote server.

I tried the above solution earlier & it worked for me. Looks like there is no bulk load component to load the file from client directly.
Srinivas
Employee

Re: [resolved] postgresql bulk loading is erroring out if the DB is on remote server.

Hi sbethi, you are correct ... bulkloading is available only when the bulkload file resides on the same server as the db.
One Star

Re: [resolved] postgresql bulk loading is erroring out if the DB is on remote server.

Thank you.