Re: [GENERAL] PostgreSQL 8.1 vs. MySQL 5.0?

2005-10-05 Thread Dann Corbit
No. Distributed transactions can cooperate in two phase commit. I think someone has done some two phase commit work already. IIRC. > -Original Message- > From: [EMAIL PROTECTED] [mailto:pgsql-general- > [EMAIL PROTECTED] On Behalf Of CSN > Sent: Wednesday, October 05, 2005 11:11 PM > To:

Re: [GENERAL] How to uninstall Postgres

2005-10-05 Thread suresh ramasamy
On 10/6/05, Ly Lam Ngoc Bich <[EMAIL PROTECTED]> wrote: > I have installed PostgresSQL with postgresql-8.0.3.tar.gz . My > computer's OS is Linux Fedora 3 . Please show me to the way to uninstall > PostgresSQL. > > > ---(end of broadcast)--- > TIP 3:

Re: [GENERAL] PostgreSQL 8.1 vs. MySQL 5.0?

2005-10-05 Thread CSN
I'm not sure what XA (distributed transactions) is - is that something that can be achieved with Slony? CSN --- "Joshua D. Drake" <[EMAIL PROTECTED]> wrote: > On Wed, 2005-10-05 at 18:37 -0700, CSN wrote: > > Just so I know (and am armed ;) ), are there any > new > > comparable features in MyS

Re: [GENERAL] PostgreSQL 8.1 vs. MySQL 5.0?

2005-10-05 Thread Tino Wildenhain
Am Mittwoch, den 05.10.2005, 18:37 -0700 schrieb CSN: > Just so I know (and am armed ;) ), are there any new > comparable features in MySQL 5.0 that aren't in > PostgreSQL up to the forthcoming 8.1? AFAIK, PG just > lacks updatable views (which are on the TODO). > > MySQL 5.0 new features > http:/

Re: [GENERAL] PostgreSQL 8.1 vs. MySQL 5.0?

2005-10-05 Thread Joshua D. Drake
More generally, it's worth making the point that a lot of MySQL's "brand new in 5.0" features have been in Postgres for a *long* time, and are therefore likely to be both more stable and better-performing than MySQL's first cut at them. Some specific things could be: Their "initial support" f

Re: [GENERAL] Syntax for use of point

2005-10-05 Thread Michael Fuhr
On Wed, Oct 05, 2005 at 06:46:16PM +0200, Poul Møller Hansen wrote: > I have made the table shown below and inserted two points, > but I can't find the proper syntax for finding the nearest point > > create table store_point(position point); > insert into store_point values ('55.512345, -6.5')

[GENERAL] How to uninstall Postgres

2005-10-05 Thread Ly Lam Ngoc Bich
I have installed PostgresSQL with postgresql-8.0.3.tar.gz . My computer's OS is Linux Fedora 3 . Please show me to the way to uninstall PostgresSQL. ---(end of broadcast)--- TIP 3: Have you checked our extensive FAQ? http://www.post

Re: [GENERAL] PostgreSQL 8.1 vs. MySQL 5.0?

2005-10-05 Thread Tom Lane
"Joshua D. Drake" <[EMAIL PROTECTED]> writes: > On Wed, 2005-10-05 at 18:37 -0700, CSN wrote: >> Just so I know (and am armed ;) ), are there any new >> comparable features in MySQL 5.0 that aren't in >> PostgreSQL up to the forthcoming 8.1? AFAIK, PG just >> lacks updatable views (which are on the

Re: [GENERAL] PostgreSQL 8.1 vs. MySQL 5.0?

2005-10-05 Thread Joshua D. Drake
On Wed, 2005-10-05 at 18:37 -0700, CSN wrote: > Just so I know (and am armed ;) ), are there any new > comparable features in MySQL 5.0 that aren't in > PostgreSQL up to the forthcoming 8.1? AFAIK, PG just > lacks updatable views (which are on the TODO). > > MySQL 5.0 new features > http://dev.mys

Re: [GENERAL] portable pgsql binary/pkg building on OSX ...

2005-10-05 Thread OpenMacNews
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 hi john > There a couple of packages out there which may provide some useful hints: > > http://sourceforge.net/projects/pgsqlformac/ > http://perso.wanadoo.fr/bruno.gaufier/xhtml/downloads.xhtml > http://www.entropy.ch/software/macosx/postgresql/ u

