SQL Query Syntax help - Mailing list pgsql-admin

From srikkanth
Subject SQL Query Syntax help
Date
Msg-id 20200122110045.14705.qmail@f4mail-235-235.rediffmail.com
Whole thread Raw
Responses Re: SQL Query Syntax help  ("Daniel Verite" <daniel@manitou-mail.org>)
Re: SQL Query Syntax help  ("Daniel Verite" <daniel@manitou-mail.org>)
Re: SQL Query Syntax help  (Geoff Winkless <pgsqladmin@geoff.dj>)
Re: SQL Query Syntax help  (Geoff Winkless <pgsqladmin@geoff.dj>)
List pgsql-admin
Hi Team,

Can you please help me in writing the syntax for the below mentioned table.

Input : 
ID Col ACol BCol CCol DCol ECol F
1111aaaabbbbccccddddeeeeffff
2222bbbbccccddddeeeeffffaaaa
3333ccccddddeeeeffffaaaabbbb
4444ddddeeeeffffaaaabbbbcccc
5555eeeeffffaaaabbbbccccdddd
6666ffffaaaabbbbccccddddeeee
7777ccccddddeeeeffffaaaabbbb
8888ddddeeeeffffaaaabbbbcccc
9999ffffaaaabbbbccccddddeeee
 
Required Output :
ID Col NameCol Value
1111Col Aaaaa
1111Col Bbbbb
1111Col Ccccc
1111Col Ddddd
1111Col Eeeee
1111Col Fffff
2222Col Abbbb
2222Col Bcccc
2222Col Cdddd
2222Col Deeee
2222Col Effff
2222Col Faaaa
3333Col Acccc
3333Col Bdddd
3333Col Ceeee
3333Col Dffff
3333Col Eaaaa
3333Col Fbbbb

And so on for the 4444, 5555, 6666, 7777, 8888, 9999


Thanks,
Srikanth B

pgsql-admin by date:

Previous
From: Laurenz Albe
Date:
Subject: Re: oldest xmin is far in the past: PG 11
Next
From: "Daniel Verite"
Date:
Subject: Re: SQL Query Syntax help