troubleshooting Question

Join multiple sql in postgresql

Avatar of Newton
Newton asked on
PostgreSQLSQL
4 Comments1 Solution115 ViewsLast Modified:
I have below 3 sql but I need 1 sql that can show all 3 result as 1 output

Sql : select current_database();
Output : dbname

Sql : select inet_server_addr();
Output : 101.99.234.20

Sql : select user;
Output : userA

Above is 3 different output but I need 1 sql that can give 1 output like below.

Output
Current_database,ip,user
Dbname, 101.99.234.20, userA

Is it possible to join these sql.
ASKER CERTIFIED SOLUTION
Join our community to see this answer!
Unlock 1 Answer and 4 Comments.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 4 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros