[GENERAL] New Software/Projects Database

1999-02-06 Thread The Hermit Hacker


For the past few months, I've been meaning to re-build and re-write our
Software/Projects Database, as it, quite frankly, just never worked
well...

Tonight, that work has started.

If you go to http://www.postgresql.org/software (mirrors will pick it up
soon), you'll see it grow.

As I write this, the only "active" screen is the registration screen,
which anyone wanting to add to the database will have to go through.  It
doesn't ask for anything more then a First/Last name and your email
address.  A userid/password will then be sent back to you, that you can
use to add entries (am working on that right now), modify and delete
entries...

The "Register" pages will also be updated, over the next few days, to make
use of the same mechanisms for changes...we want users to be able to come
back and update their data easily, to eliminate 'stale' data...

Its a work in progress...if anyone wants to help by taking the HTML source
code for the pages and submitting "cleaner/nicer" ones, with better
wording, by all means, please do...

Marc G. Fournier
Systems Administrator @ hub.org 
primary: [EMAIL PROTECTED]   secondary: scrappy@{freebsd|postgresql}.org 




RE: [GENERAL] No MAX function

1999-02-06 Thread dustin sallings

On Sat, 6 Feb 1999, Jonny Hinojosa wrote:

// cdmwhere=> SELECT * FROM traplog WHERE millisid=
//  (SELECT MAX(millisid) FROM traplog
//  WHERE esn LIKE '0f:11:19:82:54:35');
// ERROR:  No such function 'max' with the specified attributes
// cdmwhere=>

What's a millisid?  If it's something obscure, there may not have
been a max() defined for it.

// 
// -Original Message-
// From: dustin sallings [mailto:[EMAIL PROTECTED]]
// Sent: Saturday, February 06, 1999 2:21 PM
// To: Jonny Hinojosa
// Cc: PostGreSQL Mailing List
// Subject: RE: [GENERAL] No MAX function
// 
// 
// On Sat, 6 Feb 1999, Jonny Hinojosa wrote:
// 
// select * from events
//  where event_id=(select max(event_id) from events);
// 
//  That works in my event database.
// 
// // SET QUERY_LIMIT TO restricts the number of rows returned.  I want to
// // determine the largest value in a column.  Sorry if my question was
// unclear,
// // I am new to %SQL.
// //
// // Jonny
// //
// // -Original Message-
// // From: Neil Burrows [mailto:[EMAIL PROTECTED]]
// // Sent: Saturday, February 06, 1999 1:51 PM
// // To: Jonny Hinojosa
// // Cc: [EMAIL PROTECTED]
// // Subject: RE: [GENERAL] No MAX function
// //
// //
// // Hi,
// //
// // I believe there is a patch in "contrib" directory that does this, but if
// you
// // have Postgres 6.4 then have a look at the
// //
// // SET QUERY_LIMIT TO
// //
// // command.
// //
// // Regards,
// //
// // ---[  Neil
// urrows  ]-
// // E-mail: [EMAIL PROTECTED] ** This e-mail was
// **
// // Web   : http://www.remo.demon.co.uk/** Made in Scotland
// **
// // ---< PGP Key available from http://www.remo.demon.co.uk/pgp/
// >
// //
// //
// //
// // > -Original Message-
// // > From: [EMAIL PROTECTED]
// // > [mailto:[EMAIL PROTECTED]]On Behalf Of Jonny Hinojosa
// // > Sent: 06 February 1999 19:13
// // > To: PostGreSQL Mailing List
// // > Subject: [GENERAL] No MAX function
// // >
// // >
// // > Does anyone have a work around for the lack of a MAX function ?  I need
// to
// // > find the last record WHERE a LIKE 'x' AND b LIKE 'y'.
// // >
// // > Jonny Hinojosa
// // > TCA Internet
// // > [EMAIL PROTECTED]
// // > 409.693.8885
// // >
// // >
// //
// //
// //
// 
// --
// Principal Member Technical Staff, beyond.comThe world is watching
// America,
// pub  1024/3CAE01D5 1994/11/03 Dustin Sallings <[EMAIL PROTECTED]>
// |Key fingerprint =  87 02 57 08 02 D0 DA D6  C8 0F 3E 65 51 98 D8 BE
// L__ and America is watching TV.
// __
// 
// 
// 

--
Principal Member Technical Staff, beyond.comThe world is watching America,
pub  1024/3CAE01D5 1994/11/03 Dustin Sallings <[EMAIL PROTECTED]>
|Key fingerprint =  87 02 57 08 02 D0 DA D6  C8 0F 3E 65 51 98 D8 BE 
L__ and America is watching TV. __




RE: [GENERAL] No MAX function

1999-02-06 Thread Jonny Hinojosa

On v6.4.2, I get :

cdmwhere=> SELECT * FROM traplog WHERE millisid=
(SELECT MAX(millisid) FROM traplog
WHERE esn LIKE '0f:11:19:82:54:35');
ERROR:  No such function 'max' with the specified attributes
cdmwhere=>

Jonny

-Original Message-
From: dustin sallings [mailto:[EMAIL PROTECTED]]
Sent: Saturday, February 06, 1999 2:21 PM
To: Jonny Hinojosa
Cc: PostGreSQL Mailing List
Subject: RE: [GENERAL] No MAX function


On Sat, 6 Feb 1999, Jonny Hinojosa wrote:

select * from events
where event_id=(select max(event_id) from events);

That works in my event database.

// SET QUERY_LIMIT TO restricts the number of rows returned.  I want to
// determine the largest value in a column.  Sorry if my question was
unclear,
// I am new to %SQL.
//
// Jonny
//
// -Original Message-
// From: Neil Burrows [mailto:[EMAIL PROTECTED]]
// Sent: Saturday, February 06, 1999 1:51 PM
// To: Jonny Hinojosa
// Cc: [EMAIL PROTECTED]
// Subject: RE: [GENERAL] No MAX function
//
//
// Hi,
//
// I believe there is a patch in "contrib" directory that does this, but if
you
// have Postgres 6.4 then have a look at the
//
// SET QUERY_LIMIT TO
//
// command.
//
// Regards,
//
// ---[  Neil
urrows  ]-
// E-mail: [EMAIL PROTECTED] ** This e-mail was
**
// Web   : http://www.remo.demon.co.uk/** Made in Scotland
**
// ---< PGP Key available from http://www.remo.demon.co.uk/pgp/
>
//
//
//
// > -Original Message-
// > From: [EMAIL PROTECTED]
// > [mailto:[EMAIL PROTECTED]]On Behalf Of Jonny Hinojosa
// > Sent: 06 February 1999 19:13
// > To: PostGreSQL Mailing List
// > Subject: [GENERAL] No MAX function
// >
// >
// > Does anyone have a work around for the lack of a MAX function ?  I need
to
// > find the last record WHERE a LIKE 'x' AND b LIKE 'y'.
// >
// > Jonny Hinojosa
// > TCA Internet
// > [EMAIL PROTECTED]
// > 409.693.8885
// >
// >
//
//
//

--
Principal Member Technical Staff, beyond.comThe world is watching
America,
pub  1024/3CAE01D5 1994/11/03 Dustin Sallings <[EMAIL PROTECTED]>
|Key fingerprint =  87 02 57 08 02 D0 DA D6  C8 0F 3E 65 51 98 D8 BE
L__ and America is watching TV.
__




RE: [GENERAL] No MAX function

1999-02-06 Thread dustin sallings

On Sat, 6 Feb 1999, Jonny Hinojosa wrote:

select * from events
where event_id=(select max(event_id) from events);

That works in my event database.

// SET QUERY_LIMIT TO restricts the number of rows returned.  I want to
// determine the largest value in a column.  Sorry if my question was unclear,
// I am new to %SQL.
// 
// Jonny
// 
// -Original Message-
// From: Neil Burrows [mailto:[EMAIL PROTECTED]]
// Sent: Saturday, February 06, 1999 1:51 PM
// To: Jonny Hinojosa
// Cc: [EMAIL PROTECTED]
// Subject: RE: [GENERAL] No MAX function
// 
// 
// Hi,
// 
// I believe there is a patch in "contrib" directory that does this, but if you
// have Postgres 6.4 then have a look at the
// 
// SET QUERY_LIMIT TO
// 
// command.
// 
// Regards,
// 
// ---[  Neil Burrows  ]-
// E-mail: [EMAIL PROTECTED] ** This e-mail was  **
// Web   : http://www.remo.demon.co.uk/** Made in Scotland **
// ---< PGP Key available from http://www.remo.demon.co.uk/pgp/ >
// 
// 
// 
// > -Original Message-
// > From: [EMAIL PROTECTED]
// > [mailto:[EMAIL PROTECTED]]On Behalf Of Jonny Hinojosa
// > Sent: 06 February 1999 19:13
// > To: PostGreSQL Mailing List
// > Subject: [GENERAL] No MAX function
// >
// >
// > Does anyone have a work around for the lack of a MAX function ?  I need to
// > find the last record WHERE a LIKE 'x' AND b LIKE 'y'.
// >
// > Jonny Hinojosa
// > TCA Internet
// > [EMAIL PROTECTED]
// > 409.693.8885
// >
// >
// 
// 
// 

