. "bcdf6beeb34eb2015acd5ffce9f5bee5" . "VirtRDFViewNorthwindScript" . "2017-06-13T05:45:20.728172"^^ . "2017-06-13T05:45:20Z" . . "2017-06-13T05:45:20Z" . . "2017-06-13T05:45:20.728172"^^ . . . . "VirtRDFViewNorthwindScript" . . . . . . . "---++Virtuoso Northwind Linked Data Views Script to set up your own instance\n\n\nuse DB;\n\nDB.DBA.exec_stmt ('UPDATE WS.WS.SYS_DAV_RES set RES_TYPE=\\'image/jpeg\\' where RES_FULL_PATH like \\'/DAV/VAD/demo/sql/CAT%\\'', 0)\n;\n\nDB.DBA.exec_stmt ('UPDATE WS.WS.SYS_DAV_RES set RES_TYPE=\\'image/jpeg\\' where RES_FULL_PATH like \\'/DAV/VAD/demo/sql/EMP%\\'', 0)\n;\n\nGRANT SELECT ON \"Demo\".\"demo\".\"Products\" TO \"SPARQL\";\nGRANT SELECT ON \"Demo\".\"demo\".\"Suppliers\" TO \"SPARQL\";\nGRANT SELECT ON \"Demo\".\"demo\".\"Shippers\" TO \"SPARQL\";\nGRANT SELECT ON \"Demo\".\"demo\".\"Categories\" TO \"SPARQL\";\nGRANT SELECT ON \"Demo\".\"demo\".\"Customers\" TO \"SPARQL\";\nGRANT SELECT ON \"Demo\".\"demo\".\"Employees\" TO \"SPARQL\";\nGRANT SELECT ON \"Demo\".\"demo\".\"Orders\" TO \"SPARQL\";\nGRANT SELECT ON \"Demo\".\"demo\".\"Order_Details\" TO \"SPARQL\";\nGRANT SELECT ON \"Demo\".\"demo\".\"Countries\" TO \"SPARQL\";\nGRANT SELECT ON \"Demo\".\"demo\".\"Provinces\" TO \"SPARQL\";\n\n\n--SPARQL drop quad map graph iri(\"http://^{URIQADefaultHost}^/Northwind\") .\n--;\n\nSPARQL drop silent quad map virtrdf:NorthwindDemo .\n;\n\nSPARQL\nprefix northwind: \ndrop iri class northwind:Category .\ndrop iri class northwind:CategoryDoc .\ndrop iri class northwind:Shipper .\ndrop iri class northwind:ShipperDoc .\ndrop iri class northwind:Supplier .\ndrop iri class northwind:SupplierDoc .\ndrop iri class northwind:Product .\ndrop iri class northwind:ProductDoc .\ndrop iri class northwind:Customer .\ndrop iri class northwind:CustomerDoc .\ndrop iri class northwind:Employee .\ndrop iri class northwind:EmployeeDoc .\ndrop iri class northwind:Order .\ndrop iri class northwind:OrderDoc .\ndrop iri class northwind:CustomerContact .\ndrop iri class northwind:CustomerContactDoc .\ndrop iri class northwind:OrderLine .\ndrop iri class northwind:OrderLineDoc .\ndrop iri class northwind:Province .\ndrop iri class northwind:ProvinceDoc .\ndrop iri class northwind:Country .\ndrop iri class northwind:CountryDoc .\ndrop iri class northwind:Flag .\ndrop iri class northwind:FlagDoc .\ndrop iri class northwind:dbpedia_iri2 .\ndrop iri class northwind:EmployeePhoto .\ndrop iri class northwind:CategoryPhoto .\n\ndrop iri class northwind:category_iri .\ndrop iri class northwind:categorydoc_iri .\ndrop iri class northwind:shipper_iri .\ndrop iri class northwind:shipperdoc_iri .\ndrop iri class northwind:supplier_iri .\ndrop iri class northwind:supplierdoc_iri .\ndrop iri class northwind:product_iri .\ndrop iri class northwind:productdoc_iri .\ndrop iri class northwind:customer_iri .\ndrop iri class northwind:customerdoc_iri .\ndrop iri class northwind:employee_iri .\ndrop iri class northwind:employeedoc_iri .\ndrop iri class northwind:order_iri .\ndrop iri class northwind:orderdoc_iri .\ndrop iri class northwind:customercontact_iri .\ndrop iri class northwind:customercontactdoc_iri .\ndrop iri class northwind:orderline_iri .\ndrop iri class northwind:orderlinedoc_iri .\ndrop iri class northwind:province_iri .\ndrop iri class northwind:provincedoc_iri .\ndrop iri class northwind:country_iri .\ndrop iri class northwind:countrydoc_iri .\ndrop iri class northwind:employeephoto_iri .\ndrop iri class northwind:categoryphoto_iri .\ndrop iri class northwind:flag_iri .\ndrop iri class northwind:flagdoc_iri .\n;\n\nSPARQL\nprefix northwind: \n\ncreate iri class northwind:Category \"http://^{URIQADefaultHost}^/Northwind/Category/%d#this\" (in category_id integer not null) .\ncreate iri class northwind:Shipper \"http://^{URIQADefaultHost}^/Northwind/Shipper/%d#this\" (in shipper_id integer not null) .\ncreate iri class northwind:Supplier \"http://^{URIQADefaultHost}^/Northwind/Supplier/%d#this\" (in supplier_id integer not null) .\ncreate iri class northwind:Product \"http://^{URIQADefaultHost}^/Northwind/Product/%d#this\" (in product_id integer not null) .\ncreate iri class northwind:Customer \"http://^{URIQADefaultHost}^/Northwind/Customer/%U#this\" (in customer_id varchar not null) .\ncreate iri class northwind:Employee \"http://^{URIQADefaultHost}^/Northwind/Employee/%U_%U_%d#this\" (in employee_firstname varchar not null, in employee_lastname varchar not null, in employee_id integer not null) .\ncreate iri class northwind:Order \"http://^{URIQADefaultHost}^/Northwind/Order/%d#this\" (in order_id integer not null) .\ncreate iri class northwind:CustomerContact \"http://^{URIQADefaultHost}^/Northwind/CustomerContact/%U#this\" (in customer_id varchar not null) .\ncreate iri class northwind:OrderLine \"http://^{URIQADefaultHost}^/Northwind/OrderLine/%d/%d#this\" (in order_id integer not null, in product_id integer not null) .\ncreate iri class northwind:Province \"http://^{URIQADefaultHost}^/Northwind/Province/%U/%U#this\" (in country_name varchar not null, in province_name varchar not null) .\ncreate iri class northwind:Country \"http://^{URIQADefaultHost}^/Northwind/Country/%U#this\" (in country_name varchar not null) .\ncreate iri class northwind:Flag \"http://^{URIQADefaultHost}^%U#this\" (in flag_path varchar not null) .\ncreate iri class northwind:dbpedia_iri2 \"http://dbpedia.org/resource/%U\" (in uname varchar not null) .\ncreate iri class northwind:EmployeePhoto \"http://^{URIQADefaultHost}^/DAV/VAD/demo/sql/EMP%d#this\" (in emp_id varchar not null) .\ncreate iri class northwind:CategoryPhoto \"http://^{URIQADefaultHost}^/DAV/VAD/demo/sql/CAT%d#this\" (in category_id varchar not null) .\ncreate iri class northwind:Phone \"tel:%s\" (in phone_number varchar) .\ncreate iri class northwind:Fax \"fax:%s\" (in fax_number varchar) .\n;\n\nSPARQL\nprefix northwind: \nprefix oplsioc: \nprefix rdfs: \nprefix sioc: \nprefix foaf: \nprefix owl: \nprefix wgs: \nprefix ore: \nprefix opl: \n\nalter quad storage virtrdf:DefaultQuadStorage\nfrom Demo.demo.Products as products\nfrom Demo.demo.Suppliers as suppliers\nfrom Demo.demo.Shippers as shippers\nfrom Demo.demo.Categories as categories\nfrom Demo.demo.Customers as customers\nfrom Demo.demo.Employees as employees\nfrom Demo.demo.Orders as orders\nfrom Demo.demo.Order_Details as order_lines\nfrom Demo.demo.Countries as countries\nfrom Demo.demo.Provinces as provinces\nwhere (^{suppliers.}^.Country = ^{countries.}^.Name)\nwhere (^{customers.}^.Country = ^{countries.}^.Name)\nwhere (^{employees.}^.Country = ^{countries.}^.Name)\nwhere (^{orders.}^.ShipCountry = ^{countries.}^.Name)\n{\n create virtrdf:NorthwindDemo as graph iri (\"http://^{URIQADefaultHost}^/Northwind\") option (exclusive)\n {\n northwind:CustomerContact (customers.CustomerID)\n a foaf:Person\n as virtrdf:CustomerContact-foaf_Person .\n\n northwind:CustomerContact (customers.CustomerID)\n a northwind:CustomerContact\n as virtrdf:CustomerContact-CustomerContact;\n foaf:name customers.ContactName\n as virtrdf:CustomerContact-contact_name ;\n foaf:phone northwind:Phone (customers.Phone)\n as virtrdf:CustomerContact-foaf_phone ;\n northwind:is_contact_at northwind:Customer (customers.CustomerID)\n as virtrdf:CustomerContact-is_contact_at ;\n northwind:country northwind:Country (customers.Country)\n as virtrdf:CustomerContact-country ;\n opl:isDescribedUsing northwind: .\n\n northwind:Country (customers.Country)\n northwind:is_country_of\n northwind:CustomerContact (customers.CustomerID) as virtrdf:CustomerContact-is_country_of .\n\n northwind:Product (products.ProductID)\n a northwind:Product\n as virtrdf:Product-ProductID ;\n northwind:has_category northwind:Category (products.CategoryID)\n as virtrdf:Product-product_has_category ;\n northwind:has_supplier northwind:Supplier (products.SupplierID)\n as virtrdf:Product-product_has_supplier ;\n northwind:productName products.ProductName\n as virtrdf:Product-name_of_product ;\n northwind:quantityPerUnit products.QuantityPerUnit\n as virtrdf:Product-quantity_per_unit ;\n northwind:unitPrice products.UnitPrice\n as virtrdf:Product-unit_price ;\n northwind:unitsInStock products.UnitsInStock\n as virtrdf:Product-units_in_stock ;\n northwind:unitsOnOrder products.UnitsOnOrder\n as virtrdf:Product-units_on_order ;\n northwind:reorderLevel products.ReorderLevel\n as virtrdf:Product-reorder_level ;\n northwind:discontinued products.Discontinued\n as virtrdf:Product-discontinued ;\n opl:isDescribedUsing northwind: .\n\n northwind:Category (products.CategoryID)\n northwind:category_of northwind:Product (products.ProductID) as virtrdf:Product-category_of .\n\n northwind:Supplier (products.SupplierID)\n northwind:supplier_of northwind:Product (products.ProductID) as virtrdf:Product-supplier_of .\n\n northwind:Supplier (suppliers.SupplierID)\n a northwind:Supplier\n as virtrdf:Supplier-SupplierID ;\n northwind:companyName suppliers.CompanyName\n as virtrdf:Supplier-company_name ;\n northwind:contactName suppliers.ContactName\n as virtrdf:Supplier-contact_name ;\n northwind:contactTitle suppliers.ContactTitle\n as virtrdf:Supplier-contact_title ;\n northwind:address suppliers.Address\n as virtrdf:Supplier-address ;\n northwind:city northwind:dbpedia_iri2(suppliers.City)\n as virtrdf:Supplier-dbpediacity ;\n northwind:region suppliers.Region\n as virtrdf:Supplier-region ;\n northwind:postalCode suppliers.PostalCode\n as virtrdf:Supplier-postal_code ;\n northwind:country northwind:Country(suppliers.Country)\n as virtrdf:Supplier-country ;\n northwind:phone northwind:Phone (suppliers.Phone)\n as virtrdf:Supplier-phone ;\n northwind:fax northwind:Fax (suppliers.Fax)\n as virtrdf:Supplier-fax ;\n northwind:homePage suppliers.HomePage\n as virtrdf:Supplier-home_page ;\n opl:isDescribedUsing northwind: .\n\n northwind:Country (suppliers.Country)\n northwind:is_country_of\n northwind:Supplier (suppliers.SupplierID) as virtrdf:Supplier-is_country_of .\n\n northwind:Category (categories.CategoryID)\n a northwind:Category\n as virtrdf:Category-CategoryID ;\n northwind:categoryName categories.CategoryName\n as virtrdf:Category-home_page ;\n northwind:description categories.Description\n as virtrdf:Category-description ;\n foaf:img northwind:CategoryPhoto(categories.CategoryID)\n as virtrdf:Category-categories.CategoryPhoto ;\n opl:isDescribedUsing northwind: .\n\n northwind:CategoryPhoto(categories.CategoryID)\n a northwind:CategoryPhoto\n as virtrdf:Category-categories.CategoryPhotoID ;\n opl:isDescribedUsing northwind: .\n\n northwind:Shipper (shippers.ShipperID)\n a northwind:Shipper\n as virtrdf:Shipper-ShipperID ;\n northwind:companyName shippers.CompanyName\n as virtrdf:Shipper-company_name ;\n northwind:phone northwind:Phone (shippers.Phone)\n as virtrdf:Shipper-phone ;\n opl:isDescribedUsing northwind: .\n\n northwind:Customer (customers.CustomerID)\n a northwind:Customer\n as virtrdf:Customer-CustomerID2 ;\n a foaf:Organization\n as virtrdf:Customer-CustomerID ;\n foaf:name customers.CompanyName\n as virtrdf:Customer-foaf_name ;\n northwind:companyName customers.CompanyName\n as virtrdf:Customer-company_name ;\n northwind:has_contact northwind:CustomerContact (customers.CustomerID)\n as virtrdf:Customer-contact ;\n northwind:country northwind:Country (customers.Country)\n as virtrdf:Customer-country ;\n northwind:contactName customers.ContactName\n as virtrdf:Customer-contact_name ;\n northwind:contactTitle customers.ContactTitle\n as virtrdf:Customer-contact_title ;\n northwind:address customers.Address\n as virtrdf:Customer-address ;\n northwind:city northwind:dbpedia_iri2(customers.City)\n as virtrdf:Customer-dbpediacity ;\n northwind:region customers.Region\n as virtrdf:Customer-region ;\n northwind:PostalCode customers.PostalCode\n as virtrdf:Customer-postal_code ;\n foaf:phone northwind:Phone (customers.Phone)\n as virtrdf:Customer-foaf_phone ;\n northwind:phone northwind:Phone (customers.Phone)\n as virtrdf:Customer-phone ;\n northwind:fax northwind:Fax (customers.Fax)\n as virtrdf:Customer-fax ;\n opl:isDescribedUsing northwind: .\n\n northwind:Country (customers.Country)\n northwind:is_country_of\n northwind:Customer (customers.CustomerID) as virtrdf:Customer-is_country_of .\n\n northwind:Employee (employees.FirstName, employees.LastName, employees.EmployeeID)\n a northwind:Employee\n as virtrdf:Employee-EmployeeID2 ;\n a foaf:Person\n as virtrdf:Employee-EmployeeID ;\n foaf:surname employees.LastName\n as virtrdf:Employee-foaf_last_name ;\n northwind:lastName employees.LastName\n as virtrdf:Employee-last_name ;\n foaf:firstName employees.FirstName\n as virtrdf:Employee-foaf_first_name ;\n northwind:firstName employees.FirstName\n as virtrdf:Employee-first_name ;\n foaf:title employees.Title\n as virtrdf:Employee-title ;\n northwind:titleOfCourtesy employees.TitleOfCourtesy\n as virtrdf:Employee-title_of_courtesy ;\n foaf:birthday employees.BirthDate\n as virtrdf:Employee-foaf_birth_date ;\n northwind:birthday employees.BirthDate\n as virtrdf:Employee-birth_date ;\n northwind:hireDate employees.HireDate\n as virtrdf:Employee-hire_date ;\n northwind:address employees.Address\n as virtrdf:Employee-address ;\n northwind:city northwind:dbpedia_iri2(employees.City)\n as virtrdf:Employee-dbpediacity ;\n northwind:region employees.Region\n as virtrdf:Employee-region ;\n northwind:postalCode employees.PostalCode\n as virtrdf:Employee-postal_code ;\n northwind:country northwind:Country(employees.Country)\n as virtrdf:Employee-country ;\n foaf:phone employees.HomePhone\n as virtrdf:Employee-home_phone ;\n northwind:extension employees.Extension\n as virtrdf:Employee-extension ;\n northwind:notes employees.Notes\n as virtrdf:Employee-notes ;\n northwind:reportsTo northwind:Employee(employees.FirstName, employees.LastName, employees.ReportsTo) where (^{employees.}^.ReportsTo = ^{employees.}^.EmployeeID)\n as virtrdf:Employee-reports_to ;\n foaf:img northwind:EmployeePhoto(employees.EmployeeID)\n as virtrdf:Employee-employees.EmployeePhoto ;\n opl:isDescribedUsing northwind: .\n\n northwind:EmployeePhoto(employees.EmployeeID)\n a northwind:EmployeePhoto\n as virtrdf:Employee-employees.EmployeePhotoId ;\n opl:isDescribedUsing northwind: .\n\n northwind:Employee (employees.FirstName, employees.LastName, orders.EmployeeID)\n northwind:is_salesrep_of\n northwind:Order (orders.OrderID) where (^{orders.}^.EmployeeID = ^{employees.}^.EmployeeID) as virtrdf:Order-is_salesrep_of .\n\n northwind:Country (employees.Country)\n northwind:is_country_of\n northwind:Employee (employees.FirstName, employees.LastName, employees.EmployeeID) as virtrdf:Employee-is_country_of .\n\n northwind:Order (orders.OrderID)\n a northwind:Order\n as virtrdf:Order-Order ;\n northwind:has_customer northwind:Customer (orders.CustomerID)\n as virtrdf:Order-order_has_customer ;\n northwind:has_salesrep northwind:Employee (employees.FirstName, employees.LastName, orders.EmployeeID) where (^{orders.}^.EmployeeID = ^{employees.}^.EmployeeID)\n as virtrdf:Customer-has_salesrep ;\n northwind:has_employee northwind:Employee (employees.FirstName, employees.LastName, orders.EmployeeID) where (^{orders.}^.EmployeeID = ^{employees.}^.EmployeeID)\n as virtrdf:Order-order_has_employee ;\n northwind:orderDate orders.OrderDate\n as virtrdf:Order-order_date ;\n northwind:requiredDate orders.RequiredDate\n as virtrdf:Order-required_date ;\n northwind:shippedDate orders.ShippedDate\n as virtrdf:Order-shipped_date ;\n northwind:order_ship_via northwind:Shipper (orders.ShipVia)\n as virtrdf:Order-order_ship_via ;\n northwind:freight orders.Freight\n as virtrdf:Order-freight ;\n northwind:shipName orders.ShipName\n as virtrdf:Order-ship_name ;\n northwind:shipAddress orders.ShipAddress\n as virtrdf:Order-ship_address ;\n northwind:shipCity northwind:dbpedia_iri2(orders.ShipCity)\n as virtrdf:Order-dbpediaship_city ;\n northwind:shipRegion orders.ShipRegion\n as virtrdf:Order-ship_region ;\n northwind:shipPostal_code orders.ShipPostalCode\n as virtrdf:Order-ship_postal_code ;\n northwind:shipCountry northwind:Country(orders.ShipCountry)\n as virtrdf:ship_country ;\n opl:isDescribedUsing northwind: .\n\n northwind:Country (orders.ShipCountry)\n northwind:is_ship_country_of\n northwind:Order (orders.OrderID) as virtrdf:Order-is_country_of .\n\n northwind:Customer (orders.CustomerID)\n northwind:has_order northwind:Order (orders.OrderID) as virtrdf:Order-has_order .\n\n northwind:Shipper (orders.ShipVia)\n northwind:ship_order northwind:Order (orders.OrderID) as virtrdf:Order-ship_order .\n\n northwind:OrderLine (order_lines.OrderID, order_lines.ProductID)\n a northwind:OrderLine\n as virtrdf:OrderLine-OrderLines ;\n northwind:has_order_id northwind:Order (order_lines.OrderID)\n as virtrdf:order_lines_has_order_id ;\n northwind:has_product_id northwind:Product (order_lines.ProductID)\n as virtrdf:order_lines_has_product_id ;\n northwind:unitPrice order_lines.UnitPrice\n as virtrdf:OrderLine-unit_price ;\n northwind:quantity order_lines.Quantity\n as virtrdf:OrderLine-quantity ;\n northwind:discount order_lines.Discount\n as virtrdf:OrderLine-discount ;\n opl:isDescribedUsing northwind: .\n\n northwind:Order (orders.OrderID)\n northwind:is_order_of\n northwind:OrderLine (order_lines.OrderID, order_lines.ProductID) where (^{orders.}^.OrderID = ^{order_lines.}^.OrderID) as virtrdf:Order-is_order_of .\n\n northwind:Product (products.ProductID)\n northwind:is_product_of\n northwind:OrderLine (order_lines.OrderID, order_lines.ProductID) where (^{products.}^.ProductID = ^{order_lines.}^.ProductID) as virtrdf:Product-is_product_of .\n\n northwind:Country (countries.Name)\n a northwind:Country\n as virtrdf:Country-Type2 ;\n a wgs:SpatialThing\n as virtrdf:Country-Type ;\n owl:sameAs northwind:dbpedia_iri2 (countries.Name) ;\n northwind:name countries.Name\n as virtrdf:Country-Name ;\n northwind:code countries.Code\n as virtrdf:Country-Code ;\n northwind:smallFlagDAVResourceName countries.SmallFlagDAVResourceName\n as virtrdf:Country-SmallFlagDAVResourceName ;\n northwind:largeFlagDAVResourceName countries.LargeFlagDAVResourceName\n as virtrdf:Country-LargeFlagDAVResourceName ;\n northwind:smallFlagDAVResourceURI northwind:Flag(countries.SmallFlagDAVResourceURI)\n as virtrdf:Country-SmallFlagDAVResourceURI ;\n northwind:largeFlagDAVResourceURI northwind:Flag(countries.LargeFlagDAVResourceURI)\n as virtrdf:Country-LargeFlagDAVResourceURI ;\n wgs:lat countries.Lat\n as virtrdf:Country-Lat ;\n wgs:long countries.Lng\n as virtrdf:Country-Lng ;\n opl:isDescribedUsing northwind: .\n\n northwind:Country (countries.Name)\n northwind:has_province\n northwind:Province (provinces.CountryCode, provinces.Province) where (^{provinces.}^.CountryCode = ^{countries.}^.Code) as virtrdf:Country-has_province .\n\n northwind:Province (provinces.CountryCode, provinces.Province)\n a northwind:Province\n as virtrdf:Province-Provinces ;\n owl:sameAs northwind:dbpedia_iri2 (provinces.Province) ;\n northwind:has_country_code provinces.CountryCode\n as virtrdf:has_country_code ;\n northwind:provinceName provinces.Province\n as virtrdf:Province-ProvinceName ;\n opl:isDescribedUsing northwind: .\n\n northwind:Province (provinces.CountryCode, provinces.Province)\n northwind:is_province_of\n northwind:Country (countries.Name) where (^{countries.}^.Code = ^{provinces.}^.CountryCode) as virtrdf:Province-country_of .\n }.\n}.\n;\n\ndelete from DB.DBA.URL_REWRITE_RULE_LIST where urrl_list like 'demo_nw%';\ndelete from DB.DBA.URL_REWRITE_RULE where urr_rule like 'demo_nw%';\n\nDB.DBA.URLREWRITE_CREATE_REGEX_RULE (\n 'demo_nw_rule2',\n 1,\n '(/[^#]*)',\n vector('path'),\n 1,\n '/sparql?query=DESCRIBE+%%3Chttp%%3A//^{URIQADefaultHost}^%U%%23this%%3E+%%3Chttp%%3A//^{URIQADefaultHost}^%U%%3E+FROM+%%3Chttp%%3A//^{URIQADefaultHost}^/Northwind%%3E&format=%U',\n vector('path', 'path', '*accept*'),\n null,\n '(text/rdf.n3)|(application/rdf.xml)',\n 0,\n null\n );\n\nDB.DBA.URLREWRITE_CREATE_REGEX_RULE (\n 'demo_nw_rule1',\n 1,\n '(/[^#]*)',\n vector('path'),\n 1,\n '/about/html/http/^{URIQADefaultHost}^%s',\n vector('path'),\n null,\n '(text/html)|(\\\\*/\\\\*)',\n 0,\n 303\n );\n\nDB.DBA.URLREWRITE_CREATE_RULELIST (\n 'demo_nw_rule_list1',\n 1,\n vector (\n 'demo_nw_rule1',\n 'demo_nw_rule2'\n ));\n\n\nVHOST_REMOVE (lpath=>'/Northwind');\nDB.DBA.VHOST_DEFINE (lpath=>'/Northwind', ppath=>'/DAV/home/demo/', vsp_user=>'dba', is_dav=>1,\n is_brws=>0, opts=>vector ('url_rewrite', 'demo_nw_rule_list1'));\n\ncreate procedure DB.DBA.LOAD_NW_ONTOLOGY_FROM_DAV()\n{\n declare content1, urihost varchar;\n select cast (RES_CONTENT as varchar) into content1 from WS.WS.SYS_DAV_RES where RES_FULL_PATH = '/DAV/VAD/demo/sql/nw.owl';\n DB.DBA.RDF_LOAD_RDFXML (content1, 'http://demo.openlinksw.com/schemas/northwind#', 'http://demo.openlinksw.com/schemas/NorthwindOntology/1.0/');\n urihost := cfg_item_value(virtuoso_ini_path(), 'URIQA','DefaultHost');\n if (urihost = 'demo.openlinksw.com')\n {\n DB.DBA.VHOST_REMOVE (lpath=>'/schemas/northwind');\n DB.DBA.VHOST_DEFINE (lpath=>'/schemas/northwind', ppath=>'/DAV/VAD/demo/sql/nw.owl', vsp_user=>'dba', is_dav=>1, is_brws=>0);\n DB.DBA.VHOST_REMOVE (lpath=>'/schemas/northwind#');\n DB.DBA.VHOST_DEFINE (lpath=>'/schemas/northwind#', ppath=>'/DAV/VAD/demo/sql/nw.owl', vsp_user=>'dba', is_dav=>1, is_brws=>0);\n }\n};\n\nDB.DBA.LOAD_NW_ONTOLOGY_FROM_DAV();\ndrop procedure DB.DBA.LOAD_NW_ONTOLOGY_FROM_DAV;\n\nDB.DBA.XML_SET_NS_DECL ('northwind', 'http://demo.openlinksw.com/schemas/northwind#', 2);\n\n\n\n---+++References\n\n * [[NorthWindREF][Virtuoso NorthWind SPARQL Reference Collection]]" . "VirtRDFViewNorthwindScript" . . .