[ADMIN] table test

2001-11-28 Thread Manuel Trujillo

Hi.

I need to know howto make a test for know the best accuracy of two types of tables:
1- a table with three fields, and with seven registers or more, and
2- a table with ten fields, and two registers.
Like my language is very poor, I illustrate this:

Table One:  Table Two:
  1 |  2 |  3 |1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 |
---   -
1|__||| 1 ___|___|___|___|___|___|___|___|___||
2|__||| 2 ___|___|___|___|___|___|___|___|___||
.
.
.
7|__|||


How is the best way to know the better type of table of this two types?

Thank you very much!

Have a nice day ;-)
TooManySecrets

-- 
Manuel Trujillo [EMAIL PROTECTED]
Technical Engineer  http://www.motograndprix.com
Dorna Sports S.L.   +34 93 4702864

---(end of broadcast)---
TIP 2: you can get off all lists at once with the unregister command
(send "unregister YourEmailAddressHere" to [EMAIL PROTECTED])



[ADMIN] ODBC password crypting support

2001-11-28 Thread sulik_pbem

 When trying to connect to the postgreSQL database through ODBC, I get an error
"Unknown username or password. Password crypt authentication not supported.
(errcode 13095)"
 I can assume ODBC do not support password crypting. Does that mean I cannot
connect through ODBC, or there's another way?
--- Get your private e-mail at http://www.netmail.kg

---(end of broadcast)---
TIP 5: Have you checked our extensive FAQ?

http://www.postgresql.org/users-lounge/docs/faq.html



[ADMIN] éèàïîù Problem

2001-11-28 Thread Vincent . Gaboriau

Hi all,

I had curious problem with the characters like " éèàïîù... " (refer to
my first mail "[ADMIN] character sequence problem" for more
information). My database was encoding with UNICODE.
I have created another one with LATIN1 encoding, and I have'nt anymore
those problems!
Can any one explain to me why? Which encoding is used in postgres when
you say UNICODE? UTF-8?
I thought that UNICODE is knowing all the characters!

Thanks,

Vincent.


---(end of broadcast)---
TIP 4: Don't 'kill -9' the postmaster



Re: [ADMIN] [HACKERS] upper and lower doesn't work with german

2001-11-28 Thread Vincent . Gaboriau



Tom Lane a écrit :

> [EMAIL PROTECTED] writes:
> >> You might be able to get it by looking through the
> >> /global/pg_control file, but it's a binary file so you'll have
> >> to search for it.
>
> > I had found it, but I don't know speak fluent binary language  ;-)
> > Does a way exist to "decompile" it or to get informations on it?
>
> If you can't be troubled to compile up pg_controldata, then you'll
> have to resort to good old od:
>
> $ od -c pg_control
> 000 314 201 030 267 255   u 344 277  \0  \0  \0   G 013 355   p 253
> 020  \0  \0  \0 004   < 004   ) 006  \0  \0  \0  \0  \0  \0  \0   8
> 040  \0  \0  \0  \0   7 026   e 210  \0  \0  \0  \0   7 026   D   h
> 060  \0  \0  \0  \0   7 026   e 210  \0  \0  \0  \0  \0  \0  \0  \0
> 100  \0  \0  \0  \t  \0 001 357 235  \0 017 017 354   < 004   ) 004
> 120  \0  \0  \0  \0 002  \0  \0   C  \0  \0  \0  \0  \0  \0  \0
> 140  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0
> *
> 320  \0  \0  \0  \0  \0  \0  \0  \0   C  \0  \0  \0  \0  \0  \0  \0
> 340  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0
> *
> 002
>
> The LC_COLLATE and LC_CTYPE locale strings should be the last nonzero
> things in the file --- they're both "C" in this example.
>

Thanks to Tom Lane!
But I have This in my pg_control file:

# od -c pg_control
000  \0  \0  \0  \0 001  \0  \0  \0  \0  \0  \0  \0  \b  \0  \0  \0
020   ¤ 006 004   < 004  \0  \0  \0  \0  \0  \0  \0  \0 002  \0
040   ±   Õ   ë  \v  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0
060  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0
*
002
#

So no LC_COLLATE and LC_TYPE in the pg_control. But these variables are set in
the user environement!


---(end of broadcast)---
TIP 2: you can get off all lists at once with the unregister command
(send "unregister YourEmailAddressHere" to [EMAIL PROTECTED])



Re: [ADMIN] Creating schema in postgres

2001-11-28 Thread Stephan Szabo

On Wed, 28 Nov 2001, Jyoti Patil wrote:

> Hi,
>
> I would like to know how can we create a schema in postgres.

You can't yet.  Hopefully it'll be in 7.3.



---(end of broadcast)---
TIP 5: Have you checked our extensive FAQ?

http://www.postgresql.org/users-lounge/docs/faq.html



Re: [ADMIN] Creating schema in postgres

2001-11-28 Thread Andrew G. Hammond

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On 2001 November 28 05:35 am, Jyoti Patil wrote:
> I would like to know how can we create a schema in postgres.

