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 1rqDu0-00BG3y-CT for pgsql-odbc@arkaria.postgresql.org; Fri, 29 Mar 2024 15:12:20 +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 1rqDty-002J95-LR for pgsql-odbc@arkaria.postgresql.org; Fri, 29 Mar 2024 15:12:18 +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 1rqDty-002J8x-9y for pgsql-odbc@lists.postgresql.org; Fri, 29 Mar 2024 15:12:18 +0000 Received: from mail-ed1-x530.google.com ([2a00:1450:4864:20::530]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.94.2) (envelope-from ) id 1rqDtt-0074IN-Uk for pgsql-odbc@postgresql.org; Fri, 29 Mar 2024 15:12:16 +0000 Received: by mail-ed1-x530.google.com with SMTP id 4fb4d7f45d1cf-56c36f8f932so5426068a12.0 for ; Fri, 29 Mar 2024 08:12:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1711725132; x=1712329932; darn=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=WzD9/COMI37y5fYyzxQKav+ond/S44v76JKYZacU4PA=; b=cssTUHMn5Ow8bEbE5zFIHKFS66vA9oIeVx9561C9pvpzAyJz15o0mFDGh36NpEgpnx teNPyKuw/XBe0k/m0pkMPY/SE4TF4bilxAjgq5k7J9FwmPIi7JuSeGcOQa8ewvTd2TeH UXvoUHCMIVruwoimjvDw5cvQGHQDZEfYUyZcFlrOnIs9xhm9fXsOJrIF+p2yM7XN8wfA s+WsejO98RKSNDjGVpncZd2k4L1/rw1uuoV/+531FDd1rxE4Bh1TsgeFLGGAGxESN8wY e7As3rGXbLY3Zaotj5Whbog/i6XbPfAHgvZD4U14CVa33C7FEsPAPx6ZDhxmi+zimqWd d9vw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1711725132; x=1712329932; 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=WzD9/COMI37y5fYyzxQKav+ond/S44v76JKYZacU4PA=; b=tMytu5BsyD9Z4/ImUnWn6VMyEzakEAuznzjuyKBnSCMrZ0fNnkjQF/KrcDAI+kXoVk DZqNvNUa4HwNoneoChu8/kC38hWYnhQzEE1/LN0lM1PytFT1CW3NmCXaArBFeVWEV2dB oalhjgm/FR/ldu0brTOFB9oLi4Z7JaOLvJY4iWynjgBYaZZQ5/uTm3oU08pa8a3IiFph V1EoNSbf7C/jFxrlh7xyx4/03V5O2ABXdtolKajNNtbG0Qh3fMfIMaFcPScd/BmUkNJL kzT+EMa58FXgo4C8OnIGA0Woru4hRQpzdCniO19MKhmWYnxhmjOofJHe2azuX4pzxAU6 urPQ== X-Gm-Message-State: AOJu0YyYeukVaKEvmj9U7LuWFeOjAHBByarUxZII6EvDxOcgI1nHleAR NmsXjwMO+RxdBri5zpIGfEzcHavHbMBE/JiTAGUuGVcZ+LhFKmyca6w+HxgdGb9Sz3Vm3VLCRRI MvLdjXVJ9Ve82xQIMYF0uw1aRbN0= X-Google-Smtp-Source: AGHT+IFzkXOpyaOHnSt4hcUaTHj8LMgTJ0STY5lPT1DPQf24RyrsrazEpy7NuMJx2STr7zZ4tNUiSDtjzkxBXy0p9Wo= X-Received: by 2002:a17:906:57d7:b0:a46:ed72:6bba with SMTP id u23-20020a17090657d700b00a46ed726bbamr2373828ejr.18.1711725132127; Fri, 29 Mar 2024 08:12:12 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: Dave Cramer Date: Fri, 29 Mar 2024 11:11:54 -0400 Message-ID: Subject: Re: How to create an ODBC datasource in CI To: Jon Raiford Cc: PostgreSQL mailing lists Content-Type: multipart/alternative; boundary="0000000000007423000614ce1098" List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --0000000000007423000614ce1098 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Fri, 29 Mar 2024 at 08:41, Jon Raiford wrote: > I=E2=80=99m not familiar with GitHub Actions, but I know you can create d= ata > sources from the command line. This is all stored in the registry, which > you can update using the reg command. > > > > > https://learn.microsoft.com/en-us/windows-server/administration/windows-c= ommands/reg > > > > The easiest thing to do may be to create a data source manually and expor= t > it into a .reg file. You can then either import the data source using the > reg file or just use it as a template to add the entries as you like. > > > Just run Regedit and locate the data source you would like to export. > > > > 64-bit System Data Sources: \\HKLM\SOFTWARE\ODBC\ > > > 32-bit System Data Sources: \\HKLM\SOFTWARE\WOW6432Node\ODBC\ > > > 64-bit User Data Sources: \\HKCU\SOFTWARE\ODBC\ > > 32-bit User Data Sources: \\HKCU\SOFTWARE\ODBC\ > <- This is mixed in with the 64-bit > entries and the driver referenced determines if 32/64 > > > > Drivers are defined under the system keys under the section ODBCINST.INI. > Data sources are defined under the section ODBC.INI, both as a folder > containing the details of the data source as well as an entry under > =E2=80=9CODBC.INI\ODBC Data Sources=E2=80=9D, which associates the data s= ource with the > driver to use with it. > > > > I think if you view these entries in Regedit you will see the > relationships between everything. It may help to create a data source for > each type. > > > > The above describes how to create a static ODBC data source. Alternativel= y > you can use a file DSN or simply make a connection string from your test > case and avoid the data source completely. Although I suppose you may wan= t > to do each in order to test each possibility. > > > > Let me know if you have any questions or need assistance. > > > > Jon > Hey Jon, Thanks, that will help immensely. It's been a while since I've done anything with Windows. Dave > > > > > *From: *Dave Cramer > *Date: *Friday, March 29, 2024 at 7:25=E2=80=AFAM > *To: *PostgreSQL mailing lists > *Subject: *How to create an ODBC datasource in CI > > Greetings, > > > > In order to test the driver using github actions we need to be able to > create a windows datasource. Usually this requires some kind of user > interaction. > > > > Has anyone done this on GH actions ? > > > > > Dave Cramer > --0000000000007423000614ce1098 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable


