My first guess is that
NULL fails the condition on your WHERE clause,
p.id_line = 1
So your WHERE clause introduces an additional level of filtering that
filters out the NULLs coming from the LEFT JOIN...
Didn't do any tests, it's just a guess...
Best,
Oliveiros
- Original Message -
Message -
From: Louis-David Mitterrand vindex+lists-pgsql-...@apartia.org
To: pgsql-sql@postgresql.org
Sent: Friday, February 12, 2010 11:57 AM
Subject: Re: [SQL] left join not working?
On Fri, Feb 12, 2010 at 11:35:02AM -, Oliveiros C, wrote:
My first guess is that
NULL fails
Darrell,
Can you provide a little more information and background on your problem.
please?
What values can the tag column assume? Just a and b ?
Both?
Please give examples of table contents and desired output, your mail doesn't
contain enough info to give you more advises
Thank you
Dear All,
I have a table with host names and some happen to be numeric IPs.
I would like to be able to filter out the later.
Is there any function pre-defined in the system that can test a particular text
type value to see if it is a numeric ip?
Something that returns true if applied to
subjects like pgplsql not to
mention regular expressions
Thanx a lot for your fast help,
Best,
Oliveiros
- Original Message -
From: Alvaro Herrera alvhe...@commandprompt.com
To: Oliveiros C, oliveiros.crist...@marktest.pt
Cc: pgsql-sql@postgresql.org
Sent: Friday, December 11, 2009
appearing more than once...
It's basically that...
Hope this helped
Best,
Oliveiros
- Original Message -
From: Another Trad
To: Oliveiros C,
Cc: pgsql-sql@postgresql.org
Sent: Wednesday, November 18, 2009 5:37 PM
Subject: Re: [SQL] need nelp with aggregate functions
ok, I
Try substituting the SELECT count(c) as qtd_client,count(cm) as qtd_computers
by
SELECT count( DISTINCT c.cliente_id) as qtd_client,count(/* put here the
primary key of the computer table */ ) as qtd_computers
Then tell me if it output what you want
Best,
Oliveiros
- Original Message
,
Oliveiros
- Original Message -
From: Tom Lane t...@sss.pgh.pa.us
To: Oliveiros C, oliveiros.crist...@marktest.pt
Cc: Adrian Klaver akla...@comcast.net; pgsql-sql@postgresql.org
Sent: Monday, October 19, 2009 6:32 PM
Subject: Re: [SQL] How to order varchar data by word
Oliveiros C
- Original Message -
From: Adrian Klaver akla...@comcast.net
To: Oliveiros C, oliveiros.crist...@marktest.pt
Cc: Tom Lane t...@sss.pgh.pa.us; pgsql-sql@postgresql.org
Sent: Tuesday, October 20, 2009 2:46 PM
Subject: Re: [SQL] How to order varchar data by word
On Tuesday 20 October 2009 6:39:23
Message -
From: Adrian Klaver akla...@comcast.net
To: pgsql-sql@postgresql.org
Cc: Oliveiros C, oliveiros.crist...@marktest.pt
Sent: Wednesday, October 14, 2009 9:54 PM
Subject: Re: [SQL] How to order varchar data by word
On Wednesday 14 October 2009 7:13:22 am Oliveiros C, wrote:
Hello
Hello, list.
I have a table with a varchar field that I would like to order by word, not by
ordinal, which seems to be the default on postgres.
Does anyone have a clue on how this can be done?
Many thanx in advance,
Best,
Oliveiros
Hello, Gary.
thank you for your e-mail
This is a slightly modified version of the query I sent you on first place
(have you tried it out?).
It will return (I hope :) the full orders record plus the maximum
ol_timestamp and respective o_user.
HTH
Best,
Oliveiros
SELECT subquery.*,
You mean
to list the complete orders table and for each of its records, the
corresponding record on the orders_log with the latest ol_timestamp?
SELECT *
FROM orders_log main
JOIN
(
SELECT orders.*, MAX(orders_log.ol_timestamp) as latest
FROM orders
NATURAL JOIN orders_log
GROUP BY orders.*
Message -
From: Oliveiros C, oliveiros.crist...@marktest.pt
To: Gary Stainburn gary.stainb...@ringways.co.uk;
pgsql-sql@postgresql.org
Sent: Thursday, September 24, 2009 6:17 PM
Subject: Re: [SQL] simple (?) join
You mean
to list the complete orders table and for each of its records
Dear All,
I have a table which has a field that is of type bit varying.
When I do a direct INSERT with , say, X'1F', everything
works fine.
But in this table I have to insert several tens of thousands
of records each time, so I decided to use
COPY command.
And if I build a file like this
15 matches
Mail list logo