There are graphical front end tools available that will do this for you, but 
it all comes down to CREATE statements in SQL.  You can communicate dirrectly 
with the database (in SQL) using the psql command line utility that comes 
with the database.  To create a schema (in psql), you might do something like 
the following:

- -- table to list people
CREATE TABLE person (id SERIAL PRIMARY KEY,
  given_name TEXT NOT NULL,
  surname TEXT NOT NULL,
  birth_date DATE CHECK (birth_date > 1960-01-01),  -- no old people allowed
  eye_colour TEXT );

- -- table to list friendships ( n to m relationship of person to person)
CREATE TABLE friend (id SERIAL PRIMARY KEY,
  person_a INTEGER REFERENCES person(id),
  person_b INTEGER REFERENCES person(id) );

- -- pets ( 1 to n relationship of people to pets)
CREATE TABLE pet (id SERIAL PRIMARY KEY,
  name TEXT NOT NULL,
  type TEXT NOT NULL CHECK (type IN ('cat', 'dog', 'bird', 'llama')),
  owner INTEGER REFERENCES person(id) );

And, to increase the performance of sorts and selects, create some indices on 
the above tables:

CREATE INDEX p_a_idx ON person (given_name, surname);
CREATE INDEX p_b_idx ON person (surname, given_name);
CREATE INDEX f_a_idx ON friend (person_a);
CREATE INDEX f_b_idx ON friend (person_b);
CREATE INDEX pet_owner_idx ON pet(owner);

Anyway, I hope this is enough to get you pointed in the right dirrection.  
Feel free to ask me for more details.

- -- 
Andrew G. Hammond mailto:[EMAIL PROTECTED]   http://xyzzy.dhs.org/~drew/
56 2A 54 EF 19 C0 3B 43 72 69 5B E3 69 5B A1 1F  613-389-5481
5CD3 62B0 254B DEB1 86E0  8959 093E F70A B457 84B1
"To blow recursion you must first blow recur" -- me
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.0.6 (GNU/Linux)
Comment: For info see http://www.gnupg.org

iEYEARECAAYFAjwFE1AACgkQCT73CrRXhLGQhACfZPFhzCDoODJh/fdL7e36uozP
iL4An1WmIo6bm1Bysu7WHbpQQUZ1gM0w
=vFbY
-END PGP SIGNATURE-

---(end of broadcast)---
TIP 2: you can get off all lists at once with the unregister command
(send "unregister YourEmailAddressHere" to [EMAIL PROTECTED])



Re: [ADMIN] [HACKERS] upper and lower doesn't work with german

2001-11-28 Thread Tom Lane

[EMAIL PROTECTED] writes:
> But I have This in my pg_control file:

> # od -c pg_control
> 000  \0  \0  \0  \0 001  \0  \0  \0  \0  \0  \0  \0  \b  \0  \0  \0
> 020   ¤ 006 004   < 004  \0  \0  \0  \0  \0  \0  \0  \0 002  \0
> 040   ±   Õ   ë  \v  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0
> 060  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0
> *
> 002
> #

Er ... *what* version did you say you were running?  That doesn't look
like a 7.1 pg_control to me.

regards, tom lane

---(end of broadcast)---
TIP 2: you can get off all lists at once with the unregister command
(send "unregister YourEmailAddressHere" to [EMAIL PROTECTED])



Re: [ADMIN] [HACKERS] upper and lower doesn't work with german

2001-11-28 Thread Vincent . Gaboriau



Tom Lane a écrit :

> [EMAIL PROTECTED] writes:
> > But I have This in my pg_control file:
>
> > # od -c pg_control
> > 000  \0  \0  \0  \0 001  \0  \0  \0  \0  \0  \0  \0  \b  \0  \0  \0
> > 020   ¤ 006 004   < 004  \0  \0  \0  \0  \0  \0  \0  \0 002  \0
> > 040   ±   Õ   ë  \v  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0
> > 060  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0
> > *
> > 002
> > #
>
> Er ... *what* version did you say you were running?  That doesn't look
> like a 7.1 pg_control to me.

No, I have an 7.0.2 on Linux Mandrake 7.2.


---(end of broadcast)---
TIP 4: Don't 'kill -9' the postmaster



Re: [ADMIN] [HACKERS] upper and lower doesn't work with german

2001-11-28 Thread Tom Lane

[EMAIL PROTECTED] writes:
>> Er ... *what* version did you say you were running?  That doesn't look
>> like a 7.1 pg_control to me.

> No, I have an 7.0.2 on Linux Mandrake 7.2.

Time to update then.  7.0 doesn't freeze the LC_COLLATE setting at
initdb, which means that you can corrupt your indexes by starting the
postmaster with different LC settings at different times.  Which is
depressingly easy to do.

regards, tom lane

---(end of broadcast)---
TIP 6: Have you searched our list archives?

http://archives.postgresql.org



Re: [ADMIN] [HACKERS] upper and lower doesn't work with german

2001-11-28 Thread Vincent . Gaboriau