Re: [GENERAL] portable pgsql binary/pkg building on OSX ...

2005-10-05 Thread John DeSoi
On Oct 5, 2005, at 9:32 PM, OpenMacNews wrote: my 'goal' it to make a "painless" & complete package to install, preferably into its own tree (within a .app, perhaps), no interfering with, or by, other installed apps/libs/headers/etc. There a couple of packages out there which may provide s

[GENERAL] PostgreSQL 8.1 vs. MySQL 5.0?

2005-10-05 Thread CSN
Just so I know (and am armed ;) ), are there any new comparable features in MySQL 5.0 that aren't in PostgreSQL up to the forthcoming 8.1? AFAIK, PG just lacks updatable views (which are on the TODO). MySQL 5.0 new features http://dev.mysql.com/doc/mysql/en/mysql-5-0-nutshell.html Thanks, CSN

Re: [GENERAL] portable pgsql binary/pkg building on OSX ...

2005-10-05 Thread OpenMacNews
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 hi john, >> is '--disable-rpath' necessary/sufficient? > I don't think so, but I'm hardly and expert here. I was able to build > psql with libq as a single executable, but in the end I found it easier > to do the standard compile and then have a sc

Re: [GENERAL] Securing Postgres

2005-10-05 Thread Uwe C. Schroeder
On Wednesday 05 October 2005 07:37, L van der Walt wrote: > Berend Tober wrote: > > L van der Walt wrote: > >> I would like to secure Postgres completly. > >> > >> Some issues that I don't know you to fix: > >> 1. User postgres can use psql (...) to do anything. > >> 2. User root can su to postgr

Re: [GENERAL] portable pgsql binary/pkg building on OSX ...

2005-10-05 Thread John DeSoi
On Oct 5, 2005, at 6:34 PM, OpenMacNews wrote: (1) to build STATIC pgsql* binaries, with NO external lib dependencies, is '--disable-rpath' necessary/sufficient? I don't think so, but I'm hardly and expert here. I was able to build psql with libq as a single executable, but in the end I

[GENERAL] portable pgsql binary/pkg building on OSX ...

2005-10-05 Thread OpenMacNews
hi all, i've been happily building runing ver's of pgsql (current 81b2) on my OSX 10.4.2 on G4 boxes. to date, always linked/built to my /usr/local dev tree of libs, headers, etc. now, i'd like to build once, pkg and deploy to other boxes. admittedly, dylibs/libtool/etc which have been standard

Re: [GENERAL] Trying to append text to the end of a text string

