| From: | "Vellinga, Fred" <fred(dot)vellinga(at)nl(dot)mci(dot)com> |
|---|---|
| To: | "'pgsql-novice(at)postgresql(dot)org'" <pgsql-novice(at)postgresql(dot)org> |
| Subject: | RST.Addnew in combination with Limit 1. |
| Date: | 2003-11-24 14:42:52 |
| Message-ID: | DB8373C85B90D71191350008C784C739574988@ms-ams-exch02.nl.mcilink.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-novice |
Hi,
I want to use the ADODB object model to do updates etc. I use MSaccess as
frontend, but I guess it will fail on any frontend that supports ADODB.
However the following code does not do the update.
Set RST = New ADODB.Recordset
RST.Open "SELECT FldPtr FROM TblTown LIMIT 1;", CNN, adOpenKeyset,
adLockOptimistic, adCmdText
RST.AddNew
RST.Fields("FldPtr").Value = 1
RST.Update
The following does however the work:
Set RST = New ADODB.Recordset
RST.Open "SELECT FldPtr FROM TblTown;", CNN, adOpenKeyset, adLockOptimistic,
adCmdText
RST.AddNew
RST.Fields("FldPtr").Value = 1
RST.Update
Is this a bug in the LIMIT operator? The advantage of LIMIT 1 is that only
one record in sent over the wire. The code fails at the moment the
RST.update statement is called.
Anyway, I am new to PostgreSQL, but the ADODB works very fine with
PostgreSQL.
Thanks,
Fred
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Tom Ansley | 2003-11-24 23:50:27 | Retrieving Array Datatype in Java |
| Previous Message | Giovanni Mattamira | 2003-11-24 09:45:14 | Name of server SSL key and certificate in version 7.4 |