We help IT Professionals succeed at work.

We've partnered with Certified Experts, Carl Webster and Richard Faulkner, to bring you a podcast all about Citrix Workspace, moving to the cloud, and analytics & intelligence. Episode 2 coming soon!Listen Now

x

How do I create a table using mySQL or winSQL?

nismoz
nismoz asked
on
Medium Priority
2,044 Views
Last Modified: 2012-08-13
I need help making tables with either mySQL or winSQL.

Create the -Pilot- table with the following fields,

PilotID (integer sequence) and Primary Key
NameLast (required)
NameInit
NameFirst
Birthday
Sex
StreetAddress
City
State
Zip
Phone
Rank

From there I can figure out the rest if somebody could show me an example of this. Thanks
Comment
Watch Question

Technical Lead
Commented:
Hi,

You can execute the query through phpMyAdmin, MySQL CLI or your favourite database administration tool (HeidiSQL or Navicat MySQL).

Hope this helps!
CREATE TABLE `vixenhd`.`Pilot` (
`PilotID` MEDIUMINT UNSIGNED AUTO_INCREMENT, 
`NameLast` VARCHAR (100) NOT NULL, 
`NameInit` VARCHAR (10), 
`NameFirst` VARCHAR (100), 
`Birthday` BIGINT UNSIGNED, 
`Sex` VARCHAR (5), 
`StreetAddress` TEXT, 
`City` VARCHAR (50), 
`State` VARCHAR (10), 
`Zip` TINYINT UNSIGNED, 
`Phone` VARCHAR (100), 
`Rank` TINYINT UNSIGNED, 
PRIMARY KEY(`PilotID`)) TYPE = MyISAM 

Open in new window

Not the solution you were looking for? Getting a personalized solution is easy.

Ask the Experts
Bruce PieterseTechnical Lead

Commented:
Oh yes, where vixenhd on line 1 is, replace it with the database name that you will be using.

Author

Commented:
Thanks!  I will try it out later this evening and let you know how it turns out.
Access more of Experts Exchange with a free account
Thanks for using Experts Exchange.

Create a free account to continue.

Limited access with a free account allows you to:

  • View three pieces of content (articles, solutions, posts, and videos)
  • Ask the experts questions (counted toward content limit)
  • Customize your dashboard and profile

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

OR

Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.