hi,
I recently did a dist-upgrade from sarge to etch on a server with a
bunch of postgresql databases (7.4.9). Many of these had encoding set
as unicode and contained a lot of unicode data. After the dist-
upgrade, I find some of these databases are now encoded as latin1 -
and I cannot pro
On 02-Aug-07, at 2:49 AM, Judith wrote:
I'm trying in SUSE to connect to a postgres db and this is the error:
Ident Authentification failed for user <>
I'm already created the user with createuser root, but the error
persist, I would aprecciate some help, thanks in advanced
edit your
On 15-May-07, at 2:39 PM, Richard Huxton wrote:
Don't know of one - not sure what "workday" would mean in a global
sense. I mean, Mon-Fri in most European office settings, but you'd
include Sat in retail settings and in Islamic countries presumably
exclude Fridays. Our local library shuts
hi,
am migrating a database from MSSQL to postgres. How would i migrate
this:
[Id] [numeric](18, 0) IDENTITY (1, 1)
--
regards
Kenneth Gonsalves
Associate, NRC-FOSS
[EMAIL PROTECTED]
http://nrcfosshelpline.in/web/
---(end of broadcast
hi,
am migrating a database from MSSQL to postgres. How would i migrate
this:
[Id] [numerc](18, 0) IDENTITY (1, 1)
--
regards
kg
http://lawgon.livejournal.com
http://nrcfosshelpline.in/web/
---(end of broadcast)---
TIP 9: In versions below
On Wednesday 26 Oct 2005 11:52 am, Bath, David wrote:
> > This guy is not worth arguing with.
> D'Accord!
thanks all for the clarification. in case anyone is interested in the
original conversation it is here:
http://ebergen.net/wordpress/?p=83
--
regards
kg
http://www.livejournal.com/users/
hi,
i was in a minor flame war with a mysql guy - his major grouse was that
'I wouldnt commit mission critical data to a database that needs to be
vacuumed once a week'. So why does pg need vacuum?
--
regards
kg
http://www.livejournal.com/users/lawgon
tally ho! http://avsap.org.in
ಇಂಡ್ಲಿನಕ್ಸ வா
On Sunday 02 Oct 2005 4:02 am, brett wrote:
> This is my first posting here, please forgive me if I make any
> mistakes here.
thought your question was dead simple. worked on the answer for hours at
end. learnt a lot of sql, but couldnt solve it. Looks like a solution
is out. All i can say is -
On Thursday 29 Sep 2005 11:47 am, [EMAIL PROTECTED] wrote:
> please take me out from this group.
ask the guy who put you in the group to do it
--
regards
kg
http://www.livejournal.com/users/lawgon
tally ho! http://avsap.org.in
ಇಂಡ್ಲಿನಕ್ಸ வாழ்க!
---(end of broadcast)-
On Wednesday 31 Aug 2005 6:49 pm, Zac wrote:
> su - postgres -c "psql --dbname database --command \"UPDATE users
> SET pin=12345 WHERE login='admin';\""
works - good thing to know
--
regards
kg
http://www.livejournal.com/users/lawgon
tally ho! http://avsap.org.in
ಇಂಡ್ಲಿನಕ್ಸ வாழ்க!
On Wednesday 31 Aug 2005 6:43 pm, [EMAIL PROTECTED] wrote:
> After entering the statement that way my console hangs and only
> ctrl-d gets it working again.
the problem is that the quotes round 'admin' are needed to tell psql
that this is a value - but i have no idea how to create the quotes
on
On Wednesday 31 Aug 2005 6:24 pm, [EMAIL PROTECTED] wrote:
> The error is :
>
> column "admin" doesn`t exist
try \'admin\'
--
regards
kg
http://www.livejournal.com/users/lawgon
tally ho! http://avsap.org.in
ಇಂಡ್ಲಿನಕ್ಸ வாழ்க!
---(end of broadcast)-
On Wednesday 31 Aug 2005 6:00 pm, dIGITx wrote:
> su - postgres -c 'psql --dbname database --command "UPDATE users
> SET pin=12345 WHERE login='admin';"'
works for me - what is the error you are getting?
--
regards
kg
http://www.livejournal.com/users/lawgon
tally ho! http://avsap.org.in
ಇಂಡ್ಲಿನ
On Wednesday 31 Aug 2005 3:30 pm, Joost Kraaijeveld wrote:
> Hi,
>
> I want to copy several columns of a source table from db1 to db2,
> and create the target table and rename the columns in the process.
>
> Is that possible in PostgresQL? If so, an example or url for such a
> command /script would
On Thursday 18 Aug 2005 8:26 am, Premsun Choltanwanich wrote:
> Dear All,
>
> I need to distribute my application that use PostgreSQL as
> database to my customer. But I still have some questions in my mind
> on database security. I understand that everybody who get my
> application database
On Tuesday 09 Aug 2005 12:11 am, Haris Saybasili wrote:
> Hi everybody,
>
> I have two databasese: database1 and database2. I want to set a
> trigger on a table of database1 which will insert some values to a
> table of database2.
>
> Is it possible with postgresql? How can I find detailed informat
On Friday 15 Jul 2005 2:18 pm, Richard Huxton wrote:
> Sorry if this isn't as much help as you'd like, but you'll need to
> give more detail if you want a more detailed answer.
looks like he needs the details for a project/report
--
regards
kg
http://www.livejournal.com/users/lawgon
tally ho! h
On Friday 08 Jul 2005 12:02 pm, Ramakrishnan Muralidharan wrote:
>I have assuemed that the row will having eighter Debit account
> or Credit account, the following Query will give sum of debit and
> credit accounts
>
>SELECT SUM( CASE WHEN COALESCE( DEBIT , 0 ) <> 0 THEN
> COALESCE( AMOU
this guy is still polluting this list:
-- Forwarded Message --
Subject: RE: [SQL] two sums in one query
Date: Friday 08 Jul 2005 11:33 am
From: AntiSpam UOL <[EMAIL PROTECTED]>
To: lawgon <[EMAIL PROTECTED]>
http://antispam.uol.com.br";
style=
hi
i have a table like this:
serialno varchar,
debit integer,
credit integer,
amount numeric
the columns 'debit' and 'credit' refer to the acount number. I want to
query the table to select all the rows where either debit = account
or credit=account and to get two sums - one of the amounts wher
On Tuesday 21 Jun 2005 8:50 pm, MRB wrote:
> I'm working with a lot of data from MySQL where the MySQL ENUM type
> is used.
just a thought - it took me five years after migrating from mysql to
pg to start thinking like an sql programmer. I used to keep trying to
write stuff for pg 'like' i used
hi,
in a table with a serial datatype, how do i get the sequence to start
at a specific number like 10?
--
regards
kg
http://www.livejournal.com/users/lawgon
tally ho! http://avsap.org.in
ಇಂಡ್ಲಿನಕ್ಸ வாழ்க!
---(end of broadcast)---
TIP 7: don't
On Friday 17 Jun 2005 8:46 am, Michael Fuhr wrote:
> The autoreplies mentioned in these threads are still happening:
>
> http://archives.postgresql.org/pgsql-sql/2005-06/msg00102.php
> http://archives.postgresql.org/pgsql-sql/2005-06/msg00097.php
>
> I can tweak my filters to drop the autoreplies,
hi
i have a table with a varchar field called 'name'. I want postgres to
reject any insert with characters defined as illegal characters, for
example '*/^#'. How do i do this?
--
regards
kg
http://www.livejournal.com/users/lawgon
tally ho! http://avsap.sourceforge.net
ಇಂಡ್ಲಿನಕ್ಸ வாழ்க!
---
On Tuesday 07 Jun 2005 1:35 pm, Richard Huxton wrote:
> I'm not sure it is from the list - it appears to be something setup
> by [EMAIL PROTECTED]
apparently he is a member of the list - so mail from any 'untrusted'
guy like me gets this message. (anyone else getting it?)
--
regards
kg
http://
hi,
every time i post to this list i get a copy of the message below -
could the listadmin do something (or is there something i have to
do?)
-- Forwarded Message --
Subject: RE: Re: [SQL] preventing deletion of a row
Date: Tuesday 07 Jun 2005 12:24 pm
From: AntiSpam UOL <[EM
On Tuesday 07 Jun 2005 11:29 am, Nick Johnson wrote:
> >if the value of 'fixed' is TRUE, then this row cannot be deleted.
> > How do i enforce this condition?
> >
>
> Try this:
> CREATE RULE tablename_delete AS ON DELETE TO tablename WHERE
> OLD.fixed = TRUE DO INSTEAD NOTHING;
cool - thanks
--
hi
in the query:
alter database dbname set datestyle='DMY','European';
what is the significance of the two parameters given in datestyle. I
assumed that one is input and the other is output, but if i put:
set datestyle='DMY','DMY'
i get an error saying 'conflicting datestyles'
--
regards
kg
htt
hi
i have a table of the type:
id serial unique,
name varchar(50),
fixed boolean default FALSE
if the value of 'fixed' is TRUE, then this row cannot be deleted. How
do i enforce this condition?
--
regards
kg
http://www.livejournal.com/users/lawgon
tally ho! http://avsap.sourceforge.net
ಇಂಡ್ಲಿನ
how do i get a dump of a postgresql database without the data?
--
regards
kg
http://www.livejournal.com/users/lawgon
tally ho! http://avsap.sourceforge.net
àà à!
---(end of broadcast)---
TIP 4: Don't 'kill -9' the postmaster
On Friday 01 Apr 2005 5:06 pm, Gary Stainburn wrote:
> Hi folks.
>
> I've been looking at this for 10 minutes and can't see what's
> wrong. Anyone care to enlighten me.
comma after 'r'?
--
regards
kg
http://www.livejournal.com/users/lawgon
tally ho! http://avsap.sourceforge.net
àà à!
On Thursday 17 Mar 2005 7:35 pm, Richard Huxton wrote:
> Not necessarily. NOT NULL here helps to ensure you can add values
> together without the risk of a null result. There are plenty of
> "amount" columns that should be not-null (total spent, total
> ordered etc).
that makes sense - but is it
On Thursday 17 Mar 2005 1:50 pm, Phil Daintree wrote:
> CREATE TABLE chartdetails (
> accountcode integer DEFAULT 0 NOT NULL,
> period integer DEFAULT 0 NOT NULL,
> budget double precision DEFAULT (0)::double precision NOT NULL,
> actual double precision DEFAULT (0)::double precisi
hi,
i have set my datetype to 'European, SQL'. This correctly accepts
dates of the form dd/mm/. However, the output is still in the
'-mm-dd' format. How do i get the default output as dd/mm/?
--
regards
kg
http://www.livejournal.com/users/lawgon
tally ho! http://avsap.sourceforge.ne
On Wednesday 09 Mar 2005 1:40 pm, Richard Huxton wrote:
>
> I keep making this mistake, you need to include the database name:
>ALTER DATABASE my_db_name SET datestyle TO 'ISO';
er ... doesnt seem to be in the docs? Anyway it worked, thanx
--
regards
kg
http://www.livejournal.com/users/law
On Wednesday 09 Mar 2005 11:57 am, Tom Lane wrote:
> Kenneth Gonsalves <[EMAIL PROTECTED]> writes:
> > i have a website with a postgresql backend. Being a shared site,
> > i have no root access. i do have shell access to the database,
> > but cannot create or drop
hi,
i have a website with a postgresql backend. Being a shared site, i
have no root access. i do have shell access to the database, but
cannot create or drop the database. I access the database through
python scripts using the psycopg adapter. My question is, how do i
set the pgdatestyle in the
On Wednesday 05 January 2005 10:43 am, [EMAIL PROTECTED] wrote:
> Hi,
>
> I have function called test1() in database 1. I need to input the value
> from this function into another table which is in database2.
shouldnt you be using schemas instead?
kg
---(end of broadcast)
hi,
can postgres be run on a linux cluster, and if so what are the performance
and other issues - checked archives, but the only info is over a year old
kg
---(end of broadcast)---
TIP 6: Have you searched our list archives?
http://
On Friday 17 December 2004 05:54 pm, Andreas Kretschmer wrote:
> Yes, simple:
>
> test=# select name, case
> test-# when fruit = 1 then 'good'
> test-# when fruit = 2 then 'bad'
> test-# when fruit = 3 then 'rotten' end as fruit from fruit;
can one do the same thing for an 'insert' statement?
k
On Friday 17 December 2004 06:12 pm, D'Arcy J.M. Cain wrote:
> An alternative to Andreas' suggestion would be to create a simple lookup
> table and join them. This is good if the real life example can get
> larger and/or the list can change and you don't want to modify code
> every time it does.
On Friday 17 December 2004 05:15 pm, Andreas Kretschmer wrote:
> test=# select * from fruit;
> name | fruit
> +---
> Apple | 1
> Banana | 2
> Cherry | 3
> (3 Zeilen)
>
>
> test=# select name, fruit, case
> test-# when fruit = 1 then 'good'
> test-# when fruit = 2 th
hi
table:
name varchar(10)
fruit integer
i want to write an sql statement like this:
select fruit from table
which should return 'good' if fruit = 1 and 'bad' if fruit =2 and 'rotten' if
fruit =3
can it be done?
kg
---(end of broadcast)---
TI
On Monday 13 December 2004 06:55 pm, Richard Huxton wrote:
> Kenneth Gonsalves wrote:
> > hi,
> > how does one replicate the myql 'set' datatype in pg? i tried using
> > 'check', but apparently there is much more to this
>
> You could use a bit-stri
hi,
how does one replicate the myql 'set' datatype in pg? i tried using 'check',
but apparently there is much more to this
regards
kg
---(end of broadcast)---
TIP 6: Have you searched our list archives?
http://archives.postgresql.or
On Monday 13 December 2004 08:15 am, Tom Lane wrote:
>
> One character per character, whether that be a visible character or
> whitespace (including newlines). Collapsing out whitespace is
> definitely not going to give you the right count.
and while on this topic, how does one interpret the line
hi,
from mysql:
field enum('a','b','c') default null,
i translated this as:
field varchar(2) check (field in (null,'a','b','c')),
is it necessary to put the 'null' in the check condition? if not will pg
permit you to enter a null value in the field?
regards
kg
---(en
On Tuesday 23 November 2004 01:49 pm, Premsun Choltanwanich wrote:
> I use VB as develop tool and ADO for connect. My code is show below and
> for vPicMember is stand ADOStream in Binary.
>
> rs.Open "SELECT * FROM t_mbrpic WHERE mbrsysid = " & vSysId, conn,
> adOpenStatic, adLockOptimistic
> I
On Tuesday 23 November 2004 12:48 pm, Premsun Choltanwanich wrote:
> I face this same problem when I try to insert image by lo_import to
> database with my client files. I already change the way to bytea data
> type but it's not work. The error return like type mismatch when I try
> to insert it fr
On Tuesday 23 November 2004 09:51 am, sreejith s wrote:
> Query to insert
>
> INSERT INTO Imagetable VALUES (lo_import('C:\\image\\peach.jpg'));
have you succeeded in inserting an image into the database from a file on the
server using the above query? AFAIK you need a bytea
pls check this out:
http://linux-bangalore.org/2004/talks/shortlist1.php
kg
---(end of broadcast)---
TIP 9: the planner will ignore your desire to choose an index scan if your
joining column's datatypes do not match
On Saturday 28 August 2004 06:18 pm, Gaetano Mendola wrote:
> |
> | backup/restore
>
> Well, that chapter speak about pg_dump, don't you had the curiosity
> to look at the complete options for that command ? :-)
yes. so i looked in the book from which i was learning postgres. it gave
about 3 opt
On Friday 27 August 2004 01:17 pm, Michalis Kabrianis wrote:
> Kenneth Gonsalves wrote:
> > hi,
> > is there anyway to backup/restore a specfic schema in a database?
>
> Hi,
> isn't this what pg_dump --schema=SCHEMA does?
thanx - was looking in the wrong place in the
hi,
is there anyway to backup/restore a specfic schema in a database?
--
regards
kg
http://www.onlineindianhotels.net - fastest hotel search website in the world
http://www.ootygolfclub.org
---(end of broadcast)---
TIP 8: explain analyze is your fr
On Thursday 26 August 2004 04:48 pm, Philip Warner wrote:
> At 08:43 PM 26/08/2004, Riccardo G. Facchini wrote:
> >If you know of something even similar to what I'm looking for, let me
> >know.
>
> My thinking is to modify pg_dump to add a new output format, but I'd like
> to get some more feedback
On Sunday 08 August 2004 06:36 am, Oliver Elphick wrote:
> On Sat, 2004-08-07 at 05:00, Kenneth Gonsalves wrote:
> > why shouldnt the primary key change? the only key that should never
> > change is a key that is used as a foreign key in another table. In a
> > table like th
hi,
any reason why the default reply-to on this list should not be set to the
list? I keep replying to postings only to find later that the reply goes to
the OP and not to the list. reply-all button results in needless duplication
--
regards
kg
http://www.onlineindianhotels.net - fastest hotel
On Saturday 07 August 2004 04:12 am, Josh Berkus wrote:
>
> > Meanwhile, every other aspect of the data can change (e.g. a person can
> > change his name, sex, age, email, address, even date & place of birth).
> > Not to mention data entry mistakes. So it's impossible to use any
> > "real"/natural
On Wednesday 28 July 2004 06:59 am, Iain wrote:
> > couldnt you do something like, let them write the 'long flaky text', and
>
> at
>
> > the same time mark a certain number of key words or key phrases which
>
> could
>
> > be stored and retrieved?
>
> I was thinking along similar lines. On one ha
On Tuesday 27 July 2004 02:04 am, Karsten Hilbert wrote:
> One thing we ARE looking for in our records is the ability to
> find groups of patients by arbitrary criteria since one day
> I'll have to find all my patients whose father took a statine,
> whose second-born child suffered a bout of neutr
On Friday 23 July 2004 04:47 pm, Michael Glaesemann wrote:
> > id serial unique
> > namevarchar(25) not null
> > primary key is name - after all, you are going to search this on name
> > arent
> > you? or is there some advantage in doing it your way?
>
> Also, your explanation "after all,
On Friday 23 July 2004 03:29 pm, Michael Glaesemann wrote:
>
> You appear to be misunderstanding the purpose of a primary key. A
> primary key is used to ensure there is a way to identify each row
> uniquely. It is quite independent of which columns you may or may not
> want to search on. If name
On Friday 23 July 2004 12:27 pm, Karsten Hilbert wrote:
> BTW, our full schema is here:
>
> http://www.hherb.com/gnumed/schema/
i was looking at your schema. i'm not a database pro, but in master tables i
see you have made the serial id as the primary key. i do it this way:
id serial uniqu
On Thursday 22 July 2004 05:45 pm, Oliver Elphick wrote:
> On Thu, 2004-07-22 at 12:48, [EMAIL PROTECTED] wrote:
> > Actually it does work, call nextval to get your next value, then call
> > your INSERT statement,
> > explicitly giving said value for the serial column. Then you can
> > proceed wit
On Thursday 22 July 2004 05:18 pm, [EMAIL PROTECTED] wrote:
> Alternatively, you can do:
> INSERT (accepting the default)
> then SELECT currval(the_sequence_object);
> then
did this. barf: foreign key not in original table
--
regards
kg
http://www.onlineindianhotels.net - hotel bookings reser
hi,
how does one get the next number in a serial type row?
--
regards
kg
http://www.onlineindianhotels.net - hotel bookings reservations in over 4600
hotels in India
http://www.ootygolfclub.org
---(end of broadcast)---
TIP 7: don't forget to incre
hi,
can anyone tell me which is the earliest version of postgres to support
schemas
--
regards
kg
http://www.onlineindianhotels.net - hotel bookings reservations in over 4600
hotels in India
http://www.ootygolfclub.org
---(end of broadcast)---
TI
On Tuesday 29 June 2004 07:19 pm, Phil Endecott wrote:
> Kenneth Gonsalves <[EMAIL PROTECTED]> wrote:
> > in my app i have a table where the id serves as a foreign key for
> > one or more other tables. if i want to delete a row in the table,
> > i currently search the ot
in my app i have a table where the id serves as a foreign key for one or more
other tables. if i want to delete a row in the table, i currently search the
other tables where this table is referenced to see if the row is in use - and
then, if not in use, permit deletion. Now if i want the delete
hi,
does any version of postgresql support the 'SET' idiom in an insert
statement? Need this to generate an insert statement from a python dictionary
--
regards
kg
--
http://www.ootygolfclub.org
---(end of broadcast)---
TIP 6: Have you searched ou
i have a database on a local machine, and another on a remote machine. I have
a dialup connection between the two - so band width is a problem. What is the
most efficient way of updating the remote from the local? Does SQL or
postgres have simple commands for this?
--
regards
kg
--
http://www.
On Tuesday 20 January 2004 19:26, Chris Bowlby wrote:
> Hi Ken,
>
> Under 7.3.x this option was removed, you need to test via:
>
> SELECT * from table where field IS NULL;
thanx - works in both 7.1 and 7.3 - why do these guys keep fooling around
with these thangs?
--
regards
kg
http://www.ooty
in postgres7.1 i had a table where an integer field could be null. There was
no default value. a select statement like so:
'select * from table where field = null'
would give all the rows where that field had no value.
on porting to 7.3.2, this doesnt work. How to do this?
--
regards
kg
http://
On Wednesday 07 January 2004 23:01, Michael Fuhr wrote:
> On Wed, Jan 07, 2004 at 07:47:32PM +0530, Kenneth Gonsalves wrote:
> > in 7.4 i'm getting an error message - UNIQUE constraint matching keys for
> > table 'xxx' not found - any clues?
>
> It would be h
in 7.4 i'm getting an error message - UNIQUE constraint matching keys for
table 'xxx' not found - any clues?
--
regards
kg
http://www.ootygolfclub.org
poor man's tally: http://avsap.sourceforge.net
---(end of broadcast)---
TIP 9: the planner will
hi
where can i find infor about 'schema' in postgresql?
--
regards
kg
http://www.ootygolfclub.org
---(end of broadcast)---
TIP 9: the planner will ignore your desire to choose an index scan if your
joining column's datatypes do not match
76 matches
Mail list logo