Revision 373
Added by Aaron Marcuse-Kubitza almost 13 years ago
inputs/SALVIAS/verify.0.plots.sql | ||
---|---|---|
1 |
SELECT '# projects' AS "---";
|
|
1 |
SELECT '# projects' AS ___;
|
|
2 | 2 |
SELECT count(*) AS count FROM project; |
3 | 3 |
|
4 |
SELECT '# plot observations' AS "---";
|
|
4 |
SELECT '# plot observations' AS ___;
|
|
5 | 5 |
SELECT count(*) AS count FROM plotevent; |
6 | 6 |
|
7 |
SELECT E'each project\'s # plots' AS "---";
|
|
7 |
SELECT E'each project\'s # plots' AS ___;
|
|
8 | 8 |
SELECT projectname AS project, count(*) AS plots_count |
9 | 9 |
FROM project |
10 | 10 |
JOIN plotevent USING (project_id) |
inputs/SALVIAS/verify.0.plots.ref.sql | ||
---|---|---|
1 |
SELECT '# projects' AS `---`;
|
|
1 |
SELECT '# projects' AS ___;
|
|
2 | 2 |
SELECT count(*) AS count FROM projects; |
3 | 3 |
|
4 |
SELECT '# plot observations' AS `---`;
|
|
4 |
SELECT '# plot observations' AS ___;
|
|
5 | 5 |
SELECT count(*) AS count FROM plotMetadata; |
6 | 6 |
|
7 |
SELECT 'each project\'s # plots' AS `---`;
|
|
7 |
SELECT 'each project\'s # plots' AS ___;
|
|
8 | 8 |
SELECT CAST(plotMetadata.project_id AS char) AS project, count(PlotID) AS plots_count |
9 | 9 |
FROM projects |
10 | 10 |
JOIN plotMetadata ON plotMetadata.project_id = projects.project_id |
inputs/SALVIAS/verify.0.plots.ref | ||
---|---|---|
1 |
---
|
|
1 |
___
|
|
2 | 2 |
# projects |
3 | 3 |
count |
4 | 4 |
23 |
5 |
---
|
|
5 |
___
|
|
6 | 6 |
# plot observations |
7 | 7 |
count |
8 | 8 |
13661 |
9 |
---
|
|
9 |
___
|
|
10 | 10 |
each project's # plots |
11 | 11 |
project plots_count |
12 | 12 |
1 228 |
Also available in: Unified diff
SALVIAS verification: Made statement-label SELECT statements use the same syntax for MySQL and PostgreSQL so they are easy to copy and paste between the input and output queries