> > AND part.name LIKE '%green%'
>
> It's difficult for the planner to produce a decent estimate for the
> selectivity of an unanchored LIKE clause, since there are no statistics
> it can use for the purpose. We recently changed FIXED_CHAR_SEL in
> src/backend/utils/adt/selfuncs.c from 0.04 to
how do i import results of my select query to a file
thanks
---(end of broadcast)---
TIP 6: Have you searched our list archives?
http://archives.postgresql.org
\? will get you a list of the commands in psql.
Steve
> -Original Message-
> From: Joseph Syjuco [mailto:[EMAIL PROTECTED]]
> Sent: 18 July 2002 22:47
> To: [EMAIL PROTECTED]
> Subject: [SQL] how do i import my sql query result to a file
>
>
> how do i import results of my select query
On Wednesday 17 Jul 2002 3:20 am, Shmuel A. Kahn wrote:
> Assuming I have the following two tables of people and their nicknames,
> and that I want to create a list containing UPTO 2 (or any value
> greater than 1) nicknames for EACH member of a specific family (Fam
> column), how would I do this?
Hi all,
I'm still in trouble with inheritance.
Now I've created some triggers and rules for realize
something
similiar to an inheritance... I MUST do myself all the
check
for integrity, it seems the only way.
But because psql executes a function in a transaction
it was
not so bad...
In practice, i
How can I optimize Postrges SQL when I would like have ordering kolumns
without clause ORDER BY - in Oracle you can use hints to suggestion
optimizer.
for example.
SELECT /*+ INDEX_ASC TAB(TAB_PK) +/ * FROM TAB - most
efficent
SELECT * FROM TAB ORDER BY TAB_PK
where TAB_PK - is unique
You could also use describe (in psql environment )
psql mydatabase
mydatabase=# \d indexname
Index "indexname"
Attribute | Type
+---
fieldname| datatype
unique btree
The word "unique" will show up only if the index has the unique
qualification, otherwise it wi
The first thing to point out is that the estimated cost is measured in
terms of page reads while the actual time is measured in milliseconds. So
even if the cost estimate is accurate it is unlikely that those numbers
will be the same.
-N
--
Nathan C. Burnett
Research Assistant, Wisconsin Networ
Dirk,
May be you can use this
create view sesql_userindexes as
SELECT upper(c.relname) AS TBL_NAME, upper(i.relname) AS IDX_NAME,
CASE WHEN x.indisunique=false THEN 0 ELSE 1 END AS UNIQUE_FLAG, 1+
(CASE WHEN x.indkey[1]=0 THEN 0 ELSE 1 END)+(CASE WHEN x.indkey[2]=0 THEN 0 ELSE 1
END)+
(CASE W
not sure I understand the question, but from inside psql you can do:
\o FILENAMEsend all query results to file or |pipe
Robert Treat
On Thu, 2002-07-18 at 17:47, Joseph Syjuco wrote:
> how do i import results of my select query to a file
> thanks
>
>
>
>
> ---(end
Bruno,
> My suggestion:
> SELECT t3.id, coalesce(t1.name, t2.name), t1.abbreviation,
> coalesce(t1.juris_id, t2.juris_id) from
> (t3 left join t1 using (id)) left join t2 using (id);
Cool! I didn't think of that. I'll give it a try.
-Josh
---(end of broadcast)
--- Joseph Syjuco <[EMAIL PROTECTED]> wrote:
> how do i import results of my select query to a file
> thanks
>
in the psql command prompt type
\o
and then type your select query.
The result will be dumped into
ludwig.
__
Do You Yahoo!?
Yahoo!
thanks for the tips !!! actually i used \g . Again thanks
On Thu, 2002-07-18 at 20:34, Ludwig Lim wrote:
>
> --- Joseph Syjuco <[EMAIL PROTECTED]> wrote:
> > how do i import results of my select query to a file
> > thanks
> >
>
> in the psql command prompt type
> \o
>
> and then type your s
Hello all,
It might be not a correct place to post this. I am creating a table from
psql. Everything is fine except I got some troubles when trying to create
the same table but in a different way and with pgaccess.
If I have this sql:
CREATE TABLE ttt (
ID int2,
name text
> Can somebody explain me a bit about:
>
> 1. As far as I know column names in Tables are not case
> sensitive. Correct ?
> So I know if I pickup ID is not a clever idea but for this
> example it is ok.
I think your examples have proved that column names are in fact very much
case sensitive. How
I forgot about "" Sorry. So if I would use names quoted then my questions
are obsolete. Except one:
So actually the only strange part would be PostgreSQL is folding to lower
cases a column name ...
>From docs:
The folding of unquoted names to lower case in PostgreSQL is
incompatible with
16 matches
Mail list logo