2005-10-05 Thread Martijn van Oosterhout
On Thu, Oct 06, 2005 at 11:30:53AM +1300, Adam Lawrence wrote: > Hi > > I am trying to append text onto the end of a text variable. > > I have the text variable P_IDT_ID, I want to add the letter S to the end of > it, so I tried the following line in my code: > > P_IDT_ID := P_IDT_ID && cast(''

Re: [GENERAL] Trying to append text to the end of a text string

2005-10-05 Thread Jim C. Nasby
decibel=# select 'moo' || 'cow'; moocow decibel=# What database uses &&? Access? I seem to recall seeing that somewhere before, but don't remember where... Note that || is ANSI SQL. On Thu, Oct 06, 2005 at 11:30:53AM +1300, Adam Lawrence wrote: > Hi > > I am trying to append text onto the end

Re: [GENERAL] Trying to append text to the end of a text string

2005-10-05 Thread Scott Marlowe
On Wed, 2005-10-05 at 17:30, Adam Lawrence wrote: > Hi > > I am trying to append text onto the end of a text variable. > > I have the text variable P_IDT_ID, I want to add the letter S to the > end of it, so I tried the following line in my code: > > P_IDT_ID := P_IDT_ID && cast(''S'' as text

Re: [GENERAL] Securing Postgres

2005-10-05 Thread Jim C. Nasby
On Wed, Oct 05, 2005 at 04:48:33PM +0200, L van der Walt wrote: > The big problem is that the administrators works for the client and not > for me. I don't want the client to reverse engineer my database. You don't need a technical solution; you need a legal one. Anyone with physical access to

[GENERAL] Trying to append text to the end of a text string

2005-10-05 Thread Adam Lawrence
Hi   I am trying to append text onto the end of a text variable.   I have the text variable P_IDT_ID, I want to add the letter S to the end of it, so I tried the following line in my code:   P_IDT_ID := P_IDT_ID && cast(''S'' as text);   However, I got the following error message:   ERROR: 

Re: [GENERAL] License question[VASCL:A1077160A86]

2005-10-05 Thread Jim C. Nasby
On Wed, Oct 05, 2005 at 04:14:03PM -0400, Andrew Sullivan wrote: > On Wed, Oct 05, 2005 at 09:49:06PM +1000, Neil Dugan wrote: > > > > If I was to develop a 'C' project that only used the libpg.so library and > > the > > rest was my own stuff would I need to preserve the copyright to somehow? >

Re: [GENERAL] Or selection on index versus union

2005-10-05 Thread Jim C. Nasby
On Wed, Oct 05, 2005 at 11:13:58AM +0200, [EMAIL PROTECTED] wrote: > On Tuesday 04 October 2005 23:08, Michael Fuhr wrote: > > On Tue, Oct 04, 2005 at 09:32:41PM +0200, [EMAIL PROTECTED] wrote: > > > I've got a table with an index, let's call it fase. > > > > > > The following query is fine: 'selec

Re: [GENERAL] transaction toggling

2005-10-05 Thread Jim C. Nasby
On Wed, Oct 05, 2005 at 12:49:33AM -0700, Matthew Peter wrote: > Is there a way to disable transactions on certian > queries? I read a while back that this wasn't > possible, just wondering if it is in 8.1 or planned in > the future? > > Does it even make a dent in the performance if a query > is

Re: [GENERAL] Untyped result (setof / rowset) from Functions ?

2005-10-05 Thread Jim C. Nasby
Patches welcome. :) Seriously, if you were to come up with an interface that did this using a procedure language it would at a minimum be useful to others using dblink, and could potentially be brought into the core as well. Of course you could also work on a patch of the core, but if you're going

Re: [GENERAL] SPI_prepare, SPI_execute_plan do not return rows when using parameters

2005-10-05 Thread Dennis Jenkins
--- Tom Lane <[EMAIL PROTECTED]> wrote: > Dennis Jenkins <[EMAIL PROTECTED]> > writes: > > My problem is that a query that should be > returning a > > row is returning zero rows when I use a > parametrized > > query. > > You're passing the wrong parameter value, and > probably not declaring it

Re: [GENERAL] License question[VASCL:A1077160A86]

2005-10-05 Thread Andrew Sullivan
On Wed, Oct 05, 2005 at 09:49:06PM +1000, Neil Dugan wrote: > > If I was to develop a 'C' project that only used the libpg.so library and the > rest was my own stuff would I need to preserve the copyright to somehow? Yes, because libpg.so is licensed under the BSD license. Note that you can do

Re: [GENERAL] [ADMIN] System Tables

2005-10-05 Thread Sean Hamilton
Check out the docs   http://www.postgresql.org/docs/8.0/static/catalogs.html>>> "Adriano Gaspar" <[EMAIL PROTECTED]> 10/5/2005 3:29:27 PM >>> I´m interesting in learning Postgre because I´m working with it now, if you can, i want to know wich are the system tables, and in wich of them can I find

Re: [GENERAL] optimizing common subqueries

2005-10-05 Thread Jim C. Nasby
You can put the complex query into a subquery in the from clause and PostgreSQL will normally do a good job with that. See one of the other replies in this thread. On Wed, Oct 05, 2005 at 11:23:20AM -0400, John D. Burger wrote: > As I understand it, Postgres's query planner considers only trees of

Re: [GENERAL] SPI_prepare, SPI_execute_plan do not return rows when using parameters

2005-10-05 Thread Tom Lane
Dennis Jenkins <[EMAIL PROTECTED]> writes: > My problem is that a query that should be returning a > row is returning zero rows when I use a parametrized > query. You're passing the wrong parameter value, and probably not declaring it to be the right type either. CHAROID is not the type you think

[GENERAL] SPI_prepare, SPI_execute_plan do not return rows when using parameters

2005-10-05 Thread Dennis Jenkins
Postgresql v8.0.3 on FreeBSD 5.4. I'm developing my first major 'C' language stored procedure. Inside this procedure I need to query a lookup table stored in postgres. I found several examples of using SPI_* functions via google searches. I read the documents on the postgres web site several ti

Re: [GENERAL] Problems with group by ... order by

2005-10-05 Thread Tom Lane
"John D. Burger" <[EMAIL PROTECTED]> writes: > I can't figure out why the following doesn't work: >select > (case > when count1 < 300 then 'Other' > else country1 > end) as country2, > sum(count1) as count2 > from (select coalesce(coun

Re: [GENERAL] Problems with group by ... order by

2005-10-05 Thread Bricklen Anderson
John D. Burger wrote: > I can't figure out why the following doesn't work: > > select > (case > when count1 < 300 then 'Other' > else country1 > end) as country2, > sum(count1) as count2 > from (select coalesce(country, 'None') as country1, count(*) as count1

Re: [GENERAL] [PERFORM] Text/Varchar performance...

2005-10-05 Thread Josh Berkus
Cristian, > Hello, just a little question, It's preferable to use Text Fields or > varchar(255) fields in a table? Are there any performance differences in > the use of any of them? TEXT, VARCHAR, and CHAR use the same underlying storage mechanism. This means that TEXT is actually the "fastest

[GENERAL] Problems with group by ... order by

2005-10-05 Thread John D. Burger
I can't figure out why the following doesn't work: select (case when count1 < 300 then 'Other' else country1 end) as country2, sum(count1) as count2 from (select coalesce(country, 'None') as country1, count(*) as count1

[GENERAL] Text/Varchar performance...

2005-10-05 Thread Cristian Prieto
Hello, just a little question, It's preferable to use Text Fields or varchar(255) fields in a table? Are there any performance differences in the use of any of them? Thanks a lot for your answer! ---(end of broadcast)--- TIP 4: Have you searched ou

Re: [GENERAL] Securing Postgres

2005-10-05 Thread Berend Tober
Tom Lane wrote: L van der Walt <[EMAIL PROTECTED]> writes: ...I can use encryption to protect the data. If you think encryption will protect you against someone with root privileges, you're sadly mistaken. ... All the same points hold for SQL Server of course --- the fact that you w

Re: [GENERAL] PostgreSQL on Slash Dot

2005-10-05 Thread Aaron Glenn
On 10/5/05, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > Check it out. > http://developers.slashdot.org/developers/05/10/05/1344254.shtml?tid=221&tid=218 ---(end of broadcast)--- TIP 1: if posting/reading through Usenet, please send an appropriate

Re: [GENERAL] Securing Postgres

2005-10-05 Thread Stefan 'Kaishakunin' Schumacher
Also sprach Stefan 'Kaishakunin' Schumacher ([EMAIL PROTECTED]) > Also sprach L van der Walt ([EMAIL PROTECTED]) > > The big problem is that the administrators works for the client and not > > for me. I don't want the client to reverse engineer my database. > > [...] > > > About the raw databa

[GENERAL] Syntax for use of point

2005-10-05 Thread Poul Møller Hansen
I have made the table shown below and inserted two points, but I can't find the proper syntax for finding the nearest point create table store_point(position point); insert into store_point values ('55.512345, -6.5'); insert into store_point values ('55.123456, -6.1'); select * from store

[GENERAL] PostgreSQL on Slash Dot

2005-10-05 Thread Richard_D_Levine
Check it out. ---(end of broadcast)--- TIP 9: In versions below 8.0, the planner will ignore your desire to choose an index scan if your joining column's datatypes do not match

Re: [GENERAL] Securing Postgres

2005-10-05 Thread Martijn van Oosterhout
On Wed, Oct 05, 2005 at 05:27:22PM +0200, L van der Walt wrote: > I have played now with MySQL and with MySQL you can change the password > for root in MySQL (same as postgres in PostgreSQL). If you use the > command line tools like dump you require the password. Just because > your root doesn

Re: [GENERAL] transaction toggling

2005-10-05 Thread Matthew Peter
--- Richard Huxton wrote: > Matthew Peter wrote: > > Is there a way to disable transactions on certian > > queries? I read a while back that this wasn't > > possible, just wondering if it is in 8.1 or > planned in > > the future? > > > > Does it even make a dent in the performance if a > query

Re: [GENERAL] Securing Postgres

2005-10-05 Thread Richard Huxton
L van der Walt wrote: Richard Huxton wrote: L van der Walt wrote: The big problem is that the administrators works for the client and not for me. I don't want the client to reverse engineer my database. There might be other applications on the server so the administrators do require root ac

Re: [GENERAL] Securing Postgres

2005-10-05 Thread Scott Marlowe
On Wed, 2005-10-05 at 09:37, L van der Walt wrote: > Berend Tober wrote: > > > L van der Walt wrote: > > > >> I would like to secure Postgres completly. > >> > >> Some issues that I don't know you to fix: > >> 1. User postgres can use psql (...) to do anything. > >> 2. User root can su to postgr

Re: [GENERAL] Securing Postgres

2005-10-05 Thread Welty, Richard
>No I can not trust the clients administrators. >I have played now with MySQL and with MySQL you can change the password >for root in MySQL (same as postgres in PostgreSQL). If you use the >command line tools like dump you require the password. Just because >your root doesn't mean your root i

Re: [GENERAL] Securing Postgres

2005-10-05 Thread Welty, Richard
[EMAIL PROTECTED] wrote: >You could look at what SELinux extensions now available in at least the Red >Hat (and Fedora) distro offer. I have never done anything with SELinux, >and a quick review of the archives indicates it is not a slam dunk to use. >It is designed to create the kind of restricti

Re: [GENERAL] Securing Postgres

2005-10-05 Thread SCassidy
You do know that MySQL lets you reset the root password if you forget it, don't you? See: http://dev.mysql.com/doc/mysql/en/resetting-permissions.html Not terribly secure, after all. Susan

Re: [GENERAL] Securing Postgres

2005-10-05 Thread Scott Marlowe
On Wed, 2005-10-05 at 10:27, L van der Walt wrote: > Richard Huxton wrote: > > > L van der Walt wrote: > > > >> The big problem is that the administrators works for the client and > >> not for me. I don't want the client to reverse engineer my database. > >> There might be other applications on

Re: [GENERAL] Securing Postgres

2005-10-05 Thread Martijn van Oosterhout
On Wed, Oct 05, 2005 at 04:37:38PM +0200, L van der Walt wrote: > Then, I might as well just leave the whole PostgreSQL DB and write my > own mini DB with encrypted XML files. I am sure someone must have an > answer for me. I think you are missing the point. Root is all powerful, end of story.

Re: [GENERAL] Securing Postgres

2005-10-05 Thread Lincoln Yeoh
Uh. Unless you've done something more than what you say, a windows administrator can definitely access the data. Maybe most windows "administrators" don't know how to do it, but it is possible. I've viewed and changed data on a database on Windows without the database administrator username an

Re: [GENERAL] Securing Postgres

2005-10-05 Thread L van der Walt
Richard Huxton wrote: L van der Walt wrote: The big problem is that the administrators works for the client and not for me. I don't want the client to reverse engineer my database. There might be other applications on the server so the administrators do require root access. About the raw d

Re: [GENERAL] Securing Postgres

2005-10-05 Thread Tom Lane
L van der Walt <[EMAIL PROTECTED]> writes: > The big problem is that the administrators works for the client and not > for me. I don't want the client to reverse engineer my database. > There might be other applications on the server so the administrators do > require root access. > About the r

Re: [GENERAL] Securing Postgres

2005-10-05 Thread Stefan 'Kaishakunin' Schumacher
Also sprach L van der Walt ([EMAIL PROTECTED]) > The big problem is that the administrators works for the client and not > for me. I don't want the client to reverse engineer my database. [...] > About the raw database files, I can use encryption to protect the data. How shall the DBMS acces

Re: [GENERAL] Untyped result (setof / rowset) from Functions ?

2005-10-05 Thread Modern Mexican
thanks for the tip, but it would be nice if PG implemented it like MSSQL (very simple and straight forward). Felipe Sandoval Modern Mexican wrote: > Is there a technical reason why an untyped result (setof / rowset) from a > function (sql or plpgsql) is not implemented ? > > Something Simple: >

Re: [GENERAL] Securing Postgres

2005-10-05 Thread Lincoln Yeoh
At 04:48 PM 10/5/2005 +0200, L van der Walt wrote: The big problem is that the administrators works for the client and not for me. I don't want the client to reverse engineer my database. There might be other applications on the server so the administrators do require root access. If it's so

Re: [GENERAL] optimizing common subqueries

2005-10-05 Thread John D. Burger
As I understand it, Postgres's query planner considers only trees of joins - I don't know what the technical implications are of using DAG plans, other than the obvious blowup in planning space. I was recently in a similar situation, where a script essentially needed to do a self-join on the r

Re: [GENERAL] query execution

2005-10-05 Thread codeWarrior
in your postgresql.conf file near the bottom you need to enable statement logging -- set log_statement = 'all' and then you can tail -f /var/logs/postgresql/postgresql.log or tail -f wherever your postgres log is... from the 'Nix command line "Matthew Peter" <[EMAIL PROTECTED]> wrote in messa

Re: [GENERAL] Securing Postgres

2005-10-05 Thread Welty, Richard
L van der Walt wrote: >Then, I might as well just leave the whole PostgreSQL DB and write my >own mini DB with encrypted XML files. I am sure someone must have an >answer for me. i think the answer is that windows is giving you a false sense of security. in an environment where you cannot tr

Re: [GENERAL] Securing Postgres

2005-10-05 Thread Lincoln Yeoh
If you don't trust the administrators you should find someone else to admin your machine. Main question: what do you need the administrators to do for you? If you only need them to do a few things, then it is much easier to limit their access. Because, on most popular systems (e.g. C2-level

Re: [GENERAL] Securing Postgres

2005-10-05 Thread Welty, Richard
L van der Walt writes: >The big problem is that the administrators works for the client and not >for me. I don't want the client to reverse engineer my database. i think you're trying to get native OS security to perform the function of a well crafted legal document. richard -

Re: [GENERAL] selfmade datatype in C and server-crash

2005-10-05 Thread Tom Lane
Markus Schulz <[EMAIL PROTECTED]> writes: > here is the etextin code:(cut'n'paste from adt/varlena.c Code) > Datum > etextin(PG_FUNCTION_ARGS) > { > char *inputText = PG_GETARG_CSTRING(0); > text *result; > int len=0; > /* verify encoding */ > len = strlen(

Re: [GENERAL] Securing Postgres

2005-10-05 Thread Richard_D_Levine
You could look at what SELinux extensions now available in at least the Red Hat (and Fedora) distro offer. I have never done anything with SELinux, and a quick review of the archives indicates it is not a slam dunk to use. It is designed to create the kind of restrictive environment you describe.

Re: [GENERAL] Securing Postgres

2005-10-05 Thread Richard Huxton
L van der Walt wrote: The big problem is that the administrators works for the client and not for me. I don't want the client to reverse engineer my database. There might be other applications on the server so the administrators do require root access. About the raw database files, I can use

Re: [GENERAL] Securing Postgres

2005-10-05 Thread L van der Walt
The big problem is that the administrators works for the client and not for me. I don't want the client to reverse engineer my database. There might be other applications on the server so the administrators do require root access. About the raw database files, I can use encryption to protec

Re: [GENERAL] Cast to integer

2005-10-05 Thread Tom Lane
Robert Osowiecki <[EMAIL PROTECTED]> writes: > Anyone could explain to me, why cast(3.33 to int) works (from float, I > suppose) but cast('3.33' to int) (from text) does not? The latter is not really a cast; it's an invocation of the int datatype's input function. regard

Re: [GENERAL] Securing Postgres

2005-10-05 Thread Richard Huxton
Don't forget to CC: the list! L van der Walt wrote: Example: On a MS Windows Server with MS SQL Server. The administrator with the administrator username and password can not access the SQL server data. He also needs the SA username and password for the SQL server to do so. He can stop an

Re: [GENERAL] Securing Postgres

2005-10-05 Thread L van der Walt
Berend Tober wrote: L van der Walt wrote: I would like to secure Postgres completly. Some issues that I don't know you to fix: 1. User postgres can use psql (...) to do anything. 2. User root can su to postgres and thus do anything. 3. Disable all tools like pg_dump How do I secure a datab

[GENERAL] Securing Postgres

2005-10-05 Thread L van der Walt
Example: On a MS Windows Server with MS SQL Server. The administrator with the administrator username and password can not access the SQL server data. He also needs the SA username and password for the SQL server to do so. He can stop and start the server and so on but not access the data.

Re: [GENERAL] 8.0.1 SRPM on RHEL v.3

2005-10-05 Thread Devrim GUNDUZ
Hi, On Thu, 29 Sep 2005, Shane Dawalt wrote: rpmbuild --rebuild --define 'kerbdir=/usr/kerberos' postgresql-8.0.1-2PGDG.src.rpm I tried this, but it also resulted in not finding kbr5.h. Looking through the Configure log, the '=' on the --define option was actually used as part of the dire

Re: [GENERAL] Securing Postgres

2005-10-05 Thread Berend Tober
L van der Walt wrote: I would like to secure Postgres completly. Some issues that I don't know you to fix: 1. User postgres can use psql (...) to do anything. 2. User root can su to postgres and thus do anything. 3. Disable all tools like pg_dump How do I secure a database if I don't trust t

Re: [GENERAL] Securing Postgres

2005-10-05 Thread Richard Huxton
L van der Walt wrote: I would like to secure Postgres completly. Some issues that I don't know you to fix: 1. User postgres can use psql (...) to do anything. Prevent anyone from logging in as user postgres. Remove psql. 2. User root can su to postgres and thus do anything. That's the ro

Re: [GENERAL] License question[VASCL:A1077160A86]

2005-10-05 Thread Welty, Richard
Neil Dugan wrote: >If I was to develop a 'C' project that only used the libpg.so library and the >rest was my own stuff would I need to preserve the copyright to somehow? >I wouldn't be distributing any source at all just my executable and the >library. license preservation is relevant if you c

Re: [GENERAL] Cast to integer

2005-10-05 Thread A. Kretschmer
am 05.10.2005, um 15:08:33 +0200 mailte Robert Osowiecki folgendes: > Hello! > > Anyone could explain to me, why cast(3.33 to int) works (from float, I > suppose) but cast('3.33' to int) (from text) does not? And what if I > create a cast for that: is it possibly dangerous? test=# select '3.3

Re: [GENERAL] Cast to integer

2005-10-05 Thread Sean Davis
On 10/5/05 9:08 AM, "Robert Osowiecki" <[EMAIL PROTECTED]> wrote: > Hello! > > Anyone could explain to me, why cast(3.33 to int) works (from float, I > suppose) but cast('3.33' to int) (from text) does not? And what if I > create a cast for that: is it possibly dangerous? How about: sdavis=# s

[GENERAL] Securing Postgres

2005-10-05 Thread L van der Walt
I would like to secure Postgres completly. Some issues that I don't know you to fix: 1. User postgres can use psql (...) to do anything. 2. User root can su to postgres and thus do anything. 3. Disable all tools like pg_dump How do I secure a database if I don't trust the administrators. The a

[GENERAL] Cast to integer

2005-10-05 Thread Robert Osowiecki
Hello! Anyone could explain to me, why cast(3.33 to int) works (from float, I suppose) but cast('3.33' to int) (from text) does not? And what if I create a cast for that: is it possibly dangerous? Regards, Robert. ---(end of broadcast)--- TI

Re: [GENERAL] selfmade datatype in C and server-crash

2005-10-05 Thread Markus Schulz
Now i have debugged the _first_ "Insert" Statement in my etextin function cause i got a NULL value for inputText on second insert. now etextin function looks like: Datum etextin(PG_FUNCTION_ARGS) { char *inputText = PG_GETARG_CSTRING(0); text *result; int len=0;

Re: [GENERAL] Or selection on index versus union

2005-10-05 Thread Douglas McNaught
[EMAIL PROTECTED] writes: > PS We still have to be careful how to formulate conditions: > > where fase in ('1','2') > > is ok, and uses the index, but the logically identical: > > where position(fase in '12') >= 1 > > does a sequential scan. Right, you would need a functional index to fix that.

Re: [GENERAL] License question[VASCL:A1077160A86]

2005-10-05 Thread Neil Dugan
On Wednesday 05 October 2005 06:41, Aaron Glenn wrote: > On 10/4/05, Welty, Richard <[EMAIL PROTECTED]> wrote: > > Aaron Glenn wrote: > > >Completely incorrect. You can do whatever you like with PostgreSQL; > > >you just can't sue anyone when things go south. > > > > _and_ you need to preserve the

Re: [GENERAL] selfmade datatype in C and server-crash

2005-10-05 Thread Markus Schulz
On Wednesday 05 October 2005 05:01, Tom Lane wrote: > Markus Schulz <[EMAIL PROTECTED]> writes: > > This works fine and then i've created the new Type like: > > > > CREATE OR REPLACE FUNCTION etextin(cstring) > > RETURNS etext AS > > '$libdir/new_types.so', 'etextin' > > LANGUAGE 'c' VOLATILE;

Re: [GENERAL] Or selection on index versus union

2005-10-05 Thread han . holl
On Tuesday 04 October 2005 23:08, Michael Fuhr wrote: > On Tue, Oct 04, 2005 at 09:32:41PM +0200, [EMAIL PROTECTED] wrote: > > I've got a table with an index, let's call it fase. > > > > The following query is fine: 'select something from table where fase = > > '1'; > > > > However, this is disast

Re: [GENERAL] transaction toggling

2005-10-05 Thread Richard Huxton
Matthew Peter wrote: Is there a way to disable transactions on certian queries? I read a while back that this wasn't possible, just wondering if it is in 8.1 or planned in the future? Does it even make a dent in the performance if a query is wrapped in a transaction instead of out? Such as a v

Re: [GENERAL] transaction toggling

2005-10-05 Thread Martijn van Oosterhout
On Wed, Oct 05, 2005 at 12:49:33AM -0700, Matthew Peter wrote: > Does it even make a dent in the performance if a query > is wrapped in a transaction instead of out? Such as a > view counter, like... > > update views = views + 1 where x = 1;? All statements are within a transaction. The question

Re: [GENERAL] Untyped result (setof / rowset) from Functions ?

2005-10-05 Thread Richard Huxton
Modern Mexican wrote: Is there a technical reason why an untyped result (setof / rowset) from a function (sql or plpgsql) is not implemented ? Something Simple: CREATE FUNCTION foo(x int) RETURNS SETOF records AS 'SELECT t1.*, t2.* FROM t1 INNER JOIN t2 ON t1.a=t2a WHERE WHERE t1.id=$1' LANGUAG

Re: [GENERAL] query execution

2005-10-05 Thread Richard Huxton
Matthew Peter wrote: There a way to watch queries execute on the pgsql server as queries come in from the network and are processed? You could try "SELECT * FROM pg_stat_activity", though it's not guaranteed to be complete. Look in the manuals for the chapter "Monitoring Database Activity".

[GENERAL] Untyped result (setof / rowset) from Functions ?

2005-10-05 Thread Modern Mexican
Is there a technical reason why an untyped result (setof / rowset) from a function (sql or plpgsql) is not implemented ? Something Simple: CREATE FUNCTION foo(x int) RETURNS SETOF records AS 'SELECT t1.*, t2.* FROM t1 INNER JOIN t2 ON t1.a=t2a WHERE WHERE t1.id=$1' LANGUAGE SQL So I will not hav

[GENERAL] transaction toggling

2005-10-05 Thread Matthew Peter
Is there a way to disable transactions on certian queries? I read a while back that this wasn't possible, just wondering if it is in 8.1 or planned in the future? Does it even make a dent in the performance if a query is wrapped in a transaction instead of out? Such as a view counter, like... up

[GENERAL] query execution

2005-10-05 Thread Matthew Peter
There a way to watch queries execute on the pgsql server as queries come in from the network and are processed? Thanks MP __ Yahoo! Mail - PC Magazine Editors' Choice 2005 http://mail.yahoo.com ---(end of broadcast)

Re: [GENERAL] PostgreSQL Database export from Linux to Windows

2005-10-05 Thread A. Kretschmer
am 05.10.2005, um 10:54:47 +0530 mailte Nitin Tarkar folgendes: > Dear All > > Kindly guid us to export PostgreSQL Database from linux to windows. Use pg_dump to export and psql/pg_restore to import. Read the man-page for pg_dump, particulary the different output formats. And, you should use th

[GENERAL] PostgreSQL Database export from Linux to Windows

2005-10-05 Thread Nitin Tarkar
Dear All Kindly guid us to export PostgreSQL Database from linux to windows. Regards Nitin ---(end of broadcast)--- TIP 9: In versions below 8.0, the planner will ignore your desire to choose an index scan if your joining column's datatypes