Commit 3a07e209 authored by O'Reilly Media, Inc.'s avatar O'Reilly Media, Inc.
Browse files

Initial commit

parents
Loading
Loading
Loading
Loading
+8 −0
Changes for Learning SQL - Working Files/Chapter 01/Basic_Select_Syntax.txt: 8 added lines, 0 removed lines.
Original line number Diff line number Diff line
SELECT 		FIELD(S)
FROM 		TABLES

JOIN 		OTHER TABLES
WHERE		CRITERIA
GROUP BY 	ANY GROUPS
	HAVING	FILTERS FOR GROUPED VALUES
ORDER BY 	SORT ORDER
 No newline at end of file
+20 −0
Changes for Learning SQL - Working Files/Chapter 01/SQL Examples.sql: 20 added lines, 0 removed lines.
Original line number Diff line number Diff line
select * from tblcontacts

select fn, sn, town from tblcontacts

select fn, sn, town from tblcontacts 
order by region

select fn, sn, town from tblcontacts 
where region ='West Yorkshire'


select Region, count(contactid) as Contacts  from tblcontacts
group by Region
having count(contactid)>2
order by count(contactid) desc

select fn, sn, M.MaritalStatus from tblcontacts C
inner join tblMaritalStatus M
on C.maritalstatus=m.maritalstatusid
+1 −0
Changes for Learning SQL - Working Files/Chapter 01/linkforSQLServer.txt: 1 added line, 0 removed lines.
Original line number Diff line number Diff line
http://www.microsoft.com/en-us/download/details.aspx?id=29062
 No newline at end of file
+16 −0
Changes for Learning SQL - Working Files/Chapter 01/onlineSQLTest.txt: 16 added lines, 0 removed lines.
Original line number Diff line number Diff line
BEGIN TRANSACTION;

drop table example;

CREATE TABLE EXAMPLE(Id integer PRIMARY KEY, Heading text, Title text);


INSERT INTO EXAMPLE VALUES(1,'My title','Serious content');
INSERT INTO EXAMPLE VALUES(2,'My title 2','Serious content');
INSERT INTO EXAMPLE VALUES(3,'My Third title','Serious content');
INSERT INTO EXAMPLE VALUES(4,'My Next Title','Serious content');
INSERT INTO EXAMPLE VALUES(5,'My Last','Serious content');
COMMIT;


SELECT * FROM EXAMPLE;
+7 −0
Changes for Learning SQL - Working Files/Chapter 02/No Work Files.rtf: 7 added lines, 0 removed lines.
Original line number Diff line number Diff line
{\rtf1\ansi\ansicpg1252\cocoartf1038\cocoasubrtf350
{\fonttbl\f0\fswiss\fcharset0 Helvetica;}
{\colortbl;\red255\green255\blue255;}
\margl1440\margr1440\vieww9000\viewh8400\viewkind0
\pard\tx720\tx1440\tx2160\tx2880\tx3600\tx4320\tx5040\tx5760\tx6480\tx7200\tx7920\tx8640\ql\qnatural\pardirnatural

\f0\fs24 \cf0 No work files for this lesson...}
 No newline at end of file
Loading