Icon View Thread

The following is the text of the current message along with any replies.
Messages 1 to 4 of 4 total
Thread SQL error altering field in EDBManager
Wed, Jan 29 2014 6:39 PMPermanent Link

Adam H.

Hi,

I'm currently running EDB Manager 2.15 B3

When I open up one of my tables that contains an AutoInc field, and try
to change it to a GUID field I get the error:

ElevateDB Error #700 An error was found in the statement at line 2 and
column 22 (Expected SmallInt, Integer, or BigInt expression but instead
found )

The SQL that it generates is:

ALTER TABLE "Customer"
ALTER COLUMN "ID" AS GUID COLLATE "ANSI" GENERATED ALWAYS AS IDENTITY
(START WITH 0, INCREMENT BY 1) NOT NULL

Just wondering if I'm doing something wrong, or if this is a bug?

Thanks & Regards

Adam.
Wed, Jan 29 2014 8:17 PMPermanent Link

Tim Young [Elevate Software]

Elevate Software, Inc.

Avatar

Email timyoung@elevatesoft.com

Adam,

<< When I open up one of my tables that contains an AutoInc field, and try
to change it to a GUID field I get the error: >>

You can't use GUID columns as IDENTITY columns, only INTEGERs.  If you want
an auto-generated GUID column, use this:

ALTER TABLE "Customer"
ALTER COLUMN "ID" AS GUID COLLATE "ANSI" DEFAULT CURRENT_GUID()  NOT NULL

<< ElevateDB Error #700 An error was found in the statement at line 2 and
column 22 (Expected SmallInt, Integer, or BigInt expression but instead
found ) >>

This error message is now fixed, also - it should have said "but instead
GUID found".

Tim Young
Elevate Software
www.elevatesoft.com
Wed, Jan 29 2014 9:59 PMPermanent Link

Adam H.

Hi Tim,

Thanks for that. I guess my concern was that the EDB Manager allowed me
to set those settings, but it failed when applying the changes.

Cheers

Adam.
Fri, Jan 31 2014 6:06 PMPermanent Link

Tim Young [Elevate Software]

Elevate Software, Inc.

Avatar

Email timyoung@elevatesoft.com

Adam,

<< Thanks for that. I guess my concern was that the EDB Manager allowed me
to set those settings, but it failed when applying the changes. >>

I'll see what I can do about that.

Tim Young
Elevate Software
www.elevatesoft.com
Image