Re: [SQL] Presenting data in 5 Rows & 5 Cols for 25 specific values

2013-08-04 Thread Rob Sargentg
On 08/03/2013 07:26 AM, F Bax wrote: I have a table containing tasks completed in a game I'm playing. The game includes an extra BINGO Challenge where each cell of standard BINGO card contains a particular task to be completed. The goal is score a BINGO (row, column, diagonal) by completing f

Re: [SQL] Presenting data in 5 Rows & 5 Cols for 25 specific values

2013-08-03 Thread Rob Sargentg
On 08/03/2013 07:26 AM, F Bax wrote: I have a table containing tasks completed in a game I'm playing. The game includes an extra BINGO Challenge where each cell of standard BINGO card contains a particular task to be completed. The goal is score a BINGO (row, column, diagonal) by completing f

Re: [SQL] \copy multiline

2012-11-29 Thread Rob Sargentg
On 11/29/2012 02:33 AM, Guillaume Lelarge wrote: On Wed, 2012-11-28 at 21:21 -0600, Seb wrote: Hi, I use \copy to output tables into CSV files: \copy (SELECT ...) TO 'a.csv' CSV but for long and complex SELECT statements, it is cumbersome and confusing to write everything in a single line, an

Re: [SQL] How to compare two tables in PostgreSQL

2012-11-11 Thread Rob Sargentg
On 11/10/2012 08:13 PM, saikiran mothe wrote: Hi, How can i compare two tables in PostgreSQL. Thanks, Sai Compare their content or their definition? -- Sent via pgsql-sql mailing list (pgsql-sql@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-sq

Re: [SQL] How to Return Table From Function

2012-01-22 Thread Rob Sargentg
On 01/22/2012 06:09 AM, Rehan Saleem wrote: hi , i have created this function CREATE OR REPLACE FUNCTION totaloverlapcount(user_id integer , bg integer ,center_distance integer) RETURNS varchar AS $$ DECLARE percentage record; BEGIN select fname, lname, count(userid) totalcount ,100.00*co