Connection from Win machine

Started by Mihai Gheorghiualmost 25 years ago5 messagesgeneral
Jump to latest
#1Mihai Gheorghiu
tanethq@earthlink.net

PostgreSQL 7.1 on RH 7.0; database mydata has a few files created.
Access 95 on Win98 ODBC driver 6.50.00
Access connects to the database but "sees" no tables.
Thanks for the help.

Mihai Gheorghiu

#2Scott Gilbert
scott.gilbert@netregistry.au.com
In reply to: Mihai Gheorghiu (#1)
RE: Connection from Win machine

you need the 7.1 version of the drivers. There is no installer available at
this time (so far as I am aware) so you will need to go to the postgresql
ftp site to download the odbc dll contained in a zip file called
psqlodbc-07_01_0005.zip

Show quoted text

-----Original Message-----
From: pgsql-general-owner@postgresql.org
[mailto:pgsql-general-owner@postgresql.org]On Behalf Of Mihai
Gheorghiu
Sent: Thursday, May 24, 2001 3:59 AM
To: pgsql-general@postgresql.org
Subject: [GENERAL] Connection from Win machine

PostgreSQL 7.1 on RH 7.0; database mydata has a few files created.
Access 95 on Win98 ODBC driver 6.50.00
Access connects to the database but "sees" no tables.
Thanks for the help.

Mihai Gheorghiu

---------------------------(end of
broadcast)---------------------------
TIP 1: subscribe and unsubscribe commands go to
majordomo@postgresql.org

#3Jason
jason@op480.com
In reply to: Scott Gilbert (#2)
Odd "INSERT" Problems with PostgreSQL - Do YOU know?

Hi,

I am using php. When executing a query I do not get an error. However, when
I look at the DB it hasn't added the row and all other rows in the series of
queries have been added.

I've echo'd the $sql statement and actually ran it through the command line
with no problems.

The odd thing is, when I do these queries they do not fail, yet they do not
insert. It still increases the serial primary key ("id") so when I do a
query through the command line the first record for example would start at
12 (becuase i have tried to insert from the php code 12 times prior to
adding it manually).

Any idea on what the prob is?

Here's my sql statement:
$sql = "insert into pricing (prod_id, size_id, price) values ($prod_id,
$size_id, 0.00)";

here's an example of what it generates before it inserts:
insert into pricing (prod_id, size_id, price) values (148, 48, 0.00)

the table pricing has the following columns:
id - primar key/serial
prod_id - int4
size_id - int4
price - float4

Any help would be very much appreciated!

Thanks!

#4Tom Lane
tgl@sss.pgh.pa.us
In reply to: Jason (#3)
Re: Odd "INSERT" Problems with PostgreSQL - Do YOU know?

"Jason" <jason@op480.com> writes:

The odd thing is, when I do these queries they do not fail, yet they do not
insert.

Perhaps the php code is running inside a transaction block? If so, the
added rows won't be visible to other connections until (and unless) the
transaction is committed. The rows *would* be visible to subsequent
commands issued by that same php connection, though --- have you tried
checking that way?

It still increases the serial primary key ("id")

This is consistent with my theory. Sequence-object bumps are
immediately visible regardless of transaction boundaries.

regards, tom lane

#5Mihai Gheorghiu
tanethq@earthlink.net
In reply to: Scott Gilbert (#2)
Re: Connection from Win machine

Thanks a lot,

Mihai

-----Original Message-----
From: Scott Gilbert <scott.gilbert@netregistry.au.com>
To: pgsql-general@postgresql.org <pgsql-general@postgresql.org>
Date: Thursday, May 24, 2001 2:38 AM
Subject: RE: [GENERAL] Connection from Win machine

you need the 7.1 version of the drivers. There is no installer available

at

Show quoted text

this time (so far as I am aware) so you will need to go to the postgresql
ftp site to download the odbc dll contained in a zip file called
psqlodbc-07_01_0005.zip

-----Original Message-----
From: pgsql-general-owner@postgresql.org
[mailto:pgsql-general-owner@postgresql.org]On Behalf Of Mihai
Gheorghiu
Sent: Thursday, May 24, 2001 3:59 AM
To: pgsql-general@postgresql.org
Subject: [GENERAL] Connection from Win machine

PostgreSQL 7.1 on RH 7.0; database mydata has a few files created.
Access 95 on Win98 ODBC driver 6.50.00
Access connects to the database but "sees" no tables.
Thanks for the help.

Mihai Gheorghiu

---------------------------(end of
broadcast)---------------------------
TIP 1: subscribe and unsubscribe commands go to
majordomo@postgresql.org

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