[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
newbie sql porting question
Hello from a new list member!
First things first: this is (almost certainly) a newbie question so if those
annoy you then i'd stop reading now. I don't wanna get flamed after my first
post !
I should say that I have tried finding the answer in SQL tutorials, the
mysql manual, and in various other places in the web but have failed. i'm
not just being lazy :) However, i may have missed it since my only
experience with mysql has been today (i've used mssql via asp before).
A friend has asked me to try to port his rather complicated ASP/SQL web page
from one hosting service (MS - IIS/SQL 7) to another (LINUX i guess -
Instant ASP (iASP) by halycon - asp.easyspace.com/docs/index.html ). He sent
me an sql file of the currently set up tables on the first server; here's a
bit of that:
<snip>
CREATE TABLE [dbo].[Children] (
[Children_id] [int] IDENTITY (1, 1) NOT NULL ,
[hotel_id] [int] NULL ,
[yrs5] [float] NULL ,
[yrs10] [float] NULL ,
[yrs15] [float] NULL
) ON [PRIMARY]
GO
</snip>
I've figured out that mysql doesn't seem to like the [dbo]. and all the
square brackets: removing these makes the above work 'better'. However, I
can't seem to find an equivalent for the t-sql 'IDENTITY (1, 1) ' property
thing above, as my remote mysql administrator says that theres a syntax
error at this point. I did some research into this bizarre statement and
here's a link i came up with:
http://msdn.microsoft.com/library/psdk/sql/ia-iz_2.htm
which seems to say that this turns the field into an auto-incrementing
identity column. Is there a way of doing the equivalent in mysql? I couldn't
seem to find one in the mysql docs
http://vega.uneec.eurocontrol.fr/mysql/manual.html#SEC60 ) or in my win32
gui remote admin tool (i'm using MySQL Administrator for Windows by David B.
Mansel - thanks david if you're reading this!)
Any help with the above would be greatly appreciated. Is it possible I can
ignore the werd t-sql property or is it possible to duplicate it's
functionality somehow? I'd really appreciate it if some kind soul could
convert the above tsql into valid equivalent mysql but maybe that's asking a
little too much :)
Cheers,
Naveen Rao
--
---------------------------------------------------------------------
Please check "http://www.mysql.com/documentation/manual.php" before
posting. To request this thread, e-mail mysql-thread60315@xxxxxxxxxxxxxxx
To unsubscribe, send a message to:
<mysql-unsubscribe-treed=ultraviolet.org@xxxxxxxxxxxxxxx>
If you have a broken mail client that cannot send a message to
the above address (Microsoft Outlook), you can use:
http://lists.mysql.com/php/unsubscribe.php
This mailing list archive is a service of Copilot Consulting.