Subject Re: [firebird-support] cannot insert row
Author David Johnson
The query may not be returning an updatable result set.

If I recall correctly, updatable result sets are optional in the SQL
standards, with some very strict rules governing when they are allowed.
Firebird 1.5 is more stringent about many of the rules than earlier
versions of the engine have been.

Personally, I never use updatable result sets because I cannot afford to
hold on to tables while a user makes up their mind. I must commit my
transactions so the insert/update is a new transaction. Use of
TClientDataset simplifies this process.

Refactoring to separate insert/update from select queries should not be
too bad in most apps, and it should improve your scalability and
performance consistency under heavy loads.

Ann, Helen, or Arno might understand better why your specific queries
are not returning updatable results. Post the select SQL - the answer
might lie there.

Good Luck!


On Fri, 2005-07-01 at 12:01 +0000, newgen_315 wrote:
> Sorry for the double post but I am desperate,
>
> I need help badly, I do not understand this problem at all. the error
> is 'Cannot insert a new row' which seems to occur after the database
> is created.
>
> It's created with a sql script which I have been using forever
> I even install FB1.5 server, removed empbedded server, same problem.
> request live is set to true for all iboqueries
>
> has anyone seen this before
> help please
> Daniel
>
> procedure TIB_Dataset.Insert;
> begin
> if not Prepared then
> SysPrepare;
> if CanInsert then
> SysInsert
> else
> begin
> SysStateChanged;
> ==> raise EIB_DatasetError.Create( E_Cannot_Insert_Row );
> end;
> end;
>
>
>
>
>
>
> ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
>
> Visit http://firebird.sourceforge.net and click the Resources item
> on the main (top) menu. Try Knowledgebase and FAQ links !
>
> Also search the knowledgebases at http://www.ibphoenix.com
>
> ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
>
> Yahoo! Groups Links
>
>
>
>
>