Обсуждение: Connecting to Postgres using Rekall

Поиск
Список
Период
Сортировка

Connecting to Postgres using Rekall

От
Susemail
Дата:
I'm using 9.3 and postgresql-8.0.1-6.  I started Rekall  which opens the
database connection wizard.

As the RDBMsS Server Type I pick the only one available:the Rekal PgSQL
Driver (Shouldn't there be drivers for other DB's in the type list also?)

The comment from the Rekal PgSQL driver dialog: 'This driver connects to
PostgrSQL databases (version 7.x).'  Is this a typo? This version is
postgresql-8.0.1-6.

When I use the Yast 'Edit an existing system user  module' to change the
password for the user postgres it's not permanent.  It defaults back to some
unknown six character password.  Does Anyone know what it is?

When I try to connect to the PostgreSQL server I get this message:FATAL: Ident
authentication failed for user "postgres".  Anyone know why this is
happening?
Thanks,
Jerome

ps
I understand that Rekall doesn't create databases.
I don't understand why it should be so difficult to use Rekall to open a
postgresql database and just start using it.  I tried to use Rekall and
PostgreSQl in 9.1,9.2 and 9.3.  In the process I've spoken to people on the
Rekall mailing list and the PostgreSQL list and the Suse list.  I did make
some
progress setting this up in 9.2 but it never worked quite right.  I got the
database in OpenOffice going in minutes and in a half hour I had created 8
tables (from templets).  Why is that so easy and this so hard?  I read the
help
document but it doesn't talk about what to do if things aren't working; it
only talks about what to do if things are working.

Why doesn't Yast change the password for postgresql to what I want it to be?
Why does the user postgres have a default password anyway?
Why is it so hard to find out what that password is?
Why should I have to authenticate myself on a pristine setup?  I'm the first
one to use it, why am I locked out from the very beginning??
Why is all this apparently acceptable to the people who use this software
productively?
What am I missing?

 I really would like to be able to use Rekall and PostgreSQL but for me it's
like being at sea searching for a hidden channel into a safe harbor.  It all
looks like shoreline to me.

Please excuse my frustration and thanks for listening.
I tried to resist but after a few hours of getting absolutely nowhere it's
very difficult.
Jerome

Re: Connecting to Postgres using Rekall

От
Tony Caduto
Дата:
Hi Jerome,
You need to edit the pg_hba.conf file which controls the hosts Postgres will allow to connect.
By default it's set to only allow connections from local host.

pg_hba.conf is located in the data directory of where you installed PG.

You can also tell a host to be TRUSTED, i.e no password needed, if you have not defined any databases yet you might
want
to set it to TRUST so you can connect to template1, then from there you can create a new database.

> When I try to connect to the PostgreSQL server I get this message:FATAL: Ident
> authentication failed for user "postgres".  Anyone know why this is
> happening?
> Thanks,
> Jerome
>


--
Tony Caduto
AM Software Design
Home of PG Lightning Admin for Postgresql 8.x
http://www.amsoftwaredesign.com

= or := ?

От
"Zlatko Matic"
Дата:
Hello.
This is a newbie question: what is the difference between using = and := in
plpgsql function ?
I tried with both and in both cases my function works...
Thanks.

Zlatko


Re: = or := ?

От
Michael Glaesemann
Дата:

On May 9, 2005, at 18:00, Zlatko Matic wrote:

> This is a newbie question: what is the difference between using = and
> := in plpgsql function ?

In pl/pgsql,

:= is assignment
= is a logical comparison for equality

Some languages, such as perl, use = for assignment and == for logical
comparison.

x = 1
is a boolean result

x := 1
gives x the value of 1

Quick example:

    x := 2; -- gives x the value of 2

    IF (x = 1) THEN -- x = 1 is false
        x := 3;  -- skipped
    END IF;
    RETURN X; -- returns 2

Again:
    x := 1; -- gives x the value of 1

    IF (x = 1) THEN -- x = 1 is true
        x := 3;  -- perform assignment
    END IF;
    RETURN x; -- returns 3

Hope this helps.

Michael Glaesemann
grzm myrealbox com


Re: = or := ?

От
Tom Lane
Дата:
Michael Glaesemann <grzm@myrealbox.com> writes:
> On May 9, 2005, at 18:00, Zlatko Matic wrote:
>> This is a newbie question: what is the difference between using = and
>> := in plpgsql function ?

> In pl/pgsql,

> := is assignment
> = is a logical comparison for equality

It looks like the code will in fact allow you to spell an assignment
statement either way ... but I recommend following Michael's advice
for clarity.

            regards, tom lane

Re: = or := ?

От
"Zlatko Matic"
Дата:
thanks.
----- Original Message -----
From: "Michael Glaesemann" <grzm@myrealbox.com>
To: "Zlatko Matic" <zlatko.matic1@sb.t-com.hr>
Cc: <pgsql-general@postgresql.org>
Sent: Monday, May 09, 2005 11:30 AM
Subject: Re: [GENERAL] = or := ?


>
>
> On May 9, 2005, at 18:00, Zlatko Matic wrote:
>
>> This is a newbie question: what is the difference between using = and
>> := in plpgsql function ?
>
> In pl/pgsql,
>
> := is assignment
> = is a logical comparison for equality
>
> Some languages, such as perl, use = for assignment and == for logical
> comparison.
>
> x = 1
> is a boolean result
>
> x := 1
> gives x the value of 1
>
> Quick example:
>
> x := 2; -- gives x the value of 2
>
> IF (x = 1) THEN -- x = 1 is false
> x := 3;  -- skipped
> END IF;
> RETURN X; -- returns 2
>
> Again:
> x := 1; -- gives x the value of 1
>
> IF (x = 1) THEN -- x = 1 is true
> x := 3;  -- perform assignment
> END IF;
> RETURN x; -- returns 3
>
> Hope this helps.
>
> Michael Glaesemann
> grzm myrealbox com
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 1: subscribe and unsubscribe commands go to majordomo@postgresql.org
>