You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Fix "under" date semantics in oracle queries and add --all to generation scripts
Q80 and Q107 incorrectly used date ranges meaning "before year X" instead
of "during year X" (Swedish "under"). Changed to use YEAR() consistently.
Q106 also migrated from date range to YEAR() for consistency. Removed
legacy extract-oracle.ts, added --all flag to generate-language.ts and
generate-erd.ts, simplified generate-all script, and updated README with
architecture docs.
Copy file name to clipboardExpand all lines: README.md
+39-1Lines changed: 39 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -10,17 +10,55 @@ SQL Validator is a fully client-side web application powered by sql.js. Designed
10
10
-**Question Highlighting**: Started and completed questions are highlighted in the question selector making it easy to track progress.
11
11
-**Import/Export Data**: Import and export queries and views to file for sharing and/or backups.
12
12
-**Image Export**: Export queries and views as images in light mode for assignment submission.
13
+
-**Multi-Language Support**: Full i18n support with Swedish and English included. Adding a new language only requires a new language pack file.
13
14
14
15
## Usage
15
16
### Public Deployment
16
17
A public instance of SQL Validator is available at [https://sql-validator.e-su.se](https://sql-validator.e-su.se), powered with Cloudflare Pages.
17
18
18
19
### Running Locally
19
-
To deploy SQL Validator locally, follow these steps:
20
20
1. Clone the repository: `git clone https://github.com/Edwinexd/sql-validator.git`
21
21
2. Install dependencies: `npm install`
22
22
3. Start the development server: `npm start`
23
23
24
+
## Architecture
25
+
### Oracle System
26
+
The **oracle** (`data/oracle.json`) is the single source of truth for the database schema, canonical data, and all 110 reference SQL queries. It uses language-agnostic placeholders (e.g. `{{table:Person}}`, `{{col:Person.city}}`, `{{city:6}}`) that are resolved at generation time using a language pack.
27
+
28
+
The oracle is encrypted (`data/oracle.enc`) before committing so students cannot see the answers.
29
+
30
+
### Language Packs
31
+
Language definitions live in `languages/` (e.g. `sv.ts`, `en.ts`). Each pack provides:
0 commit comments