--
Principal Member Technical Staff, beyond.comThe world is watching America,
pub  1024/3CAE01D5 1994/11/03 Dustin Sallings <[EMAIL PROTECTED]>
|Key fingerprint =  87 02 57 08 02 D0 DA D6  C8 0F 3E 65 51 98 D8 BE 
L__ and America is watching TV. __




RE: [GENERAL] No MAX function

1999-02-06 Thread Jonny Hinojosa

SET QUERY_LIMIT TO restricts the number of rows returned.  I want to
determine the largest value in a column.  Sorry if my question was unclear,
I am new to %SQL.

Jonny

-Original Message-
From: Neil Burrows [mailto:[EMAIL PROTECTED]]
Sent: Saturday, February 06, 1999 1:51 PM
To: Jonny Hinojosa
Cc: [EMAIL PROTECTED]
Subject: RE: [GENERAL] No MAX function


Hi,

I believe there is a patch in "contrib" directory that does this, but if you
have Postgres 6.4 then have a look at the

SET QUERY_LIMIT TO

command.

Regards,

---[  Neil Burrows  ]-
E-mail: [EMAIL PROTECTED] ** This e-mail was  **
Web   : http://www.remo.demon.co.uk/** Made in Scotland **
---< PGP Key available from http://www.remo.demon.co.uk/pgp/ >



> -Original Message-
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED]]On Behalf Of Jonny Hinojosa
> Sent: 06 February 1999 19:13
> To: PostGreSQL Mailing List
> Subject: [GENERAL] No MAX function
>
>
> Does anyone have a work around for the lack of a MAX function ?  I need to
> find the last record WHERE a LIKE 'x' AND b LIKE 'y'.
>
> Jonny Hinojosa
> TCA Internet
> [EMAIL PROTECTED]
> 409.693.8885
>
>




[GENERAL] No MAX function

1999-02-06 Thread Jonny Hinojosa

Does anyone have a work around for the lack of a MAX function ?  I need to
find the last record WHERE a LIKE 'x' AND b LIKE 'y'.

Jonny Hinojosa
TCA Internet
[EMAIL PROTECTED]
409.693.8885




[GENERAL] Re: [HACKERS] Problems with >2GB tables on Linux 2.0

1999-02-06 Thread Marcus Mascari


A friend of mine passed on an old DBA trick which
might be useful here (albeit quite the hack).  For
optimization purposes, a DBA might not only want to
put certain datafiles which composed tablespaces
(in the Oracle sense) on a striped partition, but
he might also want either to place a single table on
a RAID striped partition, or, if RAID was unavailable,
split the table across multiple disks on multiple
controllers.  This was done for a table, say z as 
follows:

CREATE TABLE x...
CREATE TABLE y...

[ perform some inserts into x and y from z]

DROP TABLE z

CREATE VIEW z AS SELECT * FROM x UNION SELECT * FROM y;

Using this little trick will get you around the 2Gig
limit for now, although inserting and updating 
through the view might cause problems, or might
require some use of RULES to ensure proper inserting,
updating, deleting etc.  It typically was done on
largely huge, static tables.


Hope this helps (as a hack-around) for now, 

Marcus Mascari ([EMAIL PROTECTED])

