Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1sCGLF-004LDs-6B for pgsql-general@arkaria.postgresql.org; Wed, 29 May 2024 10:15:34 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1sCGLE-00EZ9d-JH for pgsql-general@arkaria.postgresql.org; Wed, 29 May 2024 10:15:32 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1sCGLE-00EZ9U-7q for pgsql-general@lists.postgresql.org; Wed, 29 May 2024 10:15:32 +0000 Received: from mail-lj1-x229.google.com ([2a00:1450:4864:20::229]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.94.2) (envelope-from ) id 1sCGLA-002VLS-8T for pgsql-general@lists.postgresql.org; Wed, 29 May 2024 10:15:30 +0000 Received: by mail-lj1-x229.google.com with SMTP id 38308e7fff4ca-2e95a7545bdso20328671fa.2 for ; Wed, 29 May 2024 03:15:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bitnine-net.20230601.gappssmtp.com; s=20230601; t=1716977725; x=1717582525; darn=lists.postgresql.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=ASauxf8W+lSHYDIkWWf8PliZ6j35ccCId5gED01SsCo=; b=UKqrhgaCz2x0dfGT6VjoBXhEyIUvVM9FOxm9toEFMwt2mckhrmflLD8PzA5O/lTZmq uq4EdvKc8XJO7sBSuwQjbOxoAxNCbD+B8HHry2vzm+dUA2yL7c2IpSYrqn8hPqtbjoCq Uvj6zT2DxjFWu29RFh5KvZ64Bam2j94Ad2GR2JNOdOeaR0MpNRBtuTABPMWq1M6r+rHO 6ABaFxJy7pii03s8We/RdOnEZf/+559DFJ8UMYXN7Wzb7Q1vBOmctmobrWUFMmCBOoLJ QaqIE1B/95b4aKfkIsHCJydrtxaDyM2wlNnfycKXLVx6B2khliXHPpdK2x3pYn3jPyCS QUlg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1716977725; x=1717582525; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=ASauxf8W+lSHYDIkWWf8PliZ6j35ccCId5gED01SsCo=; b=Z4kfgIImF189z3/YSUWx+K3iilDf4xXDUwOTgqJFItAzSazvsC8HAJGWlKl1Yrvbuv oxCnUjBmx3Jf5t4mmI/ntPZHFD/uOjdT31IPQFNFiRxZcgf6WgE6nIB+u8w2yxkxaLxy Em4GROOeiCjc1D4k5I5KJDfjQOU6EdJDdCl1qt37WbiBboWounoM/Zv4XeS/lm2qpd/c pW3Bk9m4edeHe5sbZt34fdgk1rsncSTOgAS4GeBrvJ8Z7qD/6EMksg+lgK/lRY7fs7SG K61aVETWRwCdfKTD9ELz4nArmYc4MMqKMRuItTJc4LgQghyFed5RFxvrdCE4IZO7S7vF iCYw== X-Gm-Message-State: AOJu0Yxcaw+teyPCzPerZzlZ3+1Sj3jq/lf5gFcgYGKLYDf0ieFudjKR hjxd10046XJo82UTAG+0YZzg2ObIQHN1UoRO/z5xErKgA+9028+rW09d3W9eEcfIpKMOa3fF8LS Eof/pERz3eA4U+x9EjIDj4j/ZzaJbTRpJk1g0Q5yqtUY4qlR9rkg= X-Google-Smtp-Source: AGHT+IGPaP3QsA7Pdu9tvDR/osE6Kw02CD0r/CEXTZQbq9hDmwe2yt5nENPinzEYYngzLEdg2tP3wbkYpYXiecmaJa0= X-Received: by 2002:a2e:a592:0:b0:2da:49cc:ef39 with SMTP id 38308e7fff4ca-2e95af0de5cmr103818091fa.0.1716977725148; Wed, 29 May 2024 03:15:25 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: Muhammad Salahuddin Manzoor Date: Wed, 29 May 2024 15:15:11 +0500 Message-ID: Subject: Re: Unable to connect to any data source for foreign server To: Russell Mercer Cc: pgsql-general Content-Type: multipart/alternative; boundary="0000000000006528a106199507c2" List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --0000000000006528a106199507c2 Content-Type: text/plain; charset="UTF-8" Greetings, While configuring ORG_FWD. I hope you are setting path like server name and absolute path to file on your network share and network share has appropriate permissions. '\\remote_server\path\to\file.xlsx' on network share Create user mapping if required. check your config through ogr_fdw_info -s "\\\\remote_server\\path\\to\\file.xlsx" -l To diagnose the issue you can check permissions, network accessability, path format should include server name and absolute file path and any compatability issues. Regards, Salahuddin. On Wed, 29 May 2024, 14:42 Russell Mercer, wrote: > Hi, > > I'm running into a problem connecting to a foreign server with my > Postgres database. I am using the OGR_FDW trying to connect to an Excel > "XLSX". I had this database on another server, and the foreign server > was set up and working properly there. I am trying to change the path > to the file which it is referencing, and I am now receiving an error. > In addition, I tried to just create a new foreign server to that same > "XLSX" file and it also gave the error of "Failed to connect to data > source". > > I used the OGR_FDW_INfo tool to make sure I had the foreign server > reference structured correctly, but it matches what I had before, and > didn't make a difference. > > I'm a bit lost as to where to look for possible solutions. One idea I > have is that perhaps it is a permissions issue with accessing other > files on the server where Postgres is installed, with the "postgres" user. > > Some basic info: > > Server: Windows Server 2022 > PostgreSQL 16.2 - Installed using Stack Builder > > Any information or ideas as to a solution, would be very much appreciated. > > Thanks, > Russell > > > > --0000000000006528a106199507c2 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Greetings,

While configuring ORG_FWD.
I hope you are = setting path like server name and absolute path to file on your network sha= re and network share has appropriate permissions.
'\\remote_server\path\to\file.xlsx' on ne= twork share

Create user mapping i= f required.

check your c= onfig through
ogr_fdw_info -s &quo= t;\\\\remote_server\\path\\to\\file.xlsx" -l
To diagnose the issue you can check permiss= ions, network accessability, path format should include server name and abs= olute file path and any compatability issues.

Regards,
Salahuddin.

On W= ed, 29 May 2024, 14:42 Russell Mercer, <rmercer@getspatial.com> wrote:
Hi,

I'm running into a problem connecting to a foreign server with my
Postgres database.=C2=A0 I am using the OGR_FDW trying to connect to an Exc= el
"XLSX".=C2=A0 I had this database on another server, and the fore= ign server
was set up and working properly there.=C2=A0 I am trying to change the path=
to the file which it is referencing, and I am now receiving an error.=C2=A0=
In addition, I tried to just create a new foreign server to that same
"XLSX" file and it also gave the error of "Failed to connect= to data
source".

I used the OGR_FDW_INfo tool to make sure I had the foreign server
reference structured correctly, but it matches what I had before, and
didn't make a difference.

I'm a bit lost as to where to look for possible solutions.=C2=A0 One id= ea I
have is that perhaps it is a permissions issue with accessing other
files on the server where Postgres is installed, with the "postgres&qu= ot; user.

Some basic info:

Server:=C2=A0 Windows Server 2022
PostgreSQL 16.2 - Installed using Stack Builder

Any information or ideas as to a solution, would be very much appreciated.<= br>
Thanks,
Russell



--0000000000006528a106199507c2--