Download presentation
Presentation is loading. Please wait.
1
Creating Databases for Web Applications
Session variables Big Data. Algorithms. Net Neutrality. Decide on basic projects assignments. Homework: Start work on basic assignments. Read articles and find at least one other.
2
SELECT Study Course Announcement on Pop Quiz.
Read for the process of coming up with the answer…how many tables? What are conditions on individual records? These are the WHERE conditions. Assuming more than one table, what is (are) the ON condition(s) ? Is there any GROUPing (aka aggregation)? Are there condition(s) on the groups? Is there any ORDERing? Study one or more of sources found by you and your class mates. Review use of SELECT in examples. Study examples even if you already picked the one you will enhance.
3
Sessions Way to have persistent information for just the session for multiple pages Alternative is to send information via hidden inputs in form or directly composed query string. Kept on server computer, not client computer. In place of cookies (but does use a cookie or http header) $_SESSION will be an associative array for key/value pairs. REQUIREMENT that the session_start(); call be before anything is sent to the browser. This includes any HTML outside (before) the php delimiter!
4
Sessions demo sessionTest.html sessionTest1.php sessionTest2.php
sessionEnd.php Also demonstrates foreach construction for associative array. NOTE: I know the elements in the sessions array and there are just 2, but this is a good way for situations with more and/or unknown key values.
5
sessionTest.html <!DOCTYPE html><html><head> <title>Session demo </title></head> <body> <form action="sessionTest1.php"> Name: <input type=text name='cname'> <input type=submit value="SUBMIT"> </form> </body>
6
sessionTest1.php <?php session_start(); print ("This is just a test for session variables. <br>"); $_SESSION['customer'] = $_GET['cname']; $_SESSION['visits'] = 1; print("Hello, " . $_SESSION['customer']); print(" <br> This is visit number " . $_SESSION['visits']); print("<br> <a href='sessionTest2.php'>GO TO NEXT PAGE </a>"); ?>
7
sessionTest2.php <?php session_start(); print ("demonstrating session variables<br>"); print ("Hello, " . $_SESSION['customer'] ); $visits = $_SESSION['visits']; $visits = $visits + 1; print ("This is visit number $visits"); $_SESSION['visits'] = $visits; print ("<br> <a href='sessionTest2.php'>REPEAT </a> OR <br>"); print ("<a href='sessionTest.html'>START OVER </a> OR <br>"); print ("<a href='sessionEnd.php'>END SESSION</a>"); ?>
8
sessionEnd.php <?php session_start(); print ("Session information was <br>"); if ($_SESSION!="") foreach ($_SESSION as $key=>$val) { print ("$key was $val <br>"); } session_unset(); session_destroy(); ?>
9
Big Data buzz term, mixed meanings Volume, velocity, variability
also Smart technology, Smarter Cities, etc… Volume, velocity, variability Format of data can be key-value pairs, parallel structures, XML, or tables Also, sometimes used in reference to any use of data, aka analytics, represented by Nate Silver combining polls + regression analysis to predict voting in elections
10
What is the data? Data can be collected by an organization
This is the case with the main subject matter of this course: organization creates and manages data in standard (relational) database. OR gathered from variety of sources, some sources may not be [that] well-defined or complete "Everything is trying to tell you something" But what? Correlation is not causation but it may not matter.
11
Articles in popular press
NPR story: revolution-how-number-crunchers-can-predict-our- lives?ft=3&f= &sc=nl&cc=es New York Times article: advertisers-think-you-are.html?pagewanted=all "I am the product not the customer…"
12
More All Google data, but gathered uncontrolled process:
holiday-gift-searches.html About job hunting: headhunter-big-data-hr-means-big-problems-job- seekers/
13
More Book reviews: Big Data html#printMode To Save Everything, Click Here everything-click-here.html Government proposals: press-office/2015/01/12/fact-sheet-safeguarding-american- consumers-families
14
Algorithms … used for decision making College acceptance Jobs
Sentencing, parole Populations to market to For loans Decisions on loans What else?
15
Basis of (for) Algorithms
May be data, "Big", otherwise Training set Sample ? Potential for problems in the data
16
Responses Weapons of Math Destruction by Cathy O'Neal
May be articles, blog Response from ACM (computing professional society) ithms.pdf
17
Net Neutrality What does this mean? What is status as of today?
For you, for companies, for potential for growth & innovation What is status as of today?
18
Classwork / Homework Finalize teams
One team member makes posting confirming team members Read articles cited or find your own, for example, recent article on use of Algorithms for decision making or Net Neutrality. Report on moodle (Introductions, etc. forum) Take an informed position
Similar presentations
© 2024 SlidePlayer.com. Inc.
All rights reserved.