The consolidated copy-paste script for running the whole demonstration on your own Virtuoso. Its purpose is execution, not exposition: the same statements as the seven cards above in the order a fresh database needs them. The table and row statements are standard SQL; the IRI class and quad map statements are Virtuoso-specific and are the part most likely to need adjusting on another version. Two grants name accounts that exist on demo.openlinksw.com and should be dropped elsewhere.
-- scalekg-scale-ai-production.sql
-- Consolidated batch for the ScaleKG estate used by the Neo4j "Scale AI into production" meshup.
-- Run: isql <host>:1111 <user> <password> < scalekg-scale-ai-production.sql
-- or paste into Virtuoso Conductor > Database > Interactive SQL.
-- Order: tables, rows, IRI classes, ontology, the RDF View (quad map), grants, URL rewrite rules. Every statement below was
-- executed on demo.openlinksw.com as user kidehen; the data is synthetic and illustrative.
-- Part 1 (tables, rows, grants) is standard SQL. Parts 2 and 3 (CREATE IRI CLASS and ALTER QUAD
-- STORAGE) are Virtuoso-specific and need the SPARQL keyword in front when sent through isql.
-- ── Part 1a: tables ─────────────────────────────────────────────────────────
CREATE TABLE ScaleKG.kidehen.region (region_id INTEGER NOT NULL PRIMARY KEY, region_name VARCHAR(64) NOT NULL, cloud VARCHAR(16) NOT NULL, country_code VARCHAR(2) NOT NULL);
CREATE TABLE ScaleKG.kidehen.db_cluster (cluster_id INTEGER NOT NULL PRIMARY KEY, cluster_name VARCHAR(64) NOT NULL, region_id INTEGER NOT NULL, cluster_role VARCHAR(16) NOT NULL, ram_gb INTEGER NOT NULL, storage_gb INTEGER NOT NULL, edition VARCHAR(32) NOT NULL, FOREIGN KEY (region_id) REFERENCES ScaleKG.kidehen.region (region_id));
CREATE TABLE ScaleKG.kidehen.tenant (tenant_id INTEGER NOT NULL PRIMARY KEY, tenant_name VARCHAR(64) NOT NULL, tier VARCHAR(16) NOT NULL, region_id INTEGER NOT NULL, FOREIGN KEY (region_id) REFERENCES ScaleKG.kidehen.region (region_id));
CREATE TABLE ScaleKG.kidehen.environment (env_id INTEGER NOT NULL PRIMARY KEY, env_name VARCHAR(16) NOT NULL);
CREATE TABLE ScaleKG.kidehen.graph_database (db_id INTEGER NOT NULL PRIMARY KEY, db_name VARCHAR(64) NOT NULL, cluster_id INTEGER NOT NULL, tenant_id INTEGER NOT NULL, env_id INTEGER NOT NULL, purpose VARCHAR(96) NOT NULL, FOREIGN KEY (cluster_id) REFERENCES ScaleKG.kidehen.db_cluster (cluster_id), FOREIGN KEY (tenant_id) REFERENCES ScaleKG.kidehen.tenant (tenant_id), FOREIGN KEY (env_id) REFERENCES ScaleKG.kidehen.environment (env_id));
CREATE TABLE ScaleKG.kidehen.replication_link (link_id INTEGER NOT NULL PRIMARY KEY, source_db_id INTEGER NOT NULL, target_db_id INTEGER NOT NULL, sync_mode VARCHAR(32) NOT NULL, topology VARCHAR(16) NOT NULL, rbac_replicated INTEGER NOT NULL, FOREIGN KEY (source_db_id) REFERENCES ScaleKG.kidehen.graph_database (db_id), FOREIGN KEY (target_db_id) REFERENCES ScaleKG.kidehen.graph_database (db_id));
CREATE TABLE ScaleKG.kidehen.warehouse_source (src_id INTEGER NOT NULL PRIMARY KEY, src_name VARCHAR(32) NOT NULL, vendor VARCHAR(32) NOT NULL);
CREATE TABLE ScaleKG.kidehen.warehouse_table (wt_id INTEGER NOT NULL PRIMARY KEY, src_id INTEGER NOT NULL, table_name VARCHAR(32) NOT NULL, row_count INTEGER NOT NULL, FOREIGN KEY (src_id) REFERENCES ScaleKG.kidehen.warehouse_source (src_id));
CREATE TABLE ScaleKG.kidehen.workload (wl_id INTEGER NOT NULL PRIMARY KEY, wl_name VARCHAR(64) NOT NULL, wl_kind VARCHAR(16) NOT NULL, tenant_id INTEGER NOT NULL, db_id INTEGER, src_id INTEGER, latency_class VARCHAR(16) NOT NULL, FOREIGN KEY (tenant_id) REFERENCES ScaleKG.kidehen.tenant (tenant_id), FOREIGN KEY (db_id) REFERENCES ScaleKG.kidehen.graph_database (db_id), FOREIGN KEY (src_id) REFERENCES ScaleKG.kidehen.warehouse_source (src_id));
CREATE TABLE ScaleKG.kidehen.workload_reads (wl_id INTEGER NOT NULL, wt_id INTEGER NOT NULL, PRIMARY KEY (wl_id, wt_id), FOREIGN KEY (wl_id) REFERENCES ScaleKG.kidehen.workload (wl_id), FOREIGN KEY (wt_id) REFERENCES ScaleKG.kidehen.warehouse_table (wt_id));
CREATE TABLE ScaleKG.kidehen.analytics_job (job_id INTEGER NOT NULL PRIMARY KEY, db_id INTEGER NOT NULL, job_kind VARCHAR(24) NOT NULL, run_date DATE NOT NULL, billed_seconds INTEGER NOT NULL, FOREIGN KEY (db_id) REFERENCES ScaleKG.kidehen.graph_database (db_id));
-- ── Part 1b: rows (76) ──────────────────────────────────────────────────────
INSERT INTO ScaleKG.kidehen.region VALUES (1, 'gcp-us-central1', 'Google Cloud', 'US');
INSERT INTO ScaleKG.kidehen.region VALUES (2, 'gcp-europe-west4', 'Google Cloud', 'NL');
INSERT INTO ScaleKG.kidehen.region VALUES (3, 'aws-us-east-1', 'AWS', 'US');
INSERT INTO ScaleKG.kidehen.region VALUES (4, 'azure-westeurope', 'Azure', 'NL');
INSERT INTO ScaleKG.kidehen.db_cluster VALUES (1, 'graph-bc-prod-us', 1, 'primary', 2048, 5000, 'business-critical');
INSERT INTO ScaleKG.kidehen.db_cluster VALUES (2, 'graph-bc-dr-eu', 2, 'secondary', 512, 1500, 'business-critical');
INSERT INTO ScaleKG.kidehen.db_cluster VALUES (3, 'graph-vdc-shared', 3, 'primary', 256, 1000, 'virtual-dedicated');
INSERT INTO ScaleKG.kidehen.db_cluster VALUES (4, 'graph-selfmanaged-eu', 4, 'primary', 128, 800, 'self-managed-enterprise');
INSERT INTO ScaleKG.kidehen.tenant VALUES (1, 'Acme Retail', 'enterprise', 1);
INSERT INTO ScaleKG.kidehen.tenant VALUES (2, 'Borealis Bank', 'enterprise', 1);
INSERT INTO ScaleKG.kidehen.tenant VALUES (3, 'Cobalt Health', 'enterprise', 1);
INSERT INTO ScaleKG.kidehen.tenant VALUES (4, 'Dunmore Logistics', 'growth', 3);
INSERT INTO ScaleKG.kidehen.tenant VALUES (5, 'Ember Media', 'growth', 3);
INSERT INTO ScaleKG.kidehen.tenant VALUES (6, 'Fjord Energy', 'enterprise', 4);
INSERT INTO ScaleKG.kidehen.environment VALUES (1, 'dev');
INSERT INTO ScaleKG.kidehen.environment VALUES (2, 'test');
INSERT INTO ScaleKG.kidehen.environment VALUES (3, 'staging');
INSERT INTO ScaleKG.kidehen.environment VALUES (4, 'prod');
INSERT INTO ScaleKG.kidehen.graph_database VALUES (1, 'acme_prod', 1, 1, 4, 'customer-360 knowledge graph');
INSERT INTO ScaleKG.kidehen.graph_database VALUES (2, 'acme_staging', 1, 1, 3, 'customer-360 staging');
INSERT INTO ScaleKG.kidehen.graph_database VALUES (3, 'acme_dev', 3, 1, 1, 'customer-360 development');
INSERT INTO ScaleKG.kidehen.graph_database VALUES (4, 'borealis_prod', 1, 2, 4, 'fraud-ring detection');
INSERT INTO ScaleKG.kidehen.graph_database VALUES (5, 'borealis_test', 3, 2, 2, 'fraud-ring detection test');
INSERT INTO ScaleKG.kidehen.graph_database VALUES (6, 'cobalt_prod', 1, 3, 4, 'clinical-trial knowledge domain');
INSERT INTO ScaleKG.kidehen.graph_database VALUES (7, 'cobalt_agent_kb', 1, 3, 4, 'agent knowledge domain: trial protocols');
INSERT INTO ScaleKG.kidehen.graph_database VALUES (8, 'dunmore_prod', 3, 4, 4, 'route network graph');
INSERT INTO ScaleKG.kidehen.graph_database VALUES (9, 'dunmore_analytics', 3, 4, 4, 'analytical graph kept apart from transactional');
INSERT INTO ScaleKG.kidehen.graph_database VALUES (10, 'ember_prod', 3, 5, 4, 'content graph');
INSERT INTO ScaleKG.kidehen.graph_database VALUES (11, 'ember_dev', 3, 5, 1, 'content graph development');
INSERT INTO ScaleKG.kidehen.graph_database VALUES (12, 'fjord_prod', 4, 6, 4, 'asset dependency graph');
INSERT INTO ScaleKG.kidehen.graph_database VALUES (13, 'fjord_staging', 4, 6, 3, 'asset dependency staging');
INSERT INTO ScaleKG.kidehen.graph_database VALUES (14, 'acme_prod_replica', 2, 1, 4, 'replica of acme_prod');
INSERT INTO ScaleKG.kidehen.graph_database VALUES (15, 'borealis_prod_replica', 2, 2, 4, 'replica of borealis_prod');
INSERT INTO ScaleKG.kidehen.graph_database VALUES (16, 'cobalt_prod_replica', 2, 3, 4, 'replica of cobalt_prod');
INSERT INTO ScaleKG.kidehen.replication_link VALUES (1, 1, 14, 'transaction-pull', 'active-passive', 0);
INSERT INTO ScaleKG.kidehen.replication_link VALUES (2, 4, 15, 'differential-backup-pull', 'active-passive', 0);
INSERT INTO ScaleKG.kidehen.replication_link VALUES (3, 6, 16, 'transaction-pull', 'active-passive', 0);
INSERT INTO ScaleKG.kidehen.warehouse_source VALUES (1, 'Snowflake', 'Snowflake Inc.');
INSERT INTO ScaleKG.kidehen.warehouse_source VALUES (2, 'Databricks', 'Databricks Inc.');
INSERT INTO ScaleKG.kidehen.warehouse_source VALUES (3, 'BigQuery', 'Google');
INSERT INTO ScaleKG.kidehen.warehouse_table VALUES (1, 1, 'CUSTOMERS', 2400000);
INSERT INTO ScaleKG.kidehen.warehouse_table VALUES (2, 1, 'ORDERS', 18000000);
INSERT INTO ScaleKG.kidehen.warehouse_table VALUES (3, 1, 'PRODUCTS', 85000);
INSERT INTO ScaleKG.kidehen.warehouse_table VALUES (4, 2, 'CLAIMS', 6200000);
INSERT INTO ScaleKG.kidehen.warehouse_table VALUES (5, 2, 'PROVIDERS', 41000);
INSERT INTO ScaleKG.kidehen.warehouse_table VALUES (6, 3, 'SHIPMENTS', 9300000);
INSERT INTO ScaleKG.kidehen.warehouse_table VALUES (7, 3, 'DEPOTS', 620);
INSERT INTO ScaleKG.kidehen.warehouse_table VALUES (8, 2, 'TRANSACTIONS', 51000000);
INSERT INTO ScaleKG.kidehen.warehouse_table VALUES (9, 2, 'ACCOUNTS', 1800000);
INSERT INTO ScaleKG.kidehen.workload VALUES (1, 'support-copilot', 'agent', 1, 1, NULL, 'millisecond');
INSERT INTO ScaleKG.kidehen.workload VALUES (2, 'warehouse-graphrag', 'graphrag', 1, NULL, 1, 'second');
INSERT INTO ScaleKG.kidehen.workload VALUES (3, 'fraud-ring-scorer', 'agent', 2, 4, NULL, 'millisecond');
INSERT INTO ScaleKG.kidehen.workload VALUES (4, 'txn-multihop-explorer', 'graphrag', 2, NULL, 2, 'second');
INSERT INTO ScaleKG.kidehen.workload VALUES (5, 'trial-protocol-agent', 'agent', 3, 7, NULL, 'millisecond');
INSERT INTO ScaleKG.kidehen.workload VALUES (6, 'claims-enrichment-batch', 'analytics', 3, NULL, 2, 'second');
INSERT INTO ScaleKG.kidehen.workload VALUES (7, 'route-optimizer', 'saas-app', 4, 8, NULL, 'millisecond');
INSERT INTO ScaleKG.kidehen.workload VALUES (8, 'shipment-analyst', 'graphrag', 4, NULL, 3, 'second');
INSERT INTO ScaleKG.kidehen.workload VALUES (9, 'content-recs', 'saas-app', 5, 10, NULL, 'millisecond');
INSERT INTO ScaleKG.kidehen.workload VALUES (10, 'asset-dependency-agent', 'agent', 6, 12, NULL, 'millisecond');
INSERT INTO ScaleKG.kidehen.workload_reads VALUES (2, 1);
INSERT INTO ScaleKG.kidehen.workload_reads VALUES (2, 2);
INSERT INTO ScaleKG.kidehen.workload_reads VALUES (2, 3);
INSERT INTO ScaleKG.kidehen.workload_reads VALUES (4, 8);
INSERT INTO ScaleKG.kidehen.workload_reads VALUES (4, 9);
INSERT INTO ScaleKG.kidehen.workload_reads VALUES (6, 4);
INSERT INTO ScaleKG.kidehen.workload_reads VALUES (6, 5);
INSERT INTO ScaleKG.kidehen.workload_reads VALUES (8, 6);
INSERT INTO ScaleKG.kidehen.workload_reads VALUES (8, 7);
INSERT INTO ScaleKG.kidehen.analytics_job VALUES (1, 1, 'ml-feature-prep', stringdate('2026-09-20'), 5400);
INSERT INTO ScaleKG.kidehen.analytics_job VALUES (2, 4, 'entity-resolution', stringdate('2026-09-21'), 3600);
INSERT INTO ScaleKG.kidehen.analytics_job VALUES (3, 9, 'exploratory-science', stringdate('2026-09-22'), 1800);
INSERT INTO ScaleKG.kidehen.analytics_job VALUES (4, 1, 'ml-feature-prep', stringdate('2026-09-27'), 5100);
INSERT INTO ScaleKG.kidehen.analytics_job VALUES (5, 4, 'entity-resolution', stringdate('2026-09-28'), 4200);
INSERT INTO ScaleKG.kidehen.analytics_job VALUES (6, 9, 'ml-feature-prep', stringdate('2026-09-25'), 7200);
INSERT INTO ScaleKG.kidehen.analytics_job VALUES (7, 12, 'exploratory-science', stringdate('2026-09-26'), 900);
INSERT INTO ScaleKG.kidehen.analytics_job VALUES (8, 6, 'entity-resolution', stringdate('2026-09-29'), 2700);
-- ── Part 2: IRI classes (one per entity; each can take minutes on a busy server) ──
SPARQL CREATE IRI CLASS <http://demo.openlinksw.com/schemas/ScaleKG/region_iri> "http://demo.openlinksw.com/ScaleKG/region/%d#this" (in region_id integer not null);
SPARQL CREATE IRI CLASS <http://demo.openlinksw.com/schemas/ScaleKG/cluster_iri> "http://demo.openlinksw.com/ScaleKG/cluster/%d#this" (in cluster_id integer not null);
SPARQL CREATE IRI CLASS <http://demo.openlinksw.com/schemas/ScaleKG/tenant_iri> "http://demo.openlinksw.com/ScaleKG/tenant/%d#this" (in tenant_id integer not null);
SPARQL CREATE IRI CLASS <http://demo.openlinksw.com/schemas/ScaleKG/environment_iri> "http://demo.openlinksw.com/ScaleKG/environment/%d#this" (in env_id integer not null);
SPARQL CREATE IRI CLASS <http://demo.openlinksw.com/schemas/ScaleKG/database_iri> "http://demo.openlinksw.com/ScaleKG/database/%d#this" (in db_id integer not null);
SPARQL CREATE IRI CLASS <http://demo.openlinksw.com/schemas/ScaleKG/replication_iri> "http://demo.openlinksw.com/ScaleKG/replication/%d#this" (in link_id integer not null);
SPARQL CREATE IRI CLASS <http://demo.openlinksw.com/schemas/ScaleKG/source_iri> "http://demo.openlinksw.com/ScaleKG/source/%d#this" (in src_id integer not null);
SPARQL CREATE IRI CLASS <http://demo.openlinksw.com/schemas/ScaleKG/wtable_iri> "http://demo.openlinksw.com/ScaleKG/table/%d#this" (in wt_id integer not null);
SPARQL CREATE IRI CLASS <http://demo.openlinksw.com/schemas/ScaleKG/workload_iri> "http://demo.openlinksw.com/ScaleKG/workload/%d#this" (in wl_id integer not null);
SPARQL CREATE IRI CLASS <http://demo.openlinksw.com/schemas/ScaleKG/job_iri> "http://demo.openlinksw.com/ScaleKG/job/%d#this" (in job_id integer not null);
-- ── Part 2b: the ontology (TBox) and the inference rule set derived from it ──
DB.DBA.TTLP('@prefix : <http://demo.openlinksw.com/schemas/ScaleKG/> .
@prefix skg: <http://demo.openlinksw.com/schemas/ScaleKG/> .
@prefix schema: <http://schema.org/> .
@prefix xsd: <http://www.w3.org/2001/XMLSchema#> .
@prefix rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
@prefix owl: <http://www.w3.org/2002/07/owl#> .
@prefix skos: <http://www.w3.org/2004/02/skos/core#> .
@prefix cdx: <https://linkeddata.uriburner.com/DAV/demos/daas/ontology-terms#> .
# TBox for the ScaleKG RDF View on demo.openlinksw.com. The ontology is the entity
# <http://demo.openlinksw.com/schemas/ScaleKG/>; this document is a separate CreativeWork.
<http://demo.openlinksw.com/schemas/ScaleKG/ontology-document> a schema:CreativeWork ;
schema:name "ScaleKG ontology (TBox)"@en ;
schema:description "RDFS/OWL vocabulary for the ScaleKG demonstration estate: regions, clusters, tenants, graph databases, replication links, warehouse sources and tables, workloads and analytics jobs. Loaded into the named graph http://demo.openlinksw.com/schemas/ScaleKG/ on demo.openlinksw.com and used to derive the urn:scalekg:inference rule set."@en ;
schema:dateCreated "2026-09-30T00:00:00Z"^^xsd:dateTime ;
schema:dateModified "2026-09-30T00:00:00Z"^^xsd:dateTime ;
schema:author <https://www.linkedin.com/in/kidehen#this> ;
schema:about <http://demo.openlinksw.com/schemas/ScaleKG/> .
<http://demo.openlinksw.com/schemas/ScaleKG/> a owl:Ontology ;
rdfs:label "ScaleKG ontology"@en ;
rdfs:comment "Vocabulary for describing a graph-database estate (tenants, clusters, databases, replication) and the warehouse sources that virtual-graph workloads read in place."@en ;
owl:versionInfo "1.0"@en .
# ── Classes ────────────────────────────────────────────────────────────────
skg:Region a owl:Class ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "Region"@en ;
rdfs:comment "A cloud region hosting one or more clusters."@en ;
rdfs:subClassOf schema:Place .
skg:Cluster a owl:Class ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "Cluster"@en ;
rdfs:comment "A database cluster or instance with a fixed amount of memory and storage that hosts one or more graph databases."@en ;
rdfs:subClassOf schema:Thing .
skg:Tenant a owl:Class ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "Tenant"@en ;
rdfs:comment "A customer organisation whose data is isolated in its own databases."@en ;
rdfs:subClassOf schema:Organization .
skg:Environment a owl:Class ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "Environment"@en ;
rdfs:comment "A lifecycle stage such as dev, test, staging or prod."@en ;
rdfs:subClassOf schema:DefinedTerm .
skg:DataAsset a owl:Class ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "Data asset"@en ;
rdfs:comment "Anything that stores queryable data: a natively stored graph database or a warehouse table read in place."@en ;
rdfs:subClassOf schema:Dataset .
skg:GraphDatabase a owl:Class ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "Graph database"@en ;
rdfs:comment "One database inside a cluster, owned by a single tenant in a single environment."@en ;
rdfs:subClassOf skg:DataAsset .
skg:WarehouseTable a owl:Class ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "Warehouse table"@en ;
rdfs:comment "A table in a data warehouse or lakehouse that a workload queries where it lives."@en ;
rdfs:subClassOf skg:DataAsset .
skg:WarehouseSource a owl:Class ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "Warehouse source"@en ;
rdfs:comment "A warehouse or lakehouse platform that holds warehouse tables."@en ;
rdfs:subClassOf schema:DataCatalog .
skg:ReplicationLink a owl:Class ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "Replication link"@en ;
rdfs:comment "A one-way link that keeps a target database in step with a source database on another cluster."@en ;
rdfs:subClassOf schema:Intangible .
skg:Workload a owl:Class ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "Workload"@en ;
rdfs:comment "An agent, GraphRAG application, analytics batch or SaaS application that reads a database or a warehouse."@en ;
rdfs:subClassOf schema:SoftwareApplication .
skg:AnalyticsJob a owl:Class ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "Analytics job"@en ;
rdfs:comment "A run of a graph-analytics job against a database, billed for the seconds it runs."@en ;
rdfs:subClassOf schema:Action .
# ── Object properties ──────────────────────────────────────────────────────
skg:dependsOn a owl:ObjectProperty ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "depends on"@en ;
rdfs:comment "Super-property: the subject cannot operate without the object. runsOn, readsFrom, queriesVirtually, hostedOn and replicatedTo are all specialisations."@en ;
rdfs:subPropertyOf cdx:dependsOn .
skg:runsOn a owl:ObjectProperty ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "runs on"@en ;
rdfs:comment "The natively stored graph database a workload uses."@en ;
rdfs:domain skg:Workload ; rdfs:range skg:GraphDatabase ;
rdfs:subPropertyOf skg:dependsOn .
skg:readsFrom a owl:ObjectProperty ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "reads from"@en ;
rdfs:comment "A warehouse table a virtual-graph workload reads in place."@en ;
rdfs:domain skg:Workload ; rdfs:range skg:WarehouseTable ;
rdfs:subPropertyOf skg:dependsOn .
skg:queriesVirtually a owl:ObjectProperty ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "queries virtually"@en ;
rdfs:comment "The warehouse source a workload queries through a virtual graph instead of a copy."@en ;
rdfs:domain skg:Workload ; rdfs:range skg:WarehouseSource ;
rdfs:subPropertyOf skg:dependsOn .
skg:hostedOn a owl:ObjectProperty ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "hosted on"@en ;
rdfs:comment "The cluster a graph database lives in."@en ;
rdfs:domain skg:GraphDatabase ; rdfs:range skg:Cluster ;
rdfs:subPropertyOf skg:dependsOn .
skg:replicatedTo a owl:ObjectProperty ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "replicated to"@en ;
rdfs:comment "The target database that continuously receives this database''s changes."@en ;
rdfs:domain skg:GraphDatabase ; rdfs:range skg:GraphDatabase ;
rdfs:subPropertyOf skg:dependsOn .
skg:inRegion a owl:ObjectProperty ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "in region"@en ;
rdfs:comment "The region a cluster runs in."@en ;
rdfs:domain skg:Cluster ; rdfs:range skg:Region .
skg:homeRegion a owl:ObjectProperty ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "home region"@en ;
rdfs:comment "The region a tenant is primarily served from."@en ;
rdfs:domain skg:Tenant ; rdfs:range skg:Region .
skg:ownedBy a owl:ObjectProperty ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "owned by"@en ;
rdfs:comment "The tenant that owns a database."@en ;
rdfs:domain skg:GraphDatabase ; rdfs:range skg:Tenant .
skg:forTenant a owl:ObjectProperty ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "for tenant"@en ;
rdfs:comment "The tenant a workload serves."@en ;
rdfs:domain skg:Workload ; rdfs:range skg:Tenant .
skg:environment a owl:ObjectProperty ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "environment"@en ;
rdfs:comment "The lifecycle stage a database belongs to."@en ;
rdfs:domain skg:GraphDatabase ; rdfs:range skg:Environment .
skg:inSource a owl:ObjectProperty ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "in source"@en ;
rdfs:comment "The warehouse source that holds a table."@en ;
rdfs:domain skg:WarehouseTable ; rdfs:range skg:WarehouseSource .
skg:replicatesFrom a owl:ObjectProperty ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "replicates from"@en ;
rdfs:comment "The source database of a replication link."@en ;
rdfs:domain skg:ReplicationLink ; rdfs:range skg:GraphDatabase .
skg:replicatesTo a owl:ObjectProperty ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "replicates to"@en ;
rdfs:comment "The target database of a replication link."@en ;
rdfs:domain skg:ReplicationLink ; rdfs:range skg:GraphDatabase .
skg:ranOn a owl:ObjectProperty ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "ran on"@en ;
rdfs:comment "The database an analytics job ran against."@en ;
rdfs:domain skg:AnalyticsJob ; rdfs:range skg:GraphDatabase .
# ── Datatype properties ────────────────────────────────────────────────────
skg:cloud a owl:DatatypeProperty ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "cloud"@en ; rdfs:comment "The cloud provider of a region."@en ;
rdfs:domain skg:Region ; rdfs:range xsd:string .
skg:countryCode a owl:DatatypeProperty ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "country code"@en ; rdfs:comment "ISO 3166-1 alpha-2 country code of a region."@en ;
rdfs:domain skg:Region ; rdfs:range xsd:string .
skg:clusterRole a owl:DatatypeProperty ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "cluster role"@en ; rdfs:comment "primary or secondary."@en ;
rdfs:domain skg:Cluster ; rdfs:range xsd:string .
skg:ramGb a owl:DatatypeProperty ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "RAM (GB)"@en ; rdfs:comment "Memory of a cluster in gigabytes."@en ;
rdfs:domain skg:Cluster ; rdfs:range xsd:integer .
skg:storageGb a owl:DatatypeProperty ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "storage (GB)"@en ; rdfs:comment "Storage of a cluster in gigabytes."@en ;
rdfs:domain skg:Cluster ; rdfs:range xsd:integer .
skg:edition a owl:DatatypeProperty ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "edition"@en ; rdfs:comment "The service edition a cluster runs."@en ;
rdfs:domain skg:Cluster ; rdfs:range xsd:string .
skg:tier a owl:DatatypeProperty ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "tier"@en ; rdfs:comment "The commercial tier of a tenant."@en ;
rdfs:domain skg:Tenant ; rdfs:range xsd:string .
skg:purpose a owl:DatatypeProperty ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "purpose"@en ; rdfs:comment "What a database is for."@en ;
rdfs:domain skg:GraphDatabase ; rdfs:range xsd:string .
skg:syncMode a owl:DatatypeProperty ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "sync mode"@en ; rdfs:comment "transaction-pull or differential-backup-pull."@en ;
rdfs:domain skg:ReplicationLink ; rdfs:range xsd:string .
skg:topology a owl:DatatypeProperty ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "topology"@en ; rdfs:comment "The replication topology, active-passive here."@en ;
rdfs:domain skg:ReplicationLink ; rdfs:range xsd:string .
skg:rbacReplicated a owl:DatatypeProperty ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "RBAC replicated"@en ; rdfs:comment "1 when role-based access rules travel with the replica, 0 when they must be recreated on the target."@en ;
rdfs:domain skg:ReplicationLink ; rdfs:range xsd:integer .
skg:vendor a owl:DatatypeProperty ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "vendor"@en ; rdfs:comment "The company behind a warehouse source."@en ;
rdfs:domain skg:WarehouseSource ; rdfs:range xsd:string .
skg:rowCount a owl:DatatypeProperty ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "row count"@en ; rdfs:comment "Approximate rows in a warehouse table."@en ;
rdfs:domain skg:WarehouseTable ; rdfs:range xsd:integer .
skg:workloadKind a owl:DatatypeProperty ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "workload kind"@en ; rdfs:comment "agent, graphrag, analytics or saas-app."@en ;
rdfs:domain skg:Workload ; rdfs:range xsd:string .
skg:latencyClass a owl:DatatypeProperty ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "latency class"@en ; rdfs:comment "millisecond for natively stored databases, second for warehouse-backed virtual graphs."@en ;
rdfs:domain skg:Workload ; rdfs:range xsd:string .
skg:jobKind a owl:DatatypeProperty ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "job kind"@en ; rdfs:comment "ml-feature-prep, entity-resolution or exploratory-science."@en ;
rdfs:domain skg:AnalyticsJob ; rdfs:range xsd:string .
skg:runDate a owl:DatatypeProperty ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "run date"@en ; rdfs:comment "The day an analytics job ran."@en ;
rdfs:domain skg:AnalyticsJob ; rdfs:range xsd:date .
skg:billedSeconds a owl:DatatypeProperty ;
rdfs:isDefinedBy <http://demo.openlinksw.com/schemas/ScaleKG/> ;
rdfs:label "billed seconds"@en ; rdfs:comment "Seconds a job was billed, which is the seconds it ran."@en ;
rdfs:domain skg:AnalyticsJob ; rdfs:range xsd:integer .', 'http://demo.openlinksw.com/schemas/ScaleKG/', 'http://demo.openlinksw.com/schemas/ScaleKG/');
DB.DBA.rdfs_rule_set('urn:scalekg:inference', 'http://demo.openlinksw.com/schemas/ScaleKG/');
-- ── Part 3: the RDF View. One statement per target graph: a second ALTER QUAD STORAGE
-- for the same graph REPLACES the first. Nullable foreign keys carry an IS NOT NULL guard. ──
SPARQL
ALTER QUAD STORAGE virtrdf:DefaultQuadStorage
FROM ScaleKG.kidehen.region AS r
FROM ScaleKG.kidehen.db_cluster AS c
FROM ScaleKG.kidehen.tenant AS t
FROM ScaleKG.kidehen.environment AS e
FROM ScaleKG.kidehen.graph_database AS d
FROM ScaleKG.kidehen.replication_link AS l
FROM ScaleKG.kidehen.warehouse_source AS ws
FROM ScaleKG.kidehen.warehouse_table AS wt
FROM ScaleKG.kidehen.workload AS w
FROM ScaleKG.kidehen.workload_reads AS rd
FROM ScaleKG.kidehen.analytics_job AS j
{
GRAPH <http://demo.openlinksw.com/ScaleKG#>
{
<http://demo.openlinksw.com/schemas/ScaleKG/region_iri>(r.region_id) <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://demo.openlinksw.com/schemas/ScaleKG/Region> as virtrdf:ScaleKG-region-type .
<http://demo.openlinksw.com/schemas/ScaleKG/region_iri>(r.region_id) <http://schema.org/name> r.region_name as virtrdf:ScaleKG-region-name .
<http://demo.openlinksw.com/schemas/ScaleKG/region_iri>(r.region_id) <http://demo.openlinksw.com/schemas/ScaleKG/cloud> r.cloud as virtrdf:ScaleKG-region-cloud .
<http://demo.openlinksw.com/schemas/ScaleKG/region_iri>(r.region_id) <http://demo.openlinksw.com/schemas/ScaleKG/countryCode> r.country_code as virtrdf:ScaleKG-region-country .
<http://demo.openlinksw.com/schemas/ScaleKG/cluster_iri>(c.cluster_id) <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://demo.openlinksw.com/schemas/ScaleKG/Cluster> as virtrdf:ScaleKG-cluster-type .
<http://demo.openlinksw.com/schemas/ScaleKG/cluster_iri>(c.cluster_id) <http://schema.org/name> c.cluster_name as virtrdf:ScaleKG-cluster-name .
<http://demo.openlinksw.com/schemas/ScaleKG/cluster_iri>(c.cluster_id) <http://demo.openlinksw.com/schemas/ScaleKG/clusterRole> c.cluster_role as virtrdf:ScaleKG-cluster-role .
<http://demo.openlinksw.com/schemas/ScaleKG/cluster_iri>(c.cluster_id) <http://demo.openlinksw.com/schemas/ScaleKG/ramGb> c.ram_gb as virtrdf:ScaleKG-cluster-ram .
<http://demo.openlinksw.com/schemas/ScaleKG/cluster_iri>(c.cluster_id) <http://demo.openlinksw.com/schemas/ScaleKG/storageGb> c.storage_gb as virtrdf:ScaleKG-cluster-storage .
<http://demo.openlinksw.com/schemas/ScaleKG/cluster_iri>(c.cluster_id) <http://demo.openlinksw.com/schemas/ScaleKG/edition> c.edition as virtrdf:ScaleKG-cluster-edition .
<http://demo.openlinksw.com/schemas/ScaleKG/cluster_iri>(c.cluster_id) <http://demo.openlinksw.com/schemas/ScaleKG/inRegion> <http://demo.openlinksw.com/schemas/ScaleKG/region_iri>(c.region_id) as virtrdf:ScaleKG-cluster-region .
<http://demo.openlinksw.com/schemas/ScaleKG/tenant_iri>(t.tenant_id) <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://demo.openlinksw.com/schemas/ScaleKG/Tenant> as virtrdf:ScaleKG-tenant-type .
<http://demo.openlinksw.com/schemas/ScaleKG/tenant_iri>(t.tenant_id) <http://schema.org/name> t.tenant_name as virtrdf:ScaleKG-tenant-name .
<http://demo.openlinksw.com/schemas/ScaleKG/tenant_iri>(t.tenant_id) <http://demo.openlinksw.com/schemas/ScaleKG/tier> t.tier as virtrdf:ScaleKG-tenant-tier .
<http://demo.openlinksw.com/schemas/ScaleKG/tenant_iri>(t.tenant_id) <http://demo.openlinksw.com/schemas/ScaleKG/homeRegion> <http://demo.openlinksw.com/schemas/ScaleKG/region_iri>(t.region_id) as virtrdf:ScaleKG-tenant-region .
<http://demo.openlinksw.com/schemas/ScaleKG/environment_iri>(e.env_id) <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://demo.openlinksw.com/schemas/ScaleKG/Environment> as virtrdf:ScaleKG-env-type .
<http://demo.openlinksw.com/schemas/ScaleKG/environment_iri>(e.env_id) <http://schema.org/name> e.env_name as virtrdf:ScaleKG-env-name .
<http://demo.openlinksw.com/schemas/ScaleKG/database_iri>(d.db_id) <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://demo.openlinksw.com/schemas/ScaleKG/GraphDatabase> as virtrdf:ScaleKG-db-type .
<http://demo.openlinksw.com/schemas/ScaleKG/database_iri>(d.db_id) <http://schema.org/name> d.db_name as virtrdf:ScaleKG-db-name .
<http://demo.openlinksw.com/schemas/ScaleKG/database_iri>(d.db_id) <http://demo.openlinksw.com/schemas/ScaleKG/purpose> d.purpose as virtrdf:ScaleKG-db-purpose .
<http://demo.openlinksw.com/schemas/ScaleKG/database_iri>(d.db_id) <http://demo.openlinksw.com/schemas/ScaleKG/hostedOn> <http://demo.openlinksw.com/schemas/ScaleKG/cluster_iri>(d.cluster_id) as virtrdf:ScaleKG-db-cluster .
<http://demo.openlinksw.com/schemas/ScaleKG/database_iri>(d.db_id) <http://demo.openlinksw.com/schemas/ScaleKG/ownedBy> <http://demo.openlinksw.com/schemas/ScaleKG/tenant_iri>(d.tenant_id) as virtrdf:ScaleKG-db-tenant .
<http://demo.openlinksw.com/schemas/ScaleKG/database_iri>(d.db_id) <http://demo.openlinksw.com/schemas/ScaleKG/environment> <http://demo.openlinksw.com/schemas/ScaleKG/environment_iri>(d.env_id) as virtrdf:ScaleKG-db-env .
<http://demo.openlinksw.com/schemas/ScaleKG/replication_iri>(l.link_id) <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://demo.openlinksw.com/schemas/ScaleKG/ReplicationLink> as virtrdf:ScaleKG-link-type .
<http://demo.openlinksw.com/schemas/ScaleKG/replication_iri>(l.link_id) <http://demo.openlinksw.com/schemas/ScaleKG/syncMode> l.sync_mode as virtrdf:ScaleKG-link-mode .
<http://demo.openlinksw.com/schemas/ScaleKG/replication_iri>(l.link_id) <http://demo.openlinksw.com/schemas/ScaleKG/topology> l.topology as virtrdf:ScaleKG-link-topology .
<http://demo.openlinksw.com/schemas/ScaleKG/replication_iri>(l.link_id) <http://demo.openlinksw.com/schemas/ScaleKG/rbacReplicated> l.rbac_replicated as virtrdf:ScaleKG-link-rbac .
<http://demo.openlinksw.com/schemas/ScaleKG/replication_iri>(l.link_id) <http://demo.openlinksw.com/schemas/ScaleKG/replicatesFrom> <http://demo.openlinksw.com/schemas/ScaleKG/database_iri>(l.source_db_id) as virtrdf:ScaleKG-link-from .
<http://demo.openlinksw.com/schemas/ScaleKG/replication_iri>(l.link_id) <http://demo.openlinksw.com/schemas/ScaleKG/replicatesTo> <http://demo.openlinksw.com/schemas/ScaleKG/database_iri>(l.target_db_id) as virtrdf:ScaleKG-link-to .
<http://demo.openlinksw.com/schemas/ScaleKG/database_iri>(l.source_db_id) <http://demo.openlinksw.com/schemas/ScaleKG/replicatedTo> <http://demo.openlinksw.com/schemas/ScaleKG/database_iri>(l.target_db_id) as virtrdf:ScaleKG-db-replicated-to .
<http://demo.openlinksw.com/schemas/ScaleKG/source_iri>(ws.src_id) <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://demo.openlinksw.com/schemas/ScaleKG/WarehouseSource> as virtrdf:ScaleKG-src-type .
<http://demo.openlinksw.com/schemas/ScaleKG/source_iri>(ws.src_id) <http://schema.org/name> ws.src_name as virtrdf:ScaleKG-src-name .
<http://demo.openlinksw.com/schemas/ScaleKG/source_iri>(ws.src_id) <http://demo.openlinksw.com/schemas/ScaleKG/vendor> ws.vendor as virtrdf:ScaleKG-src-vendor .
<http://demo.openlinksw.com/schemas/ScaleKG/wtable_iri>(wt.wt_id) <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://demo.openlinksw.com/schemas/ScaleKG/WarehouseTable> as virtrdf:ScaleKG-wt-type .
<http://demo.openlinksw.com/schemas/ScaleKG/wtable_iri>(wt.wt_id) <http://schema.org/name> wt.table_name as virtrdf:ScaleKG-wt-name .
<http://demo.openlinksw.com/schemas/ScaleKG/wtable_iri>(wt.wt_id) <http://demo.openlinksw.com/schemas/ScaleKG/rowCount> wt.row_count as virtrdf:ScaleKG-wt-rows .
<http://demo.openlinksw.com/schemas/ScaleKG/wtable_iri>(wt.wt_id) <http://demo.openlinksw.com/schemas/ScaleKG/inSource> <http://demo.openlinksw.com/schemas/ScaleKG/source_iri>(wt.src_id) as virtrdf:ScaleKG-wt-source .
<http://demo.openlinksw.com/schemas/ScaleKG/workload_iri>(w.wl_id) <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://demo.openlinksw.com/schemas/ScaleKG/Workload> as virtrdf:ScaleKG-wl-type .
<http://demo.openlinksw.com/schemas/ScaleKG/workload_iri>(w.wl_id) <http://schema.org/name> w.wl_name as virtrdf:ScaleKG-wl-name .
<http://demo.openlinksw.com/schemas/ScaleKG/workload_iri>(w.wl_id) <http://demo.openlinksw.com/schemas/ScaleKG/workloadKind> w.wl_kind as virtrdf:ScaleKG-wl-kind .
<http://demo.openlinksw.com/schemas/ScaleKG/workload_iri>(w.wl_id) <http://demo.openlinksw.com/schemas/ScaleKG/latencyClass> w.latency_class as virtrdf:ScaleKG-wl-latency .
<http://demo.openlinksw.com/schemas/ScaleKG/workload_iri>(w.wl_id) <http://demo.openlinksw.com/schemas/ScaleKG/forTenant> <http://demo.openlinksw.com/schemas/ScaleKG/tenant_iri>(w.tenant_id) as virtrdf:ScaleKG-wl-tenant .
<http://demo.openlinksw.com/schemas/ScaleKG/workload_iri>(w.wl_id) <http://demo.openlinksw.com/schemas/ScaleKG/runsOn> <http://demo.openlinksw.com/schemas/ScaleKG/database_iri>(w.db_id) where (^{w.}^.db_id is not null) as virtrdf:ScaleKG-wl-db .
<http://demo.openlinksw.com/schemas/ScaleKG/workload_iri>(w.wl_id) <http://demo.openlinksw.com/schemas/ScaleKG/queriesVirtually> <http://demo.openlinksw.com/schemas/ScaleKG/source_iri>(w.src_id) where (^{w.}^.src_id is not null) as virtrdf:ScaleKG-wl-src .
<http://demo.openlinksw.com/schemas/ScaleKG/workload_iri>(rd.wl_id) <http://demo.openlinksw.com/schemas/ScaleKG/readsFrom> <http://demo.openlinksw.com/schemas/ScaleKG/wtable_iri>(rd.wt_id) as virtrdf:ScaleKG-wl-reads .
<http://demo.openlinksw.com/schemas/ScaleKG/job_iri>(j.job_id) <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://demo.openlinksw.com/schemas/ScaleKG/AnalyticsJob> as virtrdf:ScaleKG-job-type .
<http://demo.openlinksw.com/schemas/ScaleKG/job_iri>(j.job_id) <http://demo.openlinksw.com/schemas/ScaleKG/jobKind> j.job_kind as virtrdf:ScaleKG-job-kind .
<http://demo.openlinksw.com/schemas/ScaleKG/job_iri>(j.job_id) <http://demo.openlinksw.com/schemas/ScaleKG/runDate> j.run_date as virtrdf:ScaleKG-job-date .
<http://demo.openlinksw.com/schemas/ScaleKG/job_iri>(j.job_id) <http://demo.openlinksw.com/schemas/ScaleKG/billedSeconds> j.billed_seconds as virtrdf:ScaleKG-job-seconds .
<http://demo.openlinksw.com/schemas/ScaleKG/job_iri>(j.job_id) <http://demo.openlinksw.com/schemas/ScaleKG/ranOn> <http://demo.openlinksw.com/schemas/ScaleKG/database_iri>(j.db_id) as virtrdf:ScaleKG-job-db .
}
} ;
-- ── Part 4: access. The view inherits SQL table privileges. SPARQL serves the anonymous
-- endpoint; demo and vdb are accounts on demo.openlinksw.com that serve SPASQL and the Query
-- Builder: on another server, drop the two lines that grant to them. ──
GRANT SELECT ON ScaleKG.kidehen.region TO "SPARQL";
GRANT SELECT ON ScaleKG.kidehen.region TO PUBLIC;
GRANT SELECT ON ScaleKG.kidehen.region TO "demo";
GRANT SELECT ON ScaleKG.kidehen.region TO "vdb";
GRANT SELECT ON ScaleKG.kidehen.db_cluster TO "SPARQL";
GRANT SELECT ON ScaleKG.kidehen.db_cluster TO PUBLIC;
GRANT SELECT ON ScaleKG.kidehen.db_cluster TO "demo";
GRANT SELECT ON ScaleKG.kidehen.db_cluster TO "vdb";
GRANT SELECT ON ScaleKG.kidehen.tenant TO "SPARQL";
GRANT SELECT ON ScaleKG.kidehen.tenant TO PUBLIC;
GRANT SELECT ON ScaleKG.kidehen.tenant TO "demo";
GRANT SELECT ON ScaleKG.kidehen.tenant TO "vdb";
GRANT SELECT ON ScaleKG.kidehen.environment TO "SPARQL";
GRANT SELECT ON ScaleKG.kidehen.environment TO PUBLIC;
GRANT SELECT ON ScaleKG.kidehen.environment TO "demo";
GRANT SELECT ON ScaleKG.kidehen.environment TO "vdb";
GRANT SELECT ON ScaleKG.kidehen.graph_database TO "SPARQL";
GRANT SELECT ON ScaleKG.kidehen.graph_database TO PUBLIC;
GRANT SELECT ON ScaleKG.kidehen.graph_database TO "demo";
GRANT SELECT ON ScaleKG.kidehen.graph_database TO "vdb";
GRANT SELECT ON ScaleKG.kidehen.replication_link TO "SPARQL";
GRANT SELECT ON ScaleKG.kidehen.replication_link TO PUBLIC;
GRANT SELECT ON ScaleKG.kidehen.replication_link TO "demo";
GRANT SELECT ON ScaleKG.kidehen.replication_link TO "vdb";
GRANT SELECT ON ScaleKG.kidehen.warehouse_source TO "SPARQL";
GRANT SELECT ON ScaleKG.kidehen.warehouse_source TO PUBLIC;
GRANT SELECT ON ScaleKG.kidehen.warehouse_source TO "demo";
GRANT SELECT ON ScaleKG.kidehen.warehouse_source TO "vdb";
GRANT SELECT ON ScaleKG.kidehen.warehouse_table TO "SPARQL";
GRANT SELECT ON ScaleKG.kidehen.warehouse_table TO PUBLIC;
GRANT SELECT ON ScaleKG.kidehen.warehouse_table TO "demo";
GRANT SELECT ON ScaleKG.kidehen.warehouse_table TO "vdb";
GRANT SELECT ON ScaleKG.kidehen.workload TO "SPARQL";
GRANT SELECT ON ScaleKG.kidehen.workload TO PUBLIC;
GRANT SELECT ON ScaleKG.kidehen.workload TO "demo";
GRANT SELECT ON ScaleKG.kidehen.workload TO "vdb";
GRANT SELECT ON ScaleKG.kidehen.workload_reads TO "SPARQL";
GRANT SELECT ON ScaleKG.kidehen.workload_reads TO PUBLIC;
GRANT SELECT ON ScaleKG.kidehen.workload_reads TO "demo";
GRANT SELECT ON ScaleKG.kidehen.workload_reads TO "vdb";
GRANT SELECT ON ScaleKG.kidehen.analytics_job TO "SPARQL";
GRANT SELECT ON ScaleKG.kidehen.analytics_job TO PUBLIC;
GRANT SELECT ON ScaleKG.kidehen.analytics_job TO "demo";
GRANT SELECT ON ScaleKG.kidehen.analytics_job TO "vdb";
-- ── Part 5: URL rewrite rules, so every entity IRI resolves (303 to a description page; RDF
-- requests routed to DESCRIBE). Generated by the OpenLink RDFVIEW_GENERATE_DATA_RULES function with
-- iri_path_segment=ScaleKG. Change the path segment and graph names if you rename the view. ──
DB.DBA.URLREWRITE_CREATE_REGEX_RULE (
'scalekg_rule2',
1,
'(/[^#]*)',
vector('path'),
1,
'/sparql?query=DESCRIBE+%%3Chttp%%3A//^{URIQADefaultHost}^%U%%23this%%3E+FROM+%%3Chttp%%3A//^{URIQADefaultHost}^/ScaleKG%%23%%3E&format=%U',
vector('path', '*accept*'),
null,
'(text/rdf.n3)|(application/rdf.xml)|(text/n3)|(application/json)|(text/turtle)',
2,
null
);
DB.DBA.URLREWRITE_CREATE_REGEX_RULE (
'scalekg_rule4',
1,
'/ScaleKG/stat([^#]*)',
vector('path'),
1,
'/sparql?query=DESCRIBE+%%3Chttp%%3A//^{URIQADefaultHost}^/ScaleKG/stat%%23%%3E+%%3Fo+FROM+%%3Chttp%%3A//^{URIQADefaultHost}^/ScaleKG%%23%%3E+WHERE+{+%%3Chttp%%3A//^{URIQADefaultHost}^/ScaleKG/stat%%23%%3E+%%3Fp+%%3Fo+}&format=%U',
vector('*accept*'),
null,
'(text/rdf.n3)|(application/rdf.xml)|(text/n3)|(application/json)|(text/turtle)',
2,
null
);
DB.DBA.URLREWRITE_CREATE_REGEX_RULE (
'scalekg_rule6',
1,
'/ScaleKG/objects/([^#]*)',
vector('path'),
1,
'/sparql?query=DESCRIBE+%%3Chttp%%3A//^{URIQADefaultHost}^/ScaleKG/objects/%U%%3E+FROM+%%3Chttp%%3A//^{URIQADefaultHost}^/ScaleKG%%23%%3E&format=%U',
vector('path', '*accept*'),
null,
'(text/rdf.n3)|(application/rdf.xml)|(text/n3)|(application/json)|(text/turtle)',
2,
null
);
DB.DBA.URLREWRITE_CREATE_REGEX_RULE (
'scalekg_rule1',
1,
'([^#]*)',
vector('path'),
1,
'/describe/?uri=http%%3A%%2F%%2F^{URIQADefaultHost}^%U%%23this&graph=http%%3A%%2F%%2F^{URIQADefaultHost}^%%2FScaleKG%%23',
vector('path'),
null,
null,
2,
303
);
DB.DBA.URLREWRITE_CREATE_REGEX_RULE (
'scalekg_rule7',
1,
'/ScaleKG/stat([^#]*)',
vector('path'),
1,
'/describe/?uri=http%%3A%%2F%%2F^{URIQADefaultHost}^%%2FScaleKG%%2Fstat%%23&graph=http%%3A%%2F%%2F^{URIQADefaultHost}^%%2FScaleKG%%23',
vector('path'),
null,
null,
2,
303
);
DB.DBA.URLREWRITE_CREATE_REGEX_RULE (
'scalekg_rule5',
1,
'/ScaleKG/objects/(.*)',
vector('path'),
1,
'/services/rdf/object.binary?path=%%2FScaleKG%%2Fobjects%%2F%U&accept=%U',
vector('path', '*accept*'),
null,
null,
2,
null
);
DB.DBA.URLREWRITE_CREATE_RULELIST ( 'scalekg_rule_list1', 1, vector ( 'scalekg_rule1', 'scalekg_rule7', 'scalekg_rule5', 'scalekg_rule2', 'scalekg_rule4', 'scalekg_rule6'));
DB.DBA.VHOST_REMOVE (lpath=>'/ScaleKG');
DB.DBA.VHOST_DEFINE (lpath=>'/ScaleKG', ppath=>'/', vsp_user=>'dba', is_dav=>0,
is_brws=>0, opts=>vector ('url_rewrite', 'scalekg_rule_list1')
);DB.DBA.URLREWRITE_CREATE_REGEX_RULE (
'scalekg_owl_rule2',
1,
'(/[^#]*)',
vector('path'),
1,
'/sparql?query=DESCRIBE+%%3Chttp%%3A//^{URIQADefaultHost}^%U%%3E+FROM+%%3Chttp%%3A//^{URIQADefaultHost}^/schemas/ScaleKG%%23%%3E&format=%U',
vector('path', '*accept*'),
null,
'(text/rdf.n3)|(application/rdf.xml)|(text/n3)|(application/json)|(text/turtle)',
2,
null
);
DB.DBA.URLREWRITE_CREATE_REGEX_RULE (
'scalekg_owl_rule1',
1,
'([^#]*)',
vector('path'),
1,
'/describe/?uri=http%%3A%%2F%%2F^{URIQADefaultHost}^%U&graph=http%%3A%%2F%%2F^{URIQADefaultHost}^%%2Fschemas%%2FScaleKG%%2F',
vector('path'),
null,
null,
2,
303
);
DB.DBA.URLREWRITE_CREATE_RULELIST ( 'scalekg_owl_rule_list1', 1, vector ( 'scalekg_owl_rule1', 'scalekg_owl_rule2'));
DB.DBA.VHOST_REMOVE (lpath=>'/schemas/ScaleKG');
DB.DBA.VHOST_DEFINE (lpath=>'/schemas/ScaleKG', ppath=>'/', vsp_user=>'dba', is_dav=>0,
is_brws=>0, opts=>vector ('url_rewrite', 'scalekg_owl_rule_list1')
);