> > The sources of postgres have been deleted, so I can't find this "contrib"!
> > So I surch another way to know if postgres have been installed with the local
> > configuration.
> > Can anyone help me?
>
> You might be able to get it by looking through the
> /global/pg_control file, but it's a binary file so you'll have
> to search for it.

I had found it, but I don't know speak fluent binary language  ;-)
Does a way exist to "decompile" it or to get informations on it?

Thanks.



---(end of broadcast)---
TIP 2: you can get off all lists at once with the unregister command
(send "unregister YourEmailAddressHere" to [EMAIL PROTECTED])



[ADMIN] Clustering high-availability

2001-11-28 Thread Miguel Gonzalez

Dear all,

 I am wondering if someone could tell me any experience of building
 architecture of load balancing for PostgreSQL. I am interested in
 clustering and a high-availability server. Is that possible? Which
 tool should I use?

  Many thanks in advance

  Miguel


---(end of broadcast)---
TIP 6: Have you searched our list archives?

http://archives.postgresql.org



[ADMIN] Creating schema in postgres

2001-11-28 Thread Jyoti Patil

Hi,

I would like to know how can we create a schema in postgres.

Many thanks 
Jyoti.


**
This email and any files transmitted with it are confidential and
intended solely for the use of the individual or entity to whom they
are addressed. If you have received this email in error please notify
the system manager.

This footnote also confirms that this email message has been swept by
MIMEsweeper for the presence of computer viruses.

www.mimesweeper.com
**

---(end of broadcast)---
TIP 1: subscribe and unsubscribe commands go to [EMAIL PROTECTED]



Re: [ADMIN] [HACKERS] upper and lower doesn't work with german

2001-11-28 Thread Tom Lane

[EMAIL PROTECTED] writes:
>> You might be able to get it by looking through the
>> /global/pg_control file, but it's a binary file so you'll have
>> to search for it.

> I had found it, but I don't know speak fluent binary language  ;-)
> Does a way exist to "decompile" it or to get informations on it?

If you can't be troubled to compile up pg_controldata, then you'll
have to resort to good old od:

$ od -c pg_control
000 314 201 030 267 255   u 344 277  \0  \0  \0   G 013 355   p 253
020  \0  \0  \0 004   < 004   ) 006  \0  \0  \0  \0  \0  \0  \0   8
040  \0  \0  \0  \0   7 026   e 210  \0  \0  \0  \0   7 026   D   h
060  \0  \0  \0  \0   7 026   e 210  \0  \0  \0  \0  \0  \0  \0  \0
100  \0  \0  \0  \t  \0 001 357 235  \0 017 017 354   < 004   ) 004
120  \0  \0  \0  \0 002  \0  \0   C  \0  \0  \0  \0  \0  \0  \0
140  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0
*
320  \0  \0  \0  \0  \0  \0  \0  \0   C  \0  \0  \0  \0  \0  \0  \0
340  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0  \0
*
002

The LC_COLLATE and LC_CTYPE locale strings should be the last nonzero
things in the file --- they're both "C" in this example.

regards, tom lane

---(end of broadcast)---
TIP 1: subscribe and unsubscribe commands go to [EMAIL PROTECTED]



[ADMIN] can posgreSQL store data using raw device?

2001-11-28 Thread Ming Du - Sun Microsystems

>From the document, I haven't found it can do this.  Does anybody know how to 
store data to raw device?
Thanks.

ming du


---(end of broadcast)---
TIP 3: if posting/reading through Usenet, please send an appropriate
subscribe-nomail command to [EMAIL PROTECTED] so that your
message can get through to the mailing list cleanly



Re: [ADMIN] ODBC password crypting support

2001-11-28 Thread Bruce Momjian

>  When trying to connect to the postgreSQL database through ODBC, I get an error
> "Unknown username or password. Password crypt authentication not supported.
> (errcode 13095)"
>  I can assume ODBC do not support password crypting. Does that mean I cannot
> connect through ODBC, or there's another way?

You can use plain password with ODBC, just not crypt password.  The
password will flow unencrypted over the network.   7.2beta3 supports MD5
encrypted passwords.

-- 
  Bruce Momjian|  http://candle.pha.pa.us
  [EMAIL PROTECTED]   |  (610) 853-3000
  +  If your life is a hard drive, |  830 Blythe Avenue
  +  Christ can be your backup.|  Drexel Hill, Pennsylvania 19026

---(end of broadcast)---
TIP 3: if posting/reading through Usenet, please send an appropriate
subscribe-nomail command to [EMAIL PROTECTED] so that your
message can get through to the mailing list cleanly



[ADMIN] how often should I run Vacuum

2001-11-28 Thread Leong, Fushan

Hi :

Want to get some idea about Vaccum function...

How often would you suggest to run Vaccum command?
Should I schedule to run in non-busy time like midnight?
Vaccum all or Vacuum for each individual table
Any tips for Vaccum?

thanks
Fushan

---(end of broadcast)---
TIP 4: Don't 'kill -9' the postmaster