addnew in combination with Limt

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: addnew in combination with Limt
Date: 2003-11-21 08:54:36
Message-ID: DB8373C85B90D71191350008C784C739574967@ms-ams-exch02.nl.mcilink.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice

Hi,

I want to use the ADODB object model to do updates etc. But the following
code does not do the update.

Set RST = New ADODB.Recordset
RST.Open "SELECT FldPtrFROM 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.Fields("FldRetVal").Value = "Austin"
RST.Update

Is this a bug in the LIMIT operator?

Thanks,
Fred

Browse pgsql-novice by date

  From Date Subject
Next Message Roy MacGregor Paterson 2003-11-21 14:48:34 Postmaster running, psql not
Previous Message Tom Lane 2003-11-21 07:01:37 Re: SQL statement is too long