BUS 464 Lecture Notes - Lecture 2: Regular Expression
Document Summary
#drop command will erase that table drop table share; #create command is used to create a new table, and all of the columns for it. #you can insert data into the table using insert statements like this. Insert into share (shrcode, shrfirm, shrprice, shrqty, shrdiv, shrpe) #or you can import data into the table from a text file. #select lets you display records from the table. #project creates a new table from the columns of an existing table. #restricts the new table to those rows that satisfy a specified condition. Select * from share where shrpe < 12; #use both project and restrict in the same statement. Select * from share where shrcode = "ar"; Select * from share where shrdiv = 2. 5; #not in is for finding ones that don"t match. Select * from share where shrcode not in (" cs"," pt"); Select * from share where shrpe >= 10 order by shrpe desc, shrfirm;