Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1merdB-0003CO-Tt for pgadmin-hackers@arkaria.postgresql.org; Mon, 25 Oct 2021 04:30:42 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1merdA-0004xu-P2 for pgadmin-hackers@arkaria.postgresql.org; Mon, 25 Oct 2021 04:30:40 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1merdA-0004xl-Iy for pgadmin-hackers@lists.postgresql.org; Mon, 25 Oct 2021 04:30:40 +0000 Received: from mail-ua1-x936.google.com ([2607:f8b0:4864:20::936]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1merd8-0004IM-1W for pgadmin-hackers@lists.postgresql.org; Mon, 25 Oct 2021 04:30:39 +0000 Received: by mail-ua1-x936.google.com with SMTP id f24so362085uav.12 for ; Sun, 24 Oct 2021 21:30:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=Lg8gxMJFaIn/f6s2wgcap63YHrcS/6OzJ05BtLtDZNQ=; b=lcZFJYtMj0ukCHf0eotlWGxCwVuZZovl4otocKGFqPXxKXmuscv8sIPf1FLdrVqDZ/ Ghixm1MJAi08LpnBEL513OO5UCz6DUwwxUl3Jf3yzZo9uBCyqYKpT0O0HmbC4RY8AaUi Tj3+PW1XNB1+jMn5f3FLF3DF+Eb7d6k2+5whyxWXtvh3Z9EhuulNdm+AdblEnmFQoKw1 5BlnBIxESxNW8K7SNwFY1qoT8h4w6OS+XQDNg3M9XWqIolMK+zr0jm6aA/3UFWVBmyJr tQ2ghNVr+qgRGbt+kX6s/hAzOmSjcOJaaUc54OeU+8mcmOTo/Lnikk1CkYWHial8V9SQ Jrcg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=Lg8gxMJFaIn/f6s2wgcap63YHrcS/6OzJ05BtLtDZNQ=; b=h6gu/3l9Re66ip1PdGJ/1PvSrTS0pvsRqz/sDwQG5mkfNut+RA1wuiqJhiAYkOTNAZ 6oAum9Ky4EePM0+cdRmUxZhgzl85mVL3yCAHFsbi6BdKeA+fXZtnPZ/W3OFQl4yt7NBO kRZos53C28f2dgXtacdV3KuVKBOzhhpgCA3LJktp21tqJm0xqZf2vYfTs6LaAEJwutNc +ow9ehOBjYbklgeCdoHbj7AvxDLRXFFrnU7PYY8UvZKe1uxLE8tQC88YUiALEVqQ5NGl mNBAfnnpIIpD1g8jgxqtUU1tCa3VepCFHSlp75b2coFtEwYK/gUzbXAGa5XElEIZoqOW 8EJQ== X-Gm-Message-State: AOAM533cxYuNj9coxG/Rb/WBr2Kt9+X3Qm5om+EeUwezRJgMdOXKcBJA YLTjdDC6yJzIiE+IglcRusoEKJr/ZC4QTnUqqf0= X-Google-Smtp-Source: ABdhPJxxzsbaGqfPD4emxnn/gLQiBK1J1vhqKe2U2kcjrGTblk7UqRgs8jQinyu/2m196CQSYWZGpDHVHrxsW3m4wG0= X-Received: by 2002:a67:be1a:: with SMTP id x26mr4950784vsq.17.1635136237119; Sun, 24 Oct 2021 21:30:37 -0700 (PDT) MIME-Version: 1.0 References: <62ACFF92-59AF-4F55-953B-BAFC767FCED7@gmail.com> In-Reply-To: From: Sanchari Biswas Date: Mon, 25 Oct 2021 00:30:24 -0400 Message-ID: Subject: Re: Conditional Tables Feature on PostGresSQL To: Aditya Toshniwal Cc: pgadmin-hackers Content-Type: multipart/alternative; boundary="00000000000092add505cf25d279" List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --00000000000092add505cf25d279 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hi Aditya, Can we use variables in any column and then have (Boolean) constraints over the variables? Eg. x as a variable value and then corresponding condition (x =E2=89=A0 5 |= | x =E2=89=A0 10). So that this condition is satisfied when queried with values of column (with variable x) other than the above two and the condition converts to actual constant values, and returns tuples with that actual value. Thanks, Sanchari. On Mon, Oct 25, 2021, 12:11 AM Aditya Toshniwal < aditya.toshniwal@enterprisedb.com> wrote: > Hi Sanchari, > > You can use the query tool to write anonymous blocks. Else, can you pleas= e > explain with an example what exactly is the requirement ? > > On Fri, Oct 22, 2021 at 10:05 PM Sanchari Biswas (Shrina) < > sanchari.shrina@gmail.com> wrote: > >> Hello, >> >> Is there any existing feature that enables the use of conditional tables >> on PostGreSQL, specifically the usage of variables, and implementing tho= se >> variables in our (complex) queries? >> >> Thanks, >> Sanchari. >> >> > > -- > Thanks, > Aditya Toshniwal > pgAdmin Hacker | Software Architect | *edbpostgres.com* > > "Don't Complain about Heat, Plant a TREE" > --00000000000092add505cf25d279 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Hi Aditya,

Can we = use variables in any column and then have (Boolean) constraints over the va= riables?
Eg. x as a variable value and then correspo= nding condition (x =E2=89=A0 5 || x =E2=89=A0 10).
S= o that this condition is satisfied when queried with values of column (with= variable x) other than the above two and the condition converts to actual = constant values, and returns tuples with that actual=C2=A0value.

Thanks,
San= chari.

On Mon, Oct 25, 2021, 12:11 AM Aditya Toshniwal <aditya.toshniwal@enterprise= db.com> wrote:
H= i Sanchari,

You can use the query tool to write anonymous blocks. Else= , can you please explain with an example what exactly is the requirement ?<= /div>

On Fri, Oct 22, 2021 at 10:05 PM Sanchari Biswas (Shrina) <= sanchari.shrina@gmail.com> wrote:
Hello,

Is there any existing feature that enables the use of conditional tables on= PostGreSQL, specifically the usage of variables, and implementing those va= riables in our (complex) queries?

Thanks,
Sanchari.



--
Thanks,
Aditya Toshniwal=
pgAdmin Hacker=C2=A0| Software Architect=C2=A0| = edbpostgres.com
"Don't Complain about Heat, Plant a TREE"
--00000000000092add505cf25d279--