=
On Fri, 29 Mar 2024 at 08:41, Jon Rai= ford <raiford@labware.com>= wrote:

I=E2=80=99m not famil= iar with GitHub Actions, but I know you can create data sources from the co= mmand line. This is all stored in the registry, which you can update using = the reg command.

=C2=A0<= /span>

https://learn.microsoft.com/en-us/windows-server/adminis= tration/windows-commands/reg

=C2=A0<= /span>

The easiest thing to = do may be to create a data source manually and export it into a .reg file. = You can then either import the data source using the reg file or just use i= t as a template to add the entries as you like.


Just run Regedit and locate the data source you would like to export.

=C2=A0<= /span>

64-bit System Data So= urces: \\HKLM\SOFTWARE\ODBC\

32-bit System Data So= urces: \\HKLM\SOFTWARE\WOW6432Node\ODBC\

64-bit User Data Sour= ces: \\HKCU\SOFTWARE\ODBC\

32-bit User Data Sour= ces: \\HKCU\SOFTWARE\ODBC\=C2=A0=C2=A0=C2=A0=C2=A0 <- This is mixed in wi= th the 64-bit entries and the driver referenced determines if 32/64<= u>

=C2=A0<= /span>

Drivers are defined u= nder the system keys under the section ODBCINST.INI. Data sources are defin= ed under the section ODBC.INI, both as a folder containing the details of t= he data source as well as an entry under =E2=80=9CODBC.INI\ODBC Data Sources=E2=80=9D, which associates the d= ata source with the driver to use with it.

=C2=A0<= /span>

I think if you view t= hese entries in Regedit you will see the relationships between everything. = It may help to create a data source for each type.

=C2=A0<= /span>

The above describes h= ow to create a static ODBC data source. Alternatively you can use a file DS= N or simply make a connection string from your test case and avoid the data= source completely. Although I suppose you may want to do each in order to test each possibility.

=C2=A0<= /span>

Let me know if you ha= ve any questions or need assistance.

=C2=A0<= /span>

Jon

<= /div>

Hey Jon,

Thanks, that will help immensely.

It's been= a while since I've done anything with Windows.

Dave=C2=A0

=C2=A0<= /span>

=C2=A0<= /span>

From: Dave Cramer <davecramer@gmail.com>
Date: Friday, March 29, 2024 at 7:25
=E2=80=AFAM
To: PostgreSQL mailing lists <pgsql-odbc@postgresql.org>
Subject: How to create an ODBC datasource in CI
=

Greetings,

=C2=A0

In order to test the driver using github actions we = need to be able to create a windows datasource. Usually this requires some = kind of user interaction.

=C2=A0

Has anyone=C2=A0done this on GH actions ?<= /u>

=C2=A0


Dave Cramer

--0000000000007423000614ce1098--