Re: DAO VB ODBC "read only problems

From: "Miller, Sam" <sam(dot)miller(at)intel(dot)com>
To: Hiroshi Inoue <Inoue(at)tpf(dot)co(dot)jp>, "Miller, Sam" <sam(dot)miller(at)intel(dot)com>
Cc: pgsql-interfaces(at)postgresql(dot)org
Subject: Re: DAO VB ODBC "read only problems
Date: 2001-10-30 06:43:26
Message-ID: 794826DE8867D411BAB8009027AE9EB9135B6EE9@FMSMSX38
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-interfaces

Hiroshi and others,

I added:
wrkODBC.DefaultCursorDriver=dbUseODBCCursor
after the "Set wrkODBC....." line.

Still doesn't work. Any more ideas?

I discovered I am using postgresql-7.0.2-17, could that be the problem?
(The ODBC driver is at 7.01.0007)

Getting desperate,

Sam

-----Original Message-----
From: Hiroshi Inoue [mailto:Inoue(at)tpf(dot)co(dot)jp]
Sent: Monday, October 29, 2001 4:40 PM
To: Miller, Sam
Cc: pgsql-interfaces(at)postgresql(dot)org
Subject: Re: [INTERFACES] DAO VB ODBC "read only problems

"Miller, Sam" wrote:
>
> Folks,
>
> I am having great difficulty getting a VB script (Excel) to talk to a
linux
> based PostgreSQL server. I can read data just fine but get the following
> error when I try to edit:
>
> Next line produces error:
> Run-time error '3027';
> Connot update. Database or object is read-only
>
> I have done the following so far:
>
> 1. Created a table with a "PRIMARY KEY" as:
> CREATE TABLE data2 (
> x integer,
> y integer,
> symbol varchar(15),
> pin varchar(15) primary key);
>
> 2. Made sure that the select statement does not end in a semi-colon.
>
> 3. Created the following table (don't think this is necessary).. but I saw
> something that mentioned it:
> CREATE TABLE "msysconf" (
> "config" int2 NOT NULL,
> "chvalue" character varying,
> "nvalue" int4,
> "comments" character varying);
>
> 4. Verified that the "read only" check box is not checked in the
PostgreSQL
> ODBC Advanced Options
>
> 5. Checked both "show columns" and "fake index" in the OID options section
> of the Data Source advanced options.
>
> 6. Tried dbOpenSnapshot option (??? static cursor) on the OpenRecordset
> method (also tried without).
>
> I don't know what else to try,
> Anyone have any ideas? (VB code below)
>

Unfortunately psqlodbc driver doesn't implement updatable
cursors. Probably you have to set DefaultCursorDriver property
of the ODBCDirect workspace as dbUseODBCCursor.

regards,
Hiroshi Inoue

Responses

Browse pgsql-interfaces by date

  From Date Subject
Next Message Hiroshi Inoue 2001-10-30 06:55:36 Re: DAO VB ODBC "read only problems
Previous Message Hiroshi Inoue 2001-10-30 00:39:31 Re: DAO VB ODBC "read only problems