with template0?
Thanks.
-Nick
--
--
Nick Fankhauser
[EMAIL PROTECTED]
http://www.doxpop.com
765.965.7363
765.962.9788 (Fax)
Doxpop - Public Records at Your Fingertips.
On 8/8/07, Nick Fankhauser [EMAIL PROTECTED] wrote:
the largest containing rows.
Oops- I meant to say ...the largest containing 56 million rows.
One other question- when I'm vacuuming, I always get the warning:
WARNING: some databases have not been vacuumed in big number transactions
HINT
On 8/8/07, Tom Lane [EMAIL PROTECTED] wrote:
Nick Fankhauser [EMAIL PROTECTED] writes:
One other question- when I'm vacuuming, I always get the warning:
WARNING: some databases have not been vacuumed in big number transactions
HINT: Better vacuum them within big number transactions
at 12:07:14PM -0400, Nick Fankhauser wrote:
2) If a regular (non-full) vacuum will not reset the XID. Will a
dump/restore take care of wraparound? We have done this in the past for
space reclamation because we seem to be able to dump/restore more quickly
than we can do a full vacuum
affecting the database for all
sessions and if so, suggest a way to turn off the triggers just for the
session doing the data copy?
Thanks
-Nick
-
Nick Fankhauser
[EMAIL PROTECTED] Phone 1.765.965.7363 Fax 1.765.962.9788
Can't help with the search engine, but the answer to your question is: psql
database name.
I'd recommend starting with the tutorial in the docs for questions like
this.
http://www.postgresql.org/docs/7.3/static/tutorial-start.html
I can also confirm that the search engine in the docs area
mean it!)
-Nick
-
Nick Fankhauser
[EMAIL PROTECTED] Phone 1.765.965.7363 Fax 1.765.962.9788
doxpop - Court records at your fingertips - http://www.doxpop.com/
---(end of broadcast
-
Nick Fankhauser
[EMAIL PROTECTED] Phone 1.765.965.7363 Fax 1.765.962.9788
doxpop - Court records at your fingertips - http://www.doxpop.com/
---(end of broadcast)---
TIP 9: the planner will ignore your desire to choose an index
Oops- forgot to give the version on that last question:
I'm running version 7.3.2 on a Debian Linux platform.
-NF
-
Nick Fankhauser
[EMAIL PROTECTED] Phone 1.765.965.7363 Fax 1.765.962.9788
doxpop - Court records
AFAIK, estimating number of distinct values from a small sample is
inherently an ill-conditioned problem.
If I had been getting estimates all over the map, I'd have been a bit more
unconcerned, but what I'm seeing is a very consistent number that also
increases and tends to be more consistent
It certainly should be the case. starelid matches to pg_class.oid and
staattnum matches to pg_attribute.attnum.
My problem was that I was looking up event_date_time in pg_class.relname
(and finding it), but the oid matched nothing. when I looked for 'event' in
pg_class 'event_date_time' in
Just out of curiosity, what happens if you make it bigger than 92k?
Does a value 10x or 100x reality change the plan?
Neither one makes a change- perhaps something else is at work here- my
understanding of the finer points of query plans is shaky- Here is the query
and the plan I'm getting:
Use currval(sequence name)
See:
http://www.postgresql.org/docs/7.3/static/functions-sequence.html
-Nick
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] Behalf Of Pierre Couderc
Sent: Friday, August 29, 2003 11:27 AM
To: [EMAIL PROTECTED]
Subject: [ADMIN] How
Jodi-
Here's an example of the hack approach, which I've used without causing
any problems for some time:
update pg_attribute set atttypmod = 104
where attrelid = ( select oid from pg_class where relname = 'actor'
and attname = 'actor_full_name' );
In your case, you'd substitute 254 for 104,
In addition to making sure you do a reload to pick up the new values, make
sure that the pg_hba.conf file you are editing is in fact the one being read
by the postmaster. There have been a few situations where a symbolic link
pointing from the data directory to a conf file living somewhere else
Mago-
pg_restore is used to restore a dump file created in one of the non-text
formats such as tar format.
To restore from a plain-text dump file, just pipe it into psql like so:
cat [filename] | psql [dbname]
-Nick
-
Nick
To nit-pick, this is a useless use of cat.
In UNIX-land, simple input redirection will work much better:
psql [dbname and various options] [filename]
Good point... to elaborate further, the reason I was in a piping mindset is
that with a large database, it also makes sense to compress on
Hi Dani-
The file is nowhere near 2GB, and a regular text dump running at the same
time always completes successfuly, with a resulting file size about 4 times
what the tar-format file was when it died. Also note that this worked on the
same server using the same database using v7.2 of postgreSQL.
Olivier-
The pg_hba.conf file controls how users connect to the database, but if the
user does not have grants on the specific table within the database, I think
you'd be getting an error similar to the one you describe. Does the user you
created either have dba privileges or select access on the
prod.dump.tar is the result of pg_dump, not a command, as for
your text sample below.
pg_dump -Ft prod prod.dump.tar would be better.
Jean-Michel-
I'm sorry- that was a typo in my original post that I should have corrected.
The actual command that I'm using is in fact pg_dump -Ft prod
, so I'm not sure if it ever got worked out.
Any thoughts??
Thanks!
-Nick
-
Nick Fankhauser
[EMAIL PROTECTED] Phone 1.765.965.7363 Fax 1.765.962.9788
doxpop - Court records at your fingertips - http://www.doxpop.com
not sure if it ever got worked out.
Any thoughts??
Thanks!
-Nick
-
Nick Fankhauser
[EMAIL PROTECTED] Phone 1.765.965.7363 Fax 1.765.962.9788
doxpop - Court records at your fingertips - http://www.doxpop.com
not sure if it ever got worked out.
Any thoughts??
Thanks!
-Nick
-
Nick Fankhauser
[EMAIL PROTECTED] Phone 1.765.965.7363 Fax 1.765.962.9788
doxpop - Court records at your fingertips - http://www.doxpop.com
Does it stop at a filesize limit imposed by the OS or filesystem, such
as 2.0GB as commonly found on linux, or NFS?
No, in this case, it is stopping at about 1.3 GB uncompressed. I usually
pipe the pg_dump output into gzip but removed the gzip to simplify the
situation while testing. Under
be something odd
about the directory structure that I'm missing.
Is there a SuSe user on the list that can help?
Thanks
-Nick
-
Nick Fankhauser
[EMAIL PROTECTED] Phone 1.765.965.7363 Fax 1.765.962.9788
doxpop - Court records
be something odd
about the directory structure that I'm missing.
Is there a SuSe user on the list that can help?
Thanks
-Nick
-
Nick Fankhauser
[EMAIL PROTECTED] Phone 1.765.965.7363 Fax 1.765.962.9788
doxpop - Court records
It means you need to give that error message to your system administrator,
who will understand what it means.
If you are the system administrator, use df to learn which filesystem is
full then spend some time learning about filesystem management so you can
fix it.
-Nick
-Original
Michael-
This document should get you started:
http://www.postgresql.org/idocs/index.php?tutorial.html
look at section 1.3 in particular.
-Nick
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]]On Behalf Of Michael Cupp
Sent: Monday, January 27, 2003 11:33 AM
Helen-
There is a separate JDBC list for related questions that I suggest you use
in the future.
A code sample is needed for a really good answer, but I'll make a guess.
This message is probably telling you that you are either trying to set a
value in a where clause that has a higher index than
The preferred method is to have a PK and store it in your big table. In
addition to being more normal and probably saving a little space, this
gives you the option of changing the corresponding values in one place. So
for instance if your lookup table was datatypes, and you had entered
Sting at
Jodi-
Given you two choices, I would go for #2, but consider this third option:
Publication:
pub_id
other_stuff
Keyword:
keyword_id
keyword_text
Keyword_assignment:
pub_id
keyword_id
Keyword only contains 6 records, but you can add new keywords as needed in
the future. (Option #1 didn't give
--
Nick Fankhauser [EMAIL PROTECTED] Phone 1.765.935.4283 Fax 1.765.962.9788
Ray Ontko Co. Software Consulting Services http://www.ontko.com/
---(end of broadcast)---
TIP 1: subscribe and unsubscribe commands go to [EMAIL
You could check this by running pg_restore with query logging
turned on, to see what commands it's actually issuing -- or just do
pg_restore -s into a text file and eyeball the generated script.
I did this, and there is a view created before the table it refers to.
There are a lot of
I'm still mystified.
Any thoughts?
Thanks.
-Nick
--
Nick Fankhauser [EMAIL PROTECTED] Phone 1.765.935.4283 Fax 1.765.962.9788
Ray Ontko Co. Software Consulting Services http://www.ontko.com
Oliver-
Thanks for the idea. Unfortunately, it still won't go.
We've never touched template1, but just to make sure, I tried using
template0 to ensure an empty DB with the same results:
nickf@morgai:~$ createdb -D PG_ALPHA -T template0 test
CREATE DATABASE
nickf@morgai:~$ pg_restore -dalpha
I'm operating in Debian Woody, with PostgreSQL 7.2. -- Hugh
Hugh-
Did you install from the Debian package or compile-your-own? We're running
7.2 on Debian 2.4, and the startup/shutdown script that Oliver Elphick
created for the Debian package has worked flawlessly for us.
If you did your own
AM-
The band-aid patch is to increase the number of connections available. Check
out this link to the idocs:
http://www.postgresql.org/idocs/index.php?runtime-config.html
Maybe that will keep things running for you while you go over the code to
learn why you're using more connections now. If
If you aren't using pooled
connections, maybe you just have more users on the web.
But is there really that number of backends/connections present?
Assuming there is no connection pooling going on, then yes, it is reasonable
to assume that more users means more connections. (I don't know
Oops...
Nope, this is definitely a message from the postgresql backend.
What I *meant* to type was:
this is definitely a message from the postgresql backend referring to too
many client connections.
---(end of broadcast)---
TIP 2: you can get
Fred:
Try following this link to the interactive Doc:
http://www.postgresql.org/idocs/
This link will tell you how to allow tcp/ip access using the pg_hba.conf
file:
http://www.postgresql.org/idocs/index.php?client-authentication.html
This link will tell you how to make sure the server is
Fred-
I'm not familiar with phppgsql, so I can't help with the specific problem
there, but perhaps someone else on the list can help with the next step. You
do seem to be getting a connection at this point, but are having some sort
of authorization problem in PHP.
You may also want to try the
)
DEBUG_PRINT_PLAN (boolean)
DEBUG_PRETTY_PRINT (boolean)
Hope this helps
Phil
- Original Message -
From: Nick Fankhauser [EMAIL PROTECTED]
To: pgsql-admin [EMAIL PROTECTED]
Sent: Monday, September 23, 2002 6:05 PM
Subject: [ADMIN] logging queries
Hi-
I'd like to set the logging
if this is possible if so, what runtime settings are
needed?
Thanks
-Nick
--
Nick Fankhauser [EMAIL PROTECTED] Phone 1.765.935.4283 Fax 1.765.962.9788
Ray Ontko Co. Software Consulting Services http://www.ontko.com
Back in the days when I used Oracle, there was something called SQL*Loader
that allowed you to read a flat ASCII file into an Oracle table.
If I were doing this, I think I'd do a pg_dump of the data, filter the dump
file to remove the copy commands then use SQL*Loader or it's newer
equivalent
TIP 2: you can get off all lists at once with the unregister command
(send unregister YourEmailAddressHere to [EMAIL PROTECTED])
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]]On Behalf Of ashwini sridhar
Sent: Tuesday, July 09, 2002 8:51 PM
To:
can be found here:
http://www.postgresql.org/idocs/index.php?client-authentication.html
-Nick
--
Nick Fankhauser [EMAIL PROTECTED] Phone 1.765.935.4283 Fax 1.765.962.9788
Ray Ontko Co. Software Consulting Services
: Mark Tessier [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, July 02, 2002 1:27 PM
To: Nick Fankhauser
Cc: [EMAIL PROTECTED]
Subject: Re: [ADMIN] db connection fails
Have you tried doing a network connection with your
apache user? (su -
apache; psql -h localhost group3.)
Yes, I've
, but in Debian, you can find a log
in /var/log/postresql.log. You may have to turn on logging in
postgresql.conf.
-Nick
--
Nick Fankhauser [EMAIL PROTECTED] Phone 1.765.935.4283 Fax 1.765.962.9788
Ray Ontko Co. Software
You can set it either within the session, or set a default. For details,
check this page in the docs:
http://www.postgresql.org/idocs/index.php?sql-set.html
(Look for DATESTYLE)
Regards,
-Nick
--
Nick Fankhauser [EMAIL
]
Cc: pgsql-admin
Subject: Re: [ADMIN] Are statistics gathered on function indexes?
Nick Fankhauser [EMAIL PROTECTED] writes:
[see subject]
Nope, they ain't. I agree they should be.
Can someone tell me how the cost is estimated for retrieving a
column based
on a function that is indexed
off-list, and you can use it as
a starting point to edit again, (using a unix editor this time grin). Or
alternately, you can probably use a dos-unix filter on the old file.
Regards,
-Nick
--
Nick Fankhauser [EMAIL PROTECTED
. Is there a way to make the planner favor index scans
a bit more? (Other than the drastic set enable_seqscan to off.)
Thanks
-Nick
--
Nick Fankhauser [EMAIL PROTECTED] Phone 1.765.935.4283 Fax 1.765.962.9788
Ray Ontko Co
--
Nick Fankhauser [EMAIL PROTECTED] Phone 1.765.935.4283 Fax 1.765.962.9788
Ray Ontko Co. Software Consulting Services http://www.ontko.com/
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED
PROTECTED]
Subject: Re: [ADMIN] set permanent date style
Nick Fankhauser [EMAIL PROTECTED] writes:
in postmaster.conf, add a line that looks something like this:
PGDATESTYLE=ISO,European
I do not believe that will work in any released version. It will work
to set PGDATESTYLE
?functions.html
You may also want to learn how to create your own functions in case there is
no equivalent:
http://www.postgresql.org/idocs/index.php?sql-createfunction.html
-Nick
--
Nick Fankhauser [EMAIL PROTECTED] Phone
!)
-Nick grinning
--
Nick Fankhauser [EMAIL PROTECTED] Phone 1.765.935.4283 Fax 1.765.962.9788
Ray Ontko Co. Software Consulting Services http://www.ontko.com/
---(end of broadcast
--
Nick Fankhauser [EMAIL PROTECTED] Phone 1.765.935.4283 Fax 1.765.962.9788
Ray Ontko Co. Software Consulting Services http://www.ontko.com/
---(end of broadcast)---
TIP 5: Have you
, or simply how to make the run better in access?
Maybe if you restated the question you'd get some better responses.
-Nick
--
Nick Fankhauser [EMAIL PROTECTED] Phone 1.765.935.4283 Fax 1.765.962.9788
Ray Ontko Co
Marc-
I've just gone through some similar query optimizing work, and I can confirm
that LIKE can definitely use an index if the initial characters are supplied
as in the example you sent.
-Nick
--
Nick Fankhauser [EMAIL
Try:
ls -al /tmp
make sure the permissions on /tmp are: drwxrwxrwt
please answer in chinese
That's a skill I don't have- I hope you can work with this...
-Nick
--
Nick Fankhauser [EMAIL PROTECTED] Phone
change local to host.
-Nick
--
Nick Fankhauser [EMAIL PROTECTED] Phone 1.765.935.4283 Fax 1.765.962.9788
Ray Ontko Co. Software Consulting Services http://www.ontko.com/
-Original Message-
From: [EMAIL
Tom, Joe:
Yup, that's the standard hack.
Thanks very much! This saved us hours.
-Nick
---(end of broadcast)---
TIP 6: Have you searched our list archives?
http://archives.postgresql.org
can think of was updating
pg_attribute.atttypmod for several records last night. Could this have
caused my problem?
Any other ideas?
Thanks everyone!
-Nick
--
Nick Fankhauser [EMAIL PROTECTED] Phone 1.765.935.4283 Fax
Tom-
No Problem- we'll do that. Is there a table that contains the mapping from
the database object names to the actual filenames?
-Nick
Next time it happens, would you shut down the
postmaster and make a copy of pg_attribute and its indexes (the physical
files) to send to me, before you
= 44
where attrelid = ( select oid from pg_class where relname = 'test' )
and attname = 'oldtest' ;
Is this a smart thing to do?
Are there other hidden related bits of data that will come back to haunt us
later?
-Nick
--
Nick
Gordon-
This looks like a subject for the PSQL-ADMIN list. I'll forward it over
there, you should also look there for the response. I know that one of the
7.1-7.2 issues is that unicode chars were not checked/rejected by 7.1 if
there was no multibyte support in the compile, but you seem to have
--
Nick Fankhauser [EMAIL PROTECTED] Phone 1.765.935.4283 Fax 1.765.962.9788
Ray Ontko Co. Software Consulting Services http://www.ontko.com/
---(end of broadcast)---
TIP 3: if posting/reading through Usenet, please send an appropriate
Tom-
Thanks! your diagnosis was correct the repair worked.
-Nick Ray
I'm beginning to think there is something seriously messed up about your
installation. The simplest theory is that the indexes on pg_attribute
are corrupted.
...
You should be able to recover using REINDEX
The constraints:
http://www.postgresql.org/idocs/index.php?sql-createtable.html
regards,
-Nick
--
Nick Fankhauser [EMAIL PROTECTED] Phone 1.765.935.4283 Fax 1.765.962.9788
Ray Ontko Co. Software Consulting Services
authorization from X to Y by
trying (from X) psql -hY
regards,
-Nick
-
Nick Fankhauser
[EMAIL PROTECTED] Phone 1.765.965.7363 Fax 1.765.962.9788
doxpop - Court records at your fingertips - http://www.doxpop.com
if Apache and
Postgres are installed on the same host, but that's not the case...
I'm reinstalling the apache machine now anyway, because I don't like the
way RH installed the rpm's
Steve
-- Original Message --
Reply-To: [EMAIL PROTECTED]
From: Nick Fankhauser [EMAIL PROTECTED]
To: Steven
--
Nick Fankhauser [EMAIL PROTECTED] Phone 1.765.935.4283 Fax 1.765.962.9788
Ray Ontko Co. Software Consulting Services http://www.ontko.com/
---(end of broadcast)---
TIP 5: Have you checked our extensive FAQ?
http://www.postgresql.org/users
--
Nick Fankhauser [EMAIL PROTECTED] Phone 1.765.935.4283 Fax 1.765.962.9788
Ray Ontko Co. Software Consulting Services http://www.ontko.com/
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]]On Behalf
)
- Seq Scan on actor_case_assignment (cost=0.00..27693.03
rows=11377 width=24)
- Hash (cost=12.22..12.22 rows=522 width=48)
- Seq Scan on local_case_type (cost=0.00..12.22 rows=522
width=48)
--
Nick
Could we see the queries? (No, I do not remember your view definitions.)
Sure! I'll append the details below. (I was hoping we had correctly guessed
the cause you wouldn't need details...)
Offhand I would think that 7.2 is smart enough to deal with this
We're on 7.1.3. We're working to
select attname,attdispersion,s.*
from pg_statistic s, pg_attribute a, pg_class c
where starelid = c.oid and attrelid = c.oid and staattnum = attnum
and relname = 'actor_case_assignment';
in each database?
Here are the results:
The Before database:
attname |
In the after case you are showing 18105XS as the most common
actor_id, with a frequency of 11.2% of the entries. Where'd that
come from? Is it correct?
I believe this is correct, and the reason I've not been getting poor
performance on the old database is that the stats are not up to date
-data
while running your tests from the command line.
Hope this helps!
-Nick
--
Nick Fankhauser [EMAIL PROTECTED] Phone 1.765.935.4283 Fax 1.765.962.9788
Ray Ontko Co. Software Consulting Services http
really drags your performance down
quickly!
Regards,
-Nick
--
Nick Fankhauser [EMAIL PROTECTED] Phone 1.765.935.4283 Fax 1.765.962.9788
Ray Ontko Co. Software Consulting Services http://www.ontko.com/
-Original
Brian-
I'm not sure if this will help the performance, but I believe this statement
is equivalent:
update v set nl=nl+1 where exists (select 'x' from l where l.sid = v.id and
l.did = 123456);
-Nick
--
Nick Fankhauser
be close.
-Nick
--
Nick Fankhauser [EMAIL PROTECTED] Phone 1.765.935.4283 Fax 1.765.962.9788
Ray Ontko Co. Software Consulting Services http://www.ontko.com/
-Original Message-
From: [EMAIL PROTECTED
I know I'm about to become a pest, but I promise, this is a short one!
Before doing the explain below, I specifically did a verbose analyze noted
that the results seemed in line with what I expected. I'm on v7.1.3 of PGSQL
Here's the query that runs too slow: (It takes about 30 seconds on a
--
Nick Fankhauser [EMAIL PROTECTED] Phone 1.765.935.4283 Fax 1.765.962.9788
Ray Ontko Co. Software Consulting Services http://www.ontko.com/
---(end of broadcast)---
TIP 2: you can get off
/postgresql
restart
5)Initialize the database location: (su - postgres; initlocation PG_STAGING)
6)Create the database: (createdb staging -D PG_STAGING)
Regards,
-Nick
--
Nick Fankhauser [EMAIL PROTECTED] Phone 1.765.935.4283
--
Nick Fankhauser [EMAIL PROTECTED] Phone 1.765.935.4283 Fax 1.765.962.9788
Ray Ontko Co. Software Consulting Services http://www.ontko.com/
---(end of broadcast)---
TIP 1: subscribe
puzzling, why does the planner
choose an index that involves actor_id?
Many thanks to those of you who read through all of this! Any suggestions?
-Nick
--
Nick Fankhauser [EMAIL PROTECTED] Phone 1.765.935.4283 Fax 1.765.962.9788
That seems strange to me also, particularly if the index column ordering
is indeed actor_id,case_id and not the other way round
Tom-
Actually, it *is* the other way around- I didn't realize that could make a
difference. Here's the line that creates it:
create unique index
Tom Lane wrote:
The only reason the planner should choose a single-column index over
using the first column of a multi-column index is that the latter index
is likely to be physically larger and thus require more I/O to access.
So, there's no penalty in the cost calculations other than the
/index.php?runtime-config.html
You should also consider the upgrade to a newer version of postgresql- the
advantages are significant.
-NickF
--
Nick Fankhauser [EMAIL PROTECTED] Phone 1.765.935.4283 Fax 1.765.962.9788
Ray Ontko
Jodi-
Have you tried turning autocommit off doing a single commit after the
load?
-NickF
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]]On Behalf Of Jodi Kanter
Sent: Wednesday, March 20, 2002 2:19 PM
To: Postgres Admin List
Subject: [ADMIN] slow inserts
I am
Pipe it into gzip:
pg_dump db_name|gzipdbname.sql.gz
NickF
--
Nick Fankhauser [EMAIL PROTECTED] Phone 1.765.935.4283 Fax 1.765.962.9788
Ray Ontko Co. Software Consulting Services http://www.ontko.com
--
Nick Fankhauser [EMAIL PROTECTED] Phone 1.765.935.4283 Fax 1.765.962.9788
Ray Ontko Co. Software Consulting Services http://www.ontko.com/
---(end of broadcast)---
TIP 3: if posting/reading through Usenet, please send an appropriate
...
I'm running PGSQL 7.1.3 and Debian Linux 2.4.14 on an Athlon 1.4Ghz box with
512MB RAM IDE drives.
Any thoughts appreciated- I'm trying to decide whether I should cancel the
vacuum do an autopsy.
-NF
--
Nick Fankhauser
happened before trying a
restart?
I'm running PGSQL 7.1.3 on Debian Linux 2.4.14
Thanks-
-Nick
--
Nick Fankhauser [EMAIL PROTECTED] Phone 1.765.935.4283 Fax 1.765.962.9788
Ray Ontko Co. Software Consulting Services
Is the vacuum actually running (accumulating any CPU time)? Or is it
just waiting on a lock held by one of those other guys?
After a little blip at startup, it stops using CPU. Here's a snippet of the
ps:
21966 pts/0S 0:00 /bin/sh /usr/lib/postgresql/bin/vacuumdb temp
21971 pts/0
Chris-
This thread from Darwin might help you identify someone who is in the know
about shared memory:
http://www.darwinfo.org/devlist.php3?number=1385
-Nick
--
Nick Fankhauser [EMAIL PROTECTED] Phone 1.765.935.4283
to new using insert
into table newtable (col1,col2) values (select col1,col2 from oldtable);
-Nick
--
Nick Fankhauser [EMAIL PROTECTED] Phone 1.765.935.4283 Fax 1.765.962.9788
Ray Ontko Co. Software Consulting Services
--
Nick Fankhauser [EMAIL PROTECTED] Phone 1.765.935.4283 Fax 1.765.962.9788
Ray Ontko Co. Software Consulting Services http://www.ontko.com/
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]]On Behalf Of Rasmus Mohr
Sent: Wednesday
This my be simpler than the answer you were after, but...
If you're getting something like cannot insert duplicate key into unique
index fred, you could type: \d fred at a psql prompt to learn what
column(s) fred refers to. You can learn even more by digging into the system
tables, but I'll
I should have just given you this example in my earlier reply- this is how I
quickly get a batch of grant statements- you can probably modify it for your
needs:
select 'grant select on '||relname||'to www-data;' from pg_class where
relname not like 'pg%';
-Nick
-Original Message-
1 - 100 of 124 matches
Mail list logo