JMP® Meets SQL: Using Query Builder for JMP Data Tables Eric Hill, JMP Abstract Example – 4 JMP Tables JMP 13 includes a Query Builder for JMP data tables Join up to 64 tables Filter data interactively and create prompts Query() JSL function lets you write SQL to manipulate JMP data tables Table 4: Avg_SAT_By_State – 51 rows, key “State” Table 3: SAT_Scores – 126,480 rows, key “SSN” Table 1: Big Class – 40 Rows, key “name” Table 2: BC_SocialSecurity – 40 rows, key “Student Name” Next
Adding Tables to the Query 1. Open the data tables 3. Add Tables and Create Joins 2. Launch JMP Query Builder Auto-Join did not succeed Join tables manually Done adding tables Build the query Next
Add additional filters Configuring the Query 9. Examine the generated SQL 5. Select columns to include 8. Save and Run 6. Customize columns 10. Create a prompted query 7. Add Filters Set all filters to “prompt” Examine the generated SQL Add additional filters if desired Save and Close the prompting query Save the query to a file before you run it Run the query Next
Running the Prompting Query 11. Run the query from the Home Window Next
Executing SQL from JSL Find students who performed better than their state average in both Verbal and Math Contact Info: Eric Hill eric.hill@jmp.com Source of data for average SAT scores by state: http://blog.prepscholar.com/average-sat-scores-by-state-most-recent Restart