Win a copy of Modern JavaScript for the Impatient this week in the Server-Side JavaScript and NodeJS forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Bear Bibeault
  • Junilu Lacar
Sheriffs:
  • Jeanne Boyarsky
  • Tim Cooke
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • salvin francis
  • Frits Walraven
Bartenders:
  • Scott Selikoff
  • Piet Souris
  • Carey Brown

create table auto_increment

 
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi,
i have really simple quest. i use netbeans 5.5 and jdbc delivered. i need create new table with field autoincrement. i typed in netbeans sqlcommand:

i got error Error code -1, SQL state 42X01: Syntax error: Encountered "auto_increment" at line 3, column 25.
Line 1, column 1

Execution finished after 0 s, 1 error(s) occurred.

how to create autoincrement field? i tried type AUTO_INCREMENT and auto-increment but the result is the same.
thanks mooses
 
author & internet detective
Posts: 40169
812
Eclipse IDE VI Editor Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Oczek,
This syntax may be database specific. What database are you using?
 
Oczek Oczkowy
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
its a standard database delivered with netbeans tool.i have installed:

Java Platform, Enterprise Edition 5 (Java EE 5) Tools Bundle, Multi-language
Be among the first to take advantage of the ease-of-development features in Java EE 5! The Java EE 5 Tools Bundle, Multi-language is a complete, developer-friendly environment with all necessary runtimes installed and fully configured. Java EE 5 Tools Bundle, Multi-language includes the following components:
NetBeans IDE 5.5, Multi-language
NetBeans Enterprise Pack 5.5, Multi-language
Sun Java System Application Server Platform Edition 9 Update 1, Multi-language
Project Open ESB Starter Kit, Multi-language
Sun Java System Access Manager 7.1 Beta
Java EE 5 Samples
Java BluePrints
API docs (Javadoc)
Your First Cup: An Introduction to the Java EE Platform
 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi
i have the same problem...
i can't set a auto_increment field
someone can help us?

bye
 
The glass is neither half full or half empty. It is too big. But this tiny ad is just right:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
    Bookmark Topic Watch Topic
  • New Topic