LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 10-16-2007, 07:25 AM   #1
techie
LQ Newbie
 
Registered: Sep 2007
Posts: 18

Rep: Reputation: 0
MySQL ALTER:-Conditional


I have a tool in mysql.There is a table with 3 columns project id ,issue id and handler id .Ihave to use ALTER acommand in a way that it has some dependency .
In the table i have to autoincrement issue id where project is is 3.
Just to autoincrement issueid the following commands work.
ALTER TABLE tablename AUTOINCREMENT=100.
but to use in the conditional way ,i don't know how to use.
 
Old 10-17-2007, 07:16 AM   #2
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Rocky 9.2
Posts: 18,360

Rep: Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751
I'm pretty sure that the autoincrement attribute only applies to a column, not a table, and it's either on or off. I don't think you can make it conditional, unless you've got v5.1 and use triggers... Strictly speaking that's not autoincrement anyway.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
mysql alter row data kpachopoulos Programming 8 09-26-2007 02:54 AM
MySql ALTER TABLE syntax bulliver Linux - Server 6 08-16-2006 06:12 AM
LXer: Mysql Cluster 5.0 ALTER TABLE In-Depth LXer Syndicated Linux News 0 07-08-2006 10:21 AM
CASE conditional la_mafia63 Linux - General 3 07-24-2005 01:02 PM
c compound conditional steve_96 Programming 9 06-04-2005 07:17 PM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 09:34 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration