pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Alok Thakur <alokthakur1987@gmail.com>
To: pgsql-sql@postgresql.org
Subject: sql query problem
Date: Sat, 14 Jan 2012 01:18:17 -0800 (PST)
Message-ID: <5ec02ff4-d24b-4824-8116-5445262a6a61@lr19g2000pbb.googlegroups.com> (raw)

Dear All,

I have two tables one contains details of user and other contains
result. The details are:
1. UserTable - id, name, phone
2. result - id, question_id, user_id, status (0 or 1)

I want the list like this:
User Id   Name   Attended   Failed   Passed

but i could not find the way to do this.

Please help



view thread (14+ messages)  latest in thread

Message-ID: <5ec02ff4-d24b-4824-8116-5445262a6a61@lr19g2000pbb.googlegroups.com>
Permalink:  ../5ec02ff4-d24b-4824-8116-5445262a6a61@lr19g2000pbb.googlegroups.com/
Also on:    postgresql.org/message-id/5ec02ff4-d24b-4824-8116-5445262a6a61@lr19g2000pbb.googlegroups.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-sql@postgresql.org
  Cc: alokthakur1987@gmail.com
  Subject: Re: sql query problem
  In-Reply-To: <5ec02ff4-d24b-4824-8116-5445262a6a61@lr19g2000pbb.googlegroups.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox