Issue 18438 - unable to create auto-increment fields in MySQL-ODBC database
Summary: unable to create auto-increment fields in MySQL-ODBC database
Status: CLOSED FIXED
Alias: None
Product: Base
Classification: Application
Component: code (show other issues)
Version: OOo 1.1 RC2
Hardware: PC Linux, all
: P3 Trivial (vote)
Target Milestone: ---
Assignee: marc.neumann
QA Contact: issues@dba
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-08-20 10:26 UTC by bryancole
Modified: 2006-05-31 14:29 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: ---
Developer Difficulty: ---


Attachments

Note You need to log in before you can comment on or make changes to this issue.
Description bryancole 2003-08-20 10:26:03 UTC
Hi,

I'm unable to create a table with an auto-increment field for the primary key
(or for any other field). I'm using OOo-v1.1rc2, MySQL-3.23.56, MyODBC-2.50.39
and unixODBC-2.2.3. The OOo-specifications seem to indicate this *should* be
possible so I think this is a defect. I've got "auto_increment" and
"last_insert_id()" in the appropriate fields in the ODBC setup dialog.

Is auto-increment field creation possible or not? It's hard to tell from the
OO-docs.

If I create a table outside of OOo with an auto-increment field, this is shown
as <auto> in the OO Tables view, and works as expected.

cheers,
Bryan
Comment 1 Frank Schönheit 2003-08-20 11:59:23 UTC
correcting sub component
(http://www.openoffice.org/issues/describecomponents.cgi?component=database%20access)
and default owner
Comment 2 Frank Schönheit 2003-08-20 12:02:57 UTC
bryan, could you try if using the "MySQL" type for the data source
(instead of the "ODBC" type) changes anything? Thanks.
Comment 3 bryancole 2003-08-20 14:49:48 UTC
I already tried this. No, using Database type: MySQL doesn't work. 

In fact, when using the MySQL type, there are no options for
specifying "retrieve generated values" (i.e. entering "auto_increment"
and "last_insert_id()"). Existing auto-increment fields don't work at
all with the "MySQL" database type, one has to use ODBC.

Bryan
Comment 4 bryancole 2003-11-17 11:17:22 UTC
After upgrading to MyODBC-3.51, I've noticed the appearance of new
column-type options in the Table Design window which specify
'Auto_increment'. Everything works as it should. 

This was probably never an OpenOffice issue, but a MyODBC one, but
sometimes it's hard to tell.

Thus, I'll set this issue to 'fixed'

Bryan
Comment 5 marc.neumann 2003-11-19 09:38:25 UTC
Hi,

so I close this issue.

Bye Marc
Comment 6 hans_werner67 2004-02-02 12:14:35 UTC
change subcomponent to 'none'