---The Hermit Hacker <[EMAIL PROTECTED]> wrote:
>
> On Sat, 6 Feb 1999, Thomas Reinke wrote:
> 
> > I may be dating myself really badly here, but isn't there a hard
limit
> > on
> > the file system at 2Gig? I thought the file size attribute in Unix
is
> > represented as a 32 bit signed long, which happens to be a max value
> > of 2147483648. If I'm right, it means the problem is fundamentally
> > with the file system, not with PostGres, and you won't solve this
> > unless the os supports larger files.
> 
> PostgreSQL has internal code that is supposed to automagically break
up a
> table into 2gb chunks so that thsi isn't a problem...
> > 
> > [EMAIL PROTECTED] wrote:
> > > 
> > > Hi,
> > > I saw a message a couple of weeks ago from someone having
problems with
> > > larger than 2GB tables.  I have similar problems.
> > > 
> > > PostgreSQL: anon-cvs as of today (2/5/1999)
> > > OS: Redhat Linux 5.2 (running 2.0.35)
> > > 
> > > I created a database called mcrl, and a table called mcrl3_1.
> > > I copied in a set of 450MB of data twice(which comes to pg file
size of
> > > 2.4GB or so).
> > > 
> > > When it hit 2GB I got this message:
> > >   mcrl=> copy mcrl3_1 FROM '/home/gjerde/mcrl/MCR3_1.txt';
> > >   ERROR:  mcrl3_1: cannot extend
> > > 
> > > The table file looks like this:
> > > [postgres@snowman mcrl]$ ls -l mcrl*
> > > -rw---   1 postgres postgres 2147482624 Feb  5 16:49 mcrl3_1
> > > 
> > > It did NOT create the .1 file however, which I did see when I
tried this
> > > on 6.4.2(but still didn't work).
> > > 
> > > I looked around in the code(specifically
src/backend/storage/smgr/*.c),
> > > but couldn't figure too much of it out.  I'll have to figure out
how
> > > postgres handles the database files first..
> > > 
> > > Hope this helps,
> > > Ole Gjerde
> > 
> > -- 
> > 
> > Thomas ReinkeTel: (416) 460-7021
> > Director of Technology   Fax: (416) 598-2319
> > E-Soft Inc. http://www.e-softinc.com
> > 
> 
> Marc G. Fournier
> Systems Administrator @ hub.org 
> primary: [EMAIL PROTECTED]   secondary:
scrappy@{freebsd|postgresql}.org 
> 
> 
> 

_
DO YOU YAHOO!?
Get your free @yahoo.com address at http://mail.yahoo.com




[GENERAL] connecting: unix socket? Yes. TCPIP port? No. -i? Yes.

1999-02-06 Thread Bob VonMoss

I'm just getting into PostGreSQL and would ultimately like to
communicate from a java/JDBC applet through the web with PostGreSQL on a

Solaris unix system. I've had a user account created for me. I'm able to

do everything so far from the commandline through unix sockets by
running 'psql' and 'createdb mydb'.

I began experimenting with JDBC and was having problems connecting, so I

put the java application on the same system where PostGreSQL is and was
getting the same 'user authentication failed...' messages. I then tried
altering the jdbc URL to specify the database only without the internet
host name and it worked successfully.
I changed this statement in the code below:
   con = DriverManager.getConnection(
   "jdbc:postgresql://my-isp.com/mydb","mylogin","mypwd");
to (since I was local):
   con = DriverManager.getConnection(
   "jdbc:postgresql:mydb","mylogin","mypwd");
and it worked on the local machine.

The error was:
bash$ java pCon
registering postgresql.Driver...
connecting to the PostGreSQL DB...
java.sql.SQLException: User authentication failed
bash$

I noticed in the docs that you can channel psql through TCPIP ports
rather than unix sockets. I tried it (with my real names) and get this:

bash$ psql -h my-isp.com -d mydb
Connection to database 'mydb' failed.
User authentication failedbash$
bash$ psql -h my-isp.com -p 5432 -d mydb
Connection to database 'mydb' failed.
User authentication failedbash$

I also tried setting PGHOST to my-isp.com, which responded the same.

The administrator says this is how postmaster is invoked:

/usr/local/pgsql/bin/postmaster -S -i -D /usr/local/pgsql/data -p 5432



// pCon.java

import java.io.*;
import java.sql.*;

public class pCon {
 public pCon() { }

 public static void main(String[] args) throws Exception
 {
  System.out.println("registering postgresql.Driver...");
  Connection con;
  try {
   Class.forName("postgresql.Driver");
  } catch (Exception e) {
   System.out.println(""+e);
   return;
  }
  System.out.println("connecting to the PostGreSQL DB...");
  try {
   con = DriverManager.getConnection(
   "jdbc:postgresql://my-isp.com/mydb","mylogin","mypwd");
  } catch (SQLException se) {
   System.out.println(""+se);
   return;
  }
  System.out.println(
   "closing connection to the PostGreSQL DB...");
  try {
   con.close();
  } catch (SQLException se) {
   System.out.println(""+se);
  }
  System.out.println(
   "connection to the PostGreSQL DB closed successfully");
 }
}

--
Bob VonMoss
mailto:[EMAIL PROTECTED]
from Chicago, IL