Jump to content

1nstan7

Members
  • Posts

    4
  • Joined

  • Last visited

1nstan7's Achievements

Newbie

Newbie (1/7)

0

Reputation

  1. Well Did I do w3schoolhelp and overclock Right? CREATE TABLE W3schoolhelp (aircraft_code CHAR(5) primary key,HTML CHAR(20),);CREATE TABLE Overclock_test(purchase_order_no NUMBER(3) primary key,coding CHAR(4) not null,PC INT(4),CONSTRAINT f_coding FOREIGN KEY (coding}REFERENCES coder(coding) ); I'm not sure if I did the caps or if I missed anything?Also if you look at stackoverflow_help it has overclocking which is a primary key and a Forgien? How do I do that?Anyway all help is appreciated!
  2. 1nstan7

    SQL total help

    Here is an example:quantity | Price | Total_order_price6 $6 $36I have created the quantity and price SQL:CREATE TABLE Ordered_Aircraft(quantity NUMBER(4),price Currency(4));Do I need to make one for total_order_price? If so how do I make it so it get the total price (quantity x Price) Between this is an example. I am trying to get total_order_price from quantity and price, how would I do that?
  3. 1nstan7

    SQL Avg Help

    http://www.w3schools.com/sql/sql_func_avg.asp The example they show is They did AVG(price) which gets the price but then they have "PriceAverage". Is that a new varible? My example table called "purchase": Car price purchase Date smcar £10 01/12/2014 smfar £20 03/12/2014 In my case will this be "SELECT AVG(price) as PriceAverage FROM purchase" ? If so how would I do this and show only purchases after 02/12/2014?
×
×
  • Create New...