forked from Pygator/murach
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' of https://github.com/Pygator/murach
- Loading branch information
Showing
2,826 changed files
with
291,965 additions
and
0 deletions.
There are no files selected for viewing
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
#/murach/java/db/MurachDB | ||
# ******************************************************************** | ||
# *** Please do NOT edit this file. *** | ||
# *** CHANGING THE CONTENT OF THIS FILE MAY CAUSE DATA CORRUPTION. *** | ||
# ******************************************************************** | ||
#Mon Sep 26 15:06:07 PDT 2011 | ||
SysschemasIndex2Identifier=225 | ||
SyscolumnsIdentifier=144 | ||
SysconglomeratesIndex1Identifier=49 | ||
SysconglomeratesIdentifier=32 | ||
SyscolumnsIndex2Identifier=177 | ||
SysschemasIndex1Identifier=209 | ||
SysconglomeratesIndex3Identifier=81 | ||
SystablesIndex2Identifier=129 | ||
SyscolumnsIndex1Identifier=161 | ||
derby.serviceProtocol=org.apache.derby.database.Database | ||
SysschemasIdentifier=192 | ||
derby.storage.propertiesId=16 | ||
SysconglomeratesIndex2Identifier=65 | ||
derby.serviceLocale=en_US | ||
SystablesIdentifier=96 | ||
SystablesIndex1Identifier=113 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
#!/bin/bash | ||
|
||
# Change to the directory that stores the script | ||
cd /murach/java/db | ||
|
||
# Use the ij tool to run the script | ||
java org.apache.derby.tools.ij MurachDBCreate.sql |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,77 @@ | ||
CONNECT 'jdbc:derby:MurachDB;create=true'; | ||
|
||
-- drop tables (ignore errors if they don't exist) | ||
DROP TABLE Products; | ||
DROP TABLE LineItems; | ||
|
||
-- create Products table | ||
CREATE TABLE Products | ||
( | ||
ProductCode VARCHAR(10), | ||
Description VARCHAR(40), | ||
Price DOUBLE | ||
); | ||
|
||
-- insert data into Products table | ||
INSERT INTO Products VALUES | ||
('bvbn', 'Murach''s Beginning Visual Basic .NET', 49.50); | ||
|
||
INSERT INTO Products VALUES | ||
('cshp', 'Murach''s C#', 49.50); | ||
|
||
INSERT INTO Products VALUES | ||
('java', 'Murach''s Beginning Java', 49.50); | ||
|
||
INSERT INTO Products VALUES | ||
('jsps', 'Murach''s Java Servlets and JSP', 49.50); | ||
|
||
INSERT INTO Products VALUES | ||
('mcb2', 'Murach''s Mainframe COBOL', 59.50); | ||
|
||
INSERT INTO Products VALUES | ||
('sqls', 'Murach''s SQL for SQL Server', 49.50); | ||
|
||
INSERT INTO Products VALUES | ||
('zjcl', 'Murach''s OS/390 and z/OS JCL', 62.50); | ||
|
||
-- view data in Products table | ||
SELECT * FROM Products; | ||
|
||
-- create LineItems table | ||
CREATE TABLE LineItems | ||
( | ||
LineItemID INT, | ||
InvoiceID INT, | ||
ProductCode VARCHAR(10), | ||
Quantity INT | ||
); | ||
|
||
-- insert data into LineItems table | ||
INSERT INTO LineItems VALUES | ||
(1, 1, 'java', 5); | ||
|
||
INSERT INTO LineItems VALUES | ||
(2, 1, 'jsps', 5); | ||
|
||
INSERT INTO LineItems VALUES | ||
(3, 2, 'mcb2', 1); | ||
|
||
INSERT INTO LineItems VALUES | ||
(7, 4, 'cshp', 1); | ||
|
||
INSERT INTO LineItems VALUES | ||
(8, 4, 'zjcl', 2); | ||
|
||
INSERT INTO LineItems VALUES | ||
(9, 6, 'sqls', 1); | ||
|
||
INSERT INTO LineItems VALUES | ||
(10, 6, 'java', 1); | ||
|
||
INSERT INTO LineItems VALUES | ||
(11, 7, 'mcb2', 5); | ||
|
||
-- view data in LineItems table | ||
SELECT * FROM LineItems; | ||
|
||
DISCONNECT; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
CREATE TABLE Products | ||
( | ||
ProductCode VARCHAR(10), | ||
Description VARCHAR(40), | ||
Price DOUBLE | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
DELETE FROM Products; | ||
|
||
INSERT INTO Products VALUES | ||
('bvbn', 'Murach''s Beginning Visual Basic .NET', 49.50); | ||
|
||
INSERT INTO Products VALUES | ||
('cshp', 'Murach''s C#', 49.50); | ||
|
||
INSERT INTO Products VALUES | ||
('java', 'Murach''s Beginning Java', 49.50); | ||
|
||
INSERT INTO Products VALUES | ||
('jsps', 'Murach''s Java Servlets and JSP', 49.50); | ||
|
||
INSERT INTO Products VALUES | ||
('mcb2', 'Murach''s Mainframe COBOL', 59.50); | ||
|
||
INSERT INTO Products VALUES | ||
('sqls', 'Murach''s SQL for SQL Server', 49.50); | ||
|
||
INSERT INTO Products VALUES | ||
('zjcl', 'Murach''s OS/390 and z/OS JCL', 62.50); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
#!/bin/bash | ||
|
||
# Change to the directory that stores the script | ||
cd /murach/java/db | ||
|
||
# Use the ij tool to run the script | ||
java org.apache.derby.tools.ij ProductsTableSelect.sql |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
CONNECT 'jdbc:derby:MurachDB'; | ||
|
||
SELECT ProductCode, Description, Price | ||
FROM Products | ||
WHERE Price > 50 | ||
ORDER BY ProductCode ASC; | ||
|
||
SELECT * FROM Products; | ||
|
||
SELECT p.ProductCode, p.Price, li.Quantity, | ||
p.Price * li.Quantity AS Total | ||
FROM Products p | ||
INNER JOIN LineItems li | ||
ON p.ProductCode = li.ProductCode | ||
WHERE p.Price > 50 | ||
ORDER BY p.ProductCode ASC; | ||
|
||
SELECT p.ProductCode, p.Price, li.Quantity, | ||
p.Price * li.Quantity AS Total | ||
FROM Products p, LineItems li | ||
WHERE p.ProductCode = li.ProductCode AND p.Price > 50 | ||
ORDER BY p.ProductCode ASC; | ||
|
||
DISCONNECT; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
---------------------------------------------------------------- | ||
Wed Sep 28 10:23:49 PDT 2011: | ||
Booting Derby version The Apache Software Foundation - Apache Derby - 10.8.1.2 - (1095077): instance a816c00e-0132-b110-5333-ffffde6e0ee7 | ||
on database directory /murach/java/db/MurachDB with class loader sun.misc.Launcher$ExtClassLoader@543a586d | ||
Loaded from file:/System/Library/Java/Extensions/derby.jar | ||
java.vendor=Oracle Corporation | ||
java.runtime.version=1.7.0-b147-20110926 | ||
user.dir=/murach/java/netbeans/book_apps/ch21_ProductMaint | ||
derby.system.home=/murach/java/db | ||
Database Class Loader started - derby.database.classpath='' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
#!/bin/bash | ||
|
||
# Change to the directory that stores the database | ||
cd /murach/java/db | ||
|
||
# Use the java command to run the ij class in the org.apache.derby.tools package | ||
java org.apache.derby.tools.ij |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
#!/bin/bash | ||
|
||
# Shutdown the Derby network server | ||
java org.apache.derby.drda.NetworkServerControl shutdown |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
#!/bin/bash | ||
|
||
# Change to the directory that stores the database | ||
cd /murach/java/db | ||
|
||
# Start the Derby network server | ||
java org.apache.derby.drda.NetworkServerControl start |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
:: Change to the directory that stores the jar file | ||
cd \murach\java\dist | ||
|
||
:: Use the java command to run the class | ||
java -jar ch23_FutureValueConsole.jar |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
#!/bin/bash | ||
|
||
# Change to the directory that stores the JAR file | ||
cd /murach/java/dist | ||
|
||
#Use the java command to run the JAR file | ||
java -jar ch23_FutureValueConsole.jar |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<jnlp spec="1.0+" | ||
codebase="http://www.murach.com/fv/app" | ||
href="future_value.jnlp"> | ||
<information> | ||
<title>Future Value Calculator</title> | ||
<vendor>Mike Murach & Associates</vendor> | ||
<offline-allowed/> | ||
</information> | ||
<resources> | ||
<!-- Application Resources --> | ||
<j2se version="1.6+" | ||
href="http://java.sun.com/products/autodl/j2se"/> | ||
<jar href="ch23_FutureValueGUI.jar" main="true" /> | ||
</resources> | ||
<application-desc></application-desc> | ||
<update check="background" | ||
policy="prompt-run" /> | ||
</jnlp> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
<!DOCTYPE html> | ||
<html> | ||
<head> | ||
<title>Future Value Calculator</title> | ||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> | ||
</head> | ||
<body> | ||
<h1>Future Value Calculator application</h1> | ||
<a href="future_value.jnlp">Launch application</a> | ||
</body> | ||
</html> |
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
java Murach's Beginning Java 49.5 | ||
jsps Murach's Java Servlets and JSP 49.5 | ||
txtp TextPad 20.0 | ||
mcb2 Murach's Mainframe COBOL 59.5 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
<?xml version="1.0"?><Products><Product Code="java"><Description>Murach's Beginning Java</Description><Price>49.5</Price></Product><Product Code="jsps"><Description>Murach's Java Servlets and JSP</Description><Price>49.5</Price></Product><Product Code="mcb2"><Description>Murach's Mainframe COBOL</Description><Price>59.5</Price></Product></Products> |
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,74 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<!-- You may freely edit this file. See commented blocks below for --> | ||
<!-- some examples of how to customize the build. --> | ||
<!-- (If you delete it and reopen the project it will be recreated.) --> | ||
<!-- By default, only the Clean and Build commands use this build script. --> | ||
<!-- Commands such as Run, Debug, and Test only use this build script if --> | ||
<!-- the Compile on Save feature is turned off for the project. --> | ||
<!-- You can turn off the Compile on Save (or Deploy on Save) setting --> | ||
<!-- in the project's Project Properties dialog box.--> | ||
<project name="ch02_Invoice" default="default" basedir="."> | ||
<description>Builds, tests, and runs the project ch02_Invoice.</description> | ||
<import file="nbproject/build-impl.xml"/> | ||
<!-- | ||
There exist several targets which are by default empty and which can be | ||
used for execution of your tasks. These targets are usually executed | ||
before and after some main targets. They are: | ||
-pre-init: called before initialization of project properties | ||
-post-init: called after initialization of project properties | ||
-pre-compile: called before javac compilation | ||
-post-compile: called after javac compilation | ||
-pre-compile-single: called before javac compilation of single file | ||
-post-compile-single: called after javac compilation of single file | ||
-pre-compile-test: called before javac compilation of JUnit tests | ||
-post-compile-test: called after javac compilation of JUnit tests | ||
-pre-compile-test-single: called before javac compilation of single JUnit test | ||
-post-compile-test-single: called after javac compilation of single JUunit test | ||
-pre-jar: called before JAR building | ||
-post-jar: called after JAR building | ||
-post-clean: called after cleaning build products | ||
(Targets beginning with '-' are not intended to be called on their own.) | ||
Example of inserting an obfuscator after compilation could look like this: | ||
<target name="-post-compile"> | ||
<obfuscate> | ||
<fileset dir="${build.classes.dir}"/> | ||
</obfuscate> | ||
</target> | ||
For list of available properties check the imported | ||
nbproject/build-impl.xml file. | ||
Another way to customize the build is by overriding existing main targets. | ||
The targets of interest are: | ||
-init-macrodef-javac: defines macro for javac compilation | ||
-init-macrodef-junit: defines macro for junit execution | ||
-init-macrodef-debug: defines macro for class debugging | ||
-init-macrodef-java: defines macro for class execution | ||
-do-jar-with-manifest: JAR building (if you are using a manifest) | ||
-do-jar-without-manifest: JAR building (if you are not using a manifest) | ||
run: execution of project | ||
-javadoc-build: Javadoc generation | ||
test-report: JUnit report generation | ||
An example of overriding the target for project execution could look like this: | ||
<target name="run" depends="ch02_Invoice-impl.jar"> | ||
<exec dir="bin" executable="launcher.exe"> | ||
<arg file="${dist.jar}"/> | ||
</exec> | ||
</target> | ||
Notice that the overridden target depends on the jar target and not only on | ||
the compile target as the regular run target does. Again, for a list of available | ||
properties which you can use, check the target you are overriding in the | ||
nbproject/build-impl.xml file. | ||
--> | ||
</project> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
Manifest-Version: 1.0 | ||
X-COMMENT: Main-Class will be added automatically by build | ||
|
Oops, something went wrong.