diff --git a/index.html b/index.html index a078b39..4a36a7f 100644 --- a/index.html +++ b/index.html @@ -8,6 +8,7 @@

Examples

diff --git a/package.json b/package.json index f3fe7e4..67659e0 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "azdataGraph", "description": "azdataGraph is a derivative of mxGraph, which is a fully client side JavaScript diagramming library that uses SVG and HTML for rendering.", - "version": "0.0.71", + "version": "0.0.72", "homepage": "https://github.com/microsoft/azdataGraph", "author": "Microsoft", "license": "Apache-2.0", @@ -42,5 +42,8 @@ "typescript": "^5.7.2", "typescript-eslint": "^8.18.0", "vite": "^6.0.7" + }, + "dependencies": { + "create-color": "^2.0.6" } } diff --git a/src/ts/schemaDesigner/schemaDesigner.css b/src/ts/schemaDesigner/schemaDesigner.css index 0758050..86445dd 100644 --- a/src/ts/schemaDesigner/schemaDesigner.css +++ b/src/ts/schemaDesigner/schemaDesigner.css @@ -19,8 +19,8 @@ width: fit-content; gap: 0.5rem; display: flex; - background-color: var(--color-toolbar-bg); - color: var(--color-toolbar-text); + background-color: var(--sd-toolbar-background-color); + color: var(--sd-toolbar-foreground-color); padding: 5px; border-radius: 0.8rem; vertical-align: middle; @@ -43,13 +43,13 @@ } .sd-toolbar-button:hover { - background-color: var(--color-toolbar-button-hover); + background-color: var(--sd-toolbar-hover-background-color); } .sd-toolbar-divider { height: 100%; width: 1px; - background-color: var(--color-toolbar-divider); + background-color: var(--sd-toolbar-divider-background-color); } #graphContainer { @@ -58,21 +58,22 @@ z-index: var(--sd-z-base); background-image: radial-gradient( circle, - var(--color-graph-gridLines) 10%, + var(--sd-graph-grid-color) 10%, transparent 10% ); background-size: 20px 20px; background-repeat: repeat; overflow: auto; + background-color: var(--sd-graph-background-color); } - + .sd-outline { position: fixed; right: 10px; bottom: 10px; - border-radius: 0.3rem; + border-radius: 0.2rem; z-index: var(--sd-z-toolbar); - border: 1px solid var(--color-border); + border: 1px solid var(--sd-border-color); box-shadow: 0px 3px 8px rgba(0, 0, 0, 0.35), 0px 1px 3px rgba(0, 0, 0, 0.5), inset 0px 0.5px 0px rgba(255, 255, 255, 0.08), inset 0px 0px 0.5px rgba(255, 255, 255, 0.3); @@ -85,18 +86,18 @@ width: 260px; height: 100%; border-radius: 2px; + color: var(--sd-cell-html-foreground); box-shadow: 0px 3px 8px rgba(0, 0, 0, 0.35), 0px 1px 3px rgba(0, 0, 0, 0.5), inset 0px 0.5px 0px rgba(255, 255, 255, 0.08), inset 0px 0px 0.5px rgba(255, 255, 255, 0.3); display: flex; flex-direction: column; - background-color: var(--color-graph-background); + background-color: var(--sd-graph-background-color); } .sd-table-color-indicator { width: 100%; height: 6px; - background-color: var(--color-graph-table-indicator); border-radius: 2px 2px 0 0; } @@ -104,7 +105,7 @@ display: flex; gap: 10px; height: 40px; - border-bottom: 1px solid var(--color-border); + border-bottom: 1px solid var(--sd-border-color); } @@ -120,7 +121,6 @@ .sd-table-header-text { font-size: 14px; font-weight: 500; - color: var(--color-table-header-text); align-self: center; text-align: left; flex: 1; diff --git a/src/ts/schemaDesigner/schemaDesigner.ts b/src/ts/schemaDesigner/schemaDesigner.ts index 3f8cdee..54005fd 100644 --- a/src/ts/schemaDesigner/schemaDesigner.ts +++ b/src/ts/schemaDesigner/schemaDesigner.ts @@ -2,7 +2,7 @@ import './schemaDesigner.css'; import '../../css/common.css'; import { IColumn, IEntity, IRelationship, ISchema, OnAction, SchemaDesignerConfig } from './schemaDesignerInterfaces'; -import { mxCell, mxEditor, mxGraph, mxGraphModel, mxHierarchicalLayout } from 'mxgraph'; +import { mxCell, mxEditor, mxGraph, mxGraphLayout, mxGraphModel } from 'mxgraph'; import { mxGraphFactory as mx } from '../mx'; import { SchemaDesignerToolbar } from './schemaDesignerToolbar'; @@ -18,7 +18,7 @@ export class SchemaDesigner { public _graph!: mxGraph; private _model!: mxGraphModel; private _toolbar!: SchemaDesignerToolbar; - private _layout!: mxHierarchicalLayout; + private _layout!: mxGraphLayout; private cellClickListeners: ((cell: mxCell) => void)[] = []; @@ -31,25 +31,88 @@ export class SchemaDesigner { private initializeGraph() { this.overwriteMxGraphDefaults(); + this.addCustomEdgeTerminals(); this._editor = new mx.mxEditor(); - const graphContainer = document.createElement("div"); - graphContainer.classList.add("sd-graph-container"); - this._container.appendChild(graphContainer); - this._editor.setGraphContainer(graphContainer); + this._editor.setGraphContainer(this._container); this._graph = this._editor.graph; this._model = this._graph.getModel(); this.setupEditorOptions(); this.setupGraphOptions(); + this.setupColors(); this.setupGraphOutlineOptions(); this.setupToolbar(); } + private setupColors() { + this._container.style.setProperty("--sd-toolbar-background-color", this._config.colors.toolbarBackground); + this._container.style.setProperty("--sd-toolbar-foreground-color", this._config.colors.toolbarForeground); + this._container.style.setProperty("--sd-toolbar-hover-background-color", this._config.colors.toolbarHoverBackground); + this._container.style.setProperty("--sd-toolbar-divider-background-color", this._config.colors.toolbarDividerBackground); + + this._container.style.setProperty("--sd-graph-background-color", this._config.colors.graphBackground); + this._container.style.setProperty("--sd-graph-grid-color", this._config.colors.graphGrid); + this._container.style.setProperty("--sd-border-color", this._config.colors.cellBorder); + + this._container.style.setProperty("--sd-cell-html-foreground", this._config.colors.cellForeground); + + this._graph.getStylesheet().getDefaultVertexStyle()["fillColor"] = this._config.colors.cellBackground; + this._graph.getStylesheet().getDefaultEdgeStyle()["strokeColor"] = this._config.colors.edge; + this._graph.getStylesheet().getDefaultVertexStyle()['cellHighlightColor'] = this._config.colors.cellHighlight; + this._graph.getStylesheet().getDefaultVertexStyle()['cellHightlightStrokeWidth'] = 3; + + + this._graph.getStylesheet().getDefaultEdgeStyle()['cellHighlightColor'] = this._config.colors.cellHighlight; + mx.mxConstants.OUTLINE_HANDLE_FILLCOLOR = this._config.colors.cellHighlight + mx.mxConstants.OUTLINE_HANDLE_STROKECOLOR = this._config.colors.cellHighlight; + mx.mxConstants.OUTLINE_COLOR = this._config.colors.cellHighlight; + } + private overwriteMxGraphDefaults() { mx.mxClient.NO_FO = true; mx.mxEvent.disableContextMenu(this._container); - mx.mxConstants.DEFAULT_VALID_COLOR = this._config.color.validColor; - mx.mxConstants.VALID_COLOR = this._config.color.validColor; - mx.mxConstants.INVALID_COLOR = this._config.color.invalidColor; + } + + private addCustomEdgeTerminals() { + mx.mxMarker.addMarker("one", (canvas, _shape, _type, pe, unitX, unitY, size, _source, _sw, _filled) => { + return () => { + const endX = pe.x - unitX * size; + const endY = pe.y - unitY * size; + + const midX = endX - unitY * size; + const midY = endY + unitX * size; + + const startX = endX + unitY * size; + const startY = endY - unitX * size; + + canvas.begin(); + canvas.moveTo(startX, startY); + canvas.lineTo(midX, midY); + canvas.stroke(); + }; + }); + + mx.mxMarker.addMarker("many", (canvas, _shape, _type, pe, unitX, unitY, size, _source, _sw, _filled) => { + return () => { + const arrowSize = 1.5; + const startX = pe.x - unitX * size * arrowSize; + const startY = pe.y - unitY * size * arrowSize; + + const Y1 = pe.y + unitX * size * arrowSize; + const X1 = pe.x; + const Y2 = pe.y - unitX * size * arrowSize; + const X2 = pe.x; + + canvas.begin(); + canvas.moveTo(startX, startY); + canvas.lineTo(X1, Y1); + canvas.stroke(); + + canvas.begin(); + canvas.moveTo(startX, startY); + canvas.lineTo(X2, Y2); + canvas.stroke(); + }; + }); } private setupEditorOptions() { @@ -57,12 +120,10 @@ export class SchemaDesigner { } private setupGraphOptions() { - this._graph.setResizeContainer(true); this._graph.tooltipHandler.setEnabled(false); this._graph.setConnectable(true); this._graph.setAllowDanglingEdges(false); this._graph.setHtmlLabels(true); - this._graph.allowLoops = false; this._graph.connectionHandler.enabled = false; this._graph.connectionHandler.movePreviewAway = false; this._graph.connectionHandler.moveIconFront = true; @@ -73,10 +134,12 @@ export class SchemaDesigner { ); this._graph.connectionHandler.factoryMethod = null!; this._layout = new SchemaDesignerLayout(this._graph); - this._layout.intraCellSpacing = 30; + this._graph.setCellsDisconnectable(false); - this._graph.autoExtend = true; - new mx.mxRubberband(this._graph); + this._graph.autoSizeCellsOnAdd = true; + this._graph.getSelectionModel().setSingleSelection(true); + this._graph.setPanning(true); + this._graph.panningHandler.useLeftButtonForPanning = true; this._graph.view.updateFloatingTerminalPoint = function (edge, start, end, source) { const next = this.getNextPoint(edge, end, source); @@ -402,10 +465,7 @@ export class SchemaDesigner { this.cellClickListeners.forEach((listener) => listener(cell)); } }); - - this._graph.getStylesheet().getDefaultVertexStyle()['cellHighlightColor'] = "red"; this._graph.getStylesheet().getDefaultEdgeStyle()['edgeStyle'] = mx.mxEdgeStyle.ElbowConnector; - this._graph.stylesheet.getDefaultEdgeStyle()[mx.mxConstants.STYLE_EDGE] = mx.mxConstants.EDGESTYLE_ENTITY_RELATION; } private setupGraphOutlineOptions() { @@ -490,6 +550,14 @@ export class SchemaDesigner { } ); + this._toolbar.addButton( + this._config.icons.zoomFitIcon, + "Fit", + () => { + this._graph.fit(undefined!); + } + ) + this._toolbar.addDivider(); this._toolbar.addButton( @@ -644,45 +712,10 @@ export class SchemaDesigner { public autoArrange() { this._model.beginUpdate(); this._layout.execute(this._graph.getDefaultParent()); - const cells = this._graph.getChildCells(this._graph.getDefaultParent()); - this._graph.center(); - - const mostNegativeX = this.mostNegativeX(); - console.log('-x', mostNegativeX); - - const mostNegativeY = this.mostNegativeY(); - console.log('-y', mostNegativeY); - - this._graph.moveCells(cells, -mostNegativeX + 100, -mostNegativeY + 100, false); - this._graph.sizeDidChange(); this._model.endUpdate(); } - private mostNegativeX() { - let mostNegativeX = 0; - const cells = this._graph.getChildCells(this._graph.getDefaultParent()); - for (let i = 0; i < cells.length; i++) { - const cell = cells[i]; - if (cell.geometry.x < mostNegativeX) { - mostNegativeX = cell.geometry.x; - } - } - return mostNegativeX; - } - - private mostNegativeY() { - let mostNegativeY = 0; - const cells = this._graph.getChildCells(this._graph.getDefaultParent()); - for (let i = 0; i < cells.length; i++) { - const cell = cells[i]; - if (cell.geometry.y < mostNegativeY) { - mostNegativeY = cell.geometry.y; - } - } - return mostNegativeY; - } - public addCellClickListener(listener: (cell: mxCell) => void) { this.cellClickListeners.push(listener); } diff --git a/src/ts/schemaDesigner/schemaDesignerEntity.ts b/src/ts/schemaDesigner/schemaDesignerEntity.ts index 1eeeed1..af7d027 100644 --- a/src/ts/schemaDesigner/schemaDesignerEntity.ts +++ b/src/ts/schemaDesigner/schemaDesignerEntity.ts @@ -1,5 +1,6 @@ import { mxGraph } from "mxgraph"; import { IColumn, IEntity, SchemaDesignerConfig } from "./schemaDesignerInterfaces"; +import createColor from "create-color"; export class SchemaDesignerEntity implements IEntity { public div!: HTMLElement; @@ -14,11 +15,13 @@ export class SchemaDesignerEntity implements IEntity { } render(): HTMLElement { + const color = createColor(this.schema, { format: "hex" }); const parent = document.createElement("div"); parent.classList.add("sd-table"); const colorIndicator = document.createElement("div"); colorIndicator.classList.add("sd-table-color-indicator"); parent.appendChild(colorIndicator); + colorIndicator.style.backgroundColor = color; const header = document.createElement("div"); header.classList.add("sd-table-header"); const headerIcon = document.createElement("div"); @@ -38,7 +41,11 @@ export class SchemaDesignerEntity implements IEntity { columnDiv.classList.add("sd-table-column"); const columnIcon = document.createElement("div"); columnIcon.classList.add("sd-table-column-icon"); - columnIcon.style.backgroundImage = `url(${this._config.icons.dataTypeIcons![column.dataType]})`; + if(this._config.icons.dataTypeIcons[column.dataType]){ + columnIcon.style.backgroundImage = `url(${this._config.icons.dataTypeIcons[column.dataType]})`; + } else { + columnIcon.style.backgroundImage = `url(${this._config.icons.customDataTypeIcon})`; + } columnDiv.appendChild(columnIcon); const columnText = document.createElement("div"); columnText.classList.add("sd-table-column-text"); diff --git a/src/ts/schemaDesigner/schemaDesignerInterfaces.ts b/src/ts/schemaDesigner/schemaDesignerInterfaces.ts index 0bc5009..8da9522 100644 --- a/src/ts/schemaDesigner/schemaDesignerInterfaces.ts +++ b/src/ts/schemaDesigner/schemaDesignerInterfaces.ts @@ -84,21 +84,36 @@ export interface SchemaDesignerConfig { redoIcon: string; zoomInIcon: string; zoomOutIcon: string; + zoomFitIcon: string; deleteIcon: string; entityIcon: string; dataTypeIcons: { [key: string]: string }; + customDataTypeIcon: string; connectorIcon: string; exportIcon: string; autoarrangeIcon: string; } - color: { - cellFillColor: string; - cellHighlightColor: string; - edgeStrokeColor: string; - outlineColor: string; - toolbarBackgroundColor: string; - validColor: string; - invalidColor: string; + colors: { + + cellHighlight: string; + cellForeground: string; + cellBackground: string; + cellBorder: string; + + toolbarBackground: string; + toolbarForeground: string; + toolbarHoverBackground: string; + toolbarDividerBackground: string; + + graphBackground: string; + graphGrid: string; + + edge: string; + + outlineCellBackground: string; + outlineBorder: string; + outlineSize: string; + outlineSizerRectangle: string; } graphFontFamily: string; isEditable: boolean; diff --git a/src/ts/schemaDesigner/schemaDesignerLayout.ts b/src/ts/schemaDesigner/schemaDesignerLayout.ts index 6434d5b..4b10e4b 100644 --- a/src/ts/schemaDesigner/schemaDesignerLayout.ts +++ b/src/ts/schemaDesigner/schemaDesignerLayout.ts @@ -7,6 +7,65 @@ export class SchemaDesignerLayout extends mx.mxHierarchicalLayout { } public override execute(parent: mxCell): void { + this.interHierarchySpacing = 100; + this.orientation = mx.mxConstants.DIRECTION_WEST; + super.execute(parent); + + // let cells = this.graph.getModel().getChildCells(this.graph.getDefaultParent()); + // cells = cells.filter(cell => !cell.edge); + // const cellSet = new Set(cells.map(cell => cell.id)); + + // this.graph.getModel().beginUpdate(); + // // Find all subgraphs + // const subGraphs: mxCell[][] = []; + // for (const cell of cells) { + // if (cellSet.has(cell.id)) { + // const subGraph: mxCell[] = []; + // const queue: mxCell[] = [cell]; + // cellSet.delete(cell.id); + // while (queue.length > 0) { + // const current = queue.shift() as mxCell; + // cellSet.delete(current.id); + // subGraph.push(current); + // const edges = this.graph.getModel().getEdges(current); + // for (const edge of edges) { + // let nextNode: mxCell | undefined = undefined; + // if (edge.source.id === current.id) { + // nextNode = edge.target; + // } else if (edge.target.id === current.id) { + // nextNode = edge.source; + // } + // if (nextNode !== undefined) { + // if (cellSet.has(nextNode!.id)) { + // queue.push(nextNode!); + // cellSet.delete(nextNode!.id); + // } + // } + // } + // } + // subGraphs.push(subGraph); + // } + // } + + // const boundingBoxes = subGraphs.map(subGraph => { + // let minX = Number.MAX_VALUE; + // let minY = Number.MAX_VALUE; + // let maxX = Number.MIN_VALUE; + // let maxY = Number.MIN_VALUE; + // for (const cell of subGraph) { + // const geo = cell.getGeometry(); + // if (geo) { + // minX = Math.min(minX, geo.x); + // minY = Math.min(minY, geo.y); + // maxX = Math.max(maxX, geo.x + geo.width); + // maxY = Math.max(maxY, geo.y + geo.height); + // } + // } + // return { minX, minY, maxX, maxY }; + // }); + + // console.log(boundingBoxes); + // this.graph.getModel().endUpdate(); } } \ No newline at end of file diff --git a/src/ts/schemaDesigner/schemaDesignerToolbar.ts b/src/ts/schemaDesigner/schemaDesignerToolbar.ts index d98f991..b49648b 100644 --- a/src/ts/schemaDesigner/schemaDesignerToolbar.ts +++ b/src/ts/schemaDesigner/schemaDesignerToolbar.ts @@ -23,7 +23,7 @@ export class SchemaDesignerToolbar { button.title = title; if (onDragEndCallback) { const dragImage = button.cloneNode(true) as HTMLElement; - dragImage.style.backgroundColor = this._config.color.toolbarBackgroundColor; + dragImage.style.backgroundColor = this._config.colors.toolbarBackground; const ds = mx.mxUtils.makeDraggable( button, this._graph, diff --git a/ts-examples/adventureWorks.js b/ts-examples/adventureWorks.js new file mode 100644 index 0000000..e9ce224 --- /dev/null +++ b/ts-examples/adventureWorks.js @@ -0,0 +1,4168 @@ +export const adventureWorks = +{ + "entities": [ + { + "name": "SalesTaxRate", + "schema": "Sales", + "columns": [ + { + "name": "SalesTaxRateID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "StateProvinceID", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "TaxType", + "dataType": "tinyint", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "TaxRate", + "dataType": "smallmoney", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Name", + "dataType": "Name", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "rowguid", + "dataType": "uniqueidentifier", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "PersonCreditCard", + "schema": "Sales", + "columns": [ + { + "name": "BusinessEntityID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "CreditCardID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "PersonPhone", + "schema": "Person", + "columns": [ + { + "name": "BusinessEntityID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "PhoneNumber", + "dataType": "Phone", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "PhoneNumberTypeID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "SalesTerritory", + "schema": "Sales", + "columns": [ + { + "name": "TerritoryID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "Name", + "dataType": "Name", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "CountryRegionCode", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Group", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "SalesYTD", + "dataType": "money", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "SalesLastYear", + "dataType": "money", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "CostYTD", + "dataType": "money", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "CostLastYear", + "dataType": "money", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "rowguid", + "dataType": "uniqueidentifier", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "PhoneNumberType", + "schema": "Person", + "columns": [ + { + "name": "PhoneNumberTypeID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "Name", + "dataType": "Name", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "Product", + "schema": "Production", + "columns": [ + { + "name": "ProductID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "Name", + "dataType": "Name", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ProductNumber", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "MakeFlag", + "dataType": "Flag", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "FinishedGoodsFlag", + "dataType": "Flag", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Color", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "SafetyStockLevel", + "dataType": "smallint", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ReorderPoint", + "dataType": "smallint", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "StandardCost", + "dataType": "money", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ListPrice", + "dataType": "money", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Size", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "SizeUnitMeasureCode", + "dataType": "nchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "WeightUnitMeasureCode", + "dataType": "nchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Weight", + "dataType": "decimal", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "DaysToManufacture", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ProductLine", + "dataType": "nchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Class", + "dataType": "nchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Style", + "dataType": "nchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ProductSubcategoryID", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ProductModelID", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "SellStartDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "SellEndDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "DiscontinuedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "rowguid", + "dataType": "uniqueidentifier", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "SalesTerritoryHistory", + "schema": "Sales", + "columns": [ + { + "name": "BusinessEntityID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "TerritoryID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "StartDate", + "dataType": "datetime", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "EndDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "rowguid", + "dataType": "uniqueidentifier", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "ScrapReason", + "schema": "Production", + "columns": [ + { + "name": "ScrapReasonID", + "dataType": "smallint", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "Name", + "dataType": "Name", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "Shift", + "schema": "HumanResources", + "columns": [ + { + "name": "ShiftID", + "dataType": "tinyint", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "Name", + "dataType": "Name", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "StartTime", + "dataType": "time", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "EndTime", + "dataType": "time", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "ProductCategory", + "schema": "Production", + "columns": [ + { + "name": "ProductCategoryID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "Name", + "dataType": "Name", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "rowguid", + "dataType": "uniqueidentifier", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "ShipMethod", + "schema": "Purchasing", + "columns": [ + { + "name": "ShipMethodID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "Name", + "dataType": "Name", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ShipBase", + "dataType": "money", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ShipRate", + "dataType": "money", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "rowguid", + "dataType": "uniqueidentifier", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "ProductCostHistory", + "schema": "Production", + "columns": [ + { + "name": "ProductID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "StartDate", + "dataType": "datetime", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "EndDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "StandardCost", + "dataType": "money", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "ProductDescription", + "schema": "Production", + "columns": [ + { + "name": "ProductDescriptionID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "Description", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "rowguid", + "dataType": "uniqueidentifier", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "ShoppingCartItem", + "schema": "Sales", + "columns": [ + { + "name": "ShoppingCartItemID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "ShoppingCartID", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Quantity", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ProductID", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "DateCreated", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "ProductDocument", + "schema": "Production", + "columns": [ + { + "name": "ProductID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "DocumentNode", + "dataType": "hierarchyid", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "DatabaseLog", + "schema": "dbo", + "columns": [ + { + "name": "DatabaseLogID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "PostTime", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "DatabaseUser", + "dataType": "sysname", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Event", + "dataType": "sysname", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Schema", + "dataType": "sysname", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Object", + "dataType": "sysname", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "TSQL", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "XmlEvent", + "dataType": "xml", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "ProductInventory", + "schema": "Production", + "columns": [ + { + "name": "ProductID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "LocationID", + "dataType": "smallint", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "Shelf", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Bin", + "dataType": "tinyint", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Quantity", + "dataType": "smallint", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "rowguid", + "dataType": "uniqueidentifier", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "SpecialOffer", + "schema": "Sales", + "columns": [ + { + "name": "SpecialOfferID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "Description", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "DiscountPct", + "dataType": "smallmoney", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Type", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Category", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "StartDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "EndDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "MinQty", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "MaxQty", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "rowguid", + "dataType": "uniqueidentifier", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "ErrorLog", + "schema": "dbo", + "columns": [ + { + "name": "ErrorLogID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "ErrorTime", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "UserName", + "dataType": "sysname", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ErrorNumber", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ErrorSeverity", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ErrorState", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ErrorProcedure", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ErrorLine", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ErrorMessage", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "ProductListPriceHistory", + "schema": "Production", + "columns": [ + { + "name": "ProductID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "StartDate", + "dataType": "datetime", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "EndDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ListPrice", + "dataType": "money", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "Address", + "schema": "Person", + "columns": [ + { + "name": "AddressID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "AddressLine1", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "AddressLine2", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "City", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "StateProvinceID", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "PostalCode", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "SpatialLocation", + "dataType": "geography", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "rowguid", + "dataType": "uniqueidentifier", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "SpecialOfferProduct", + "schema": "Sales", + "columns": [ + { + "name": "SpecialOfferID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "ProductID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "rowguid", + "dataType": "uniqueidentifier", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "ProductModel", + "schema": "Production", + "columns": [ + { + "name": "ProductModelID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "Name", + "dataType": "Name", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "CatalogDescription", + "dataType": "xml", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Instructions", + "dataType": "xml", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "rowguid", + "dataType": "uniqueidentifier", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "AddressType", + "schema": "Person", + "columns": [ + { + "name": "AddressTypeID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "Name", + "dataType": "Name", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "rowguid", + "dataType": "uniqueidentifier", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "StateProvince", + "schema": "Person", + "columns": [ + { + "name": "StateProvinceID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "StateProvinceCode", + "dataType": "nchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "CountryRegionCode", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "IsOnlyStateProvinceFlag", + "dataType": "Flag", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Name", + "dataType": "Name", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "TerritoryID", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "rowguid", + "dataType": "uniqueidentifier", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "ProductModelIllustration", + "schema": "Production", + "columns": [ + { + "name": "ProductModelID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "IllustrationID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "AWBuildVersion", + "schema": "dbo", + "columns": [ + { + "name": "SystemInformationID", + "dataType": "tinyint", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "Database Version", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "VersionDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "ProductModelProductDescriptionCulture", + "schema": "Production", + "columns": [ + { + "name": "ProductModelID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "ProductDescriptionID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "CultureID", + "dataType": "nchar", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "BillOfMaterials", + "schema": "Production", + "columns": [ + { + "name": "BillOfMaterialsID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "ProductAssemblyID", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ComponentID", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "StartDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "EndDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "UnitMeasureCode", + "dataType": "nchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "BOMLevel", + "dataType": "smallint", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "PerAssemblyQty", + "dataType": "decimal", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "Store", + "schema": "Sales", + "columns": [ + { + "name": "BusinessEntityID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "Name", + "dataType": "Name", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "SalesPersonID", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Demographics", + "dataType": "xml", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "rowguid", + "dataType": "uniqueidentifier", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "ProductPhoto", + "schema": "Production", + "columns": [ + { + "name": "ProductPhotoID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "ThumbNailPhoto", + "dataType": "varbinary", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ThumbnailPhotoFileName", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "LargePhoto", + "dataType": "varbinary", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "LargePhotoFileName", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "ProductProductPhoto", + "schema": "Production", + "columns": [ + { + "name": "ProductID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "ProductPhotoID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "Primary", + "dataType": "Flag", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "TransactionHistory", + "schema": "Production", + "columns": [ + { + "name": "TransactionID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "ProductID", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ReferenceOrderID", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ReferenceOrderLineID", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "TransactionDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "TransactionType", + "dataType": "nchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Quantity", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ActualCost", + "dataType": "money", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "ProductReview", + "schema": "Production", + "columns": [ + { + "name": "ProductReviewID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "ProductID", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ReviewerName", + "dataType": "Name", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ReviewDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "EmailAddress", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Rating", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Comments", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "BusinessEntity", + "schema": "Person", + "columns": [ + { + "name": "BusinessEntityID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "rowguid", + "dataType": "uniqueidentifier", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "TransactionHistoryArchive", + "schema": "Production", + "columns": [ + { + "name": "TransactionID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "ProductID", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ReferenceOrderID", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ReferenceOrderLineID", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "TransactionDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "TransactionType", + "dataType": "nchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Quantity", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ActualCost", + "dataType": "money", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "ProductSubcategory", + "schema": "Production", + "columns": [ + { + "name": "ProductSubcategoryID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "ProductCategoryID", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Name", + "dataType": "Name", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "rowguid", + "dataType": "uniqueidentifier", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "BusinessEntityAddress", + "schema": "Person", + "columns": [ + { + "name": "BusinessEntityID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "AddressID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "AddressTypeID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "rowguid", + "dataType": "uniqueidentifier", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "ProductVendor", + "schema": "Purchasing", + "columns": [ + { + "name": "ProductID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "BusinessEntityID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "AverageLeadTime", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "StandardPrice", + "dataType": "money", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "LastReceiptCost", + "dataType": "money", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "LastReceiptDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "MinOrderQty", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "MaxOrderQty", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "OnOrderQty", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "UnitMeasureCode", + "dataType": "nchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "BusinessEntityContact", + "schema": "Person", + "columns": [ + { + "name": "BusinessEntityID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "PersonID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "ContactTypeID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "rowguid", + "dataType": "uniqueidentifier", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "UnitMeasure", + "schema": "Production", + "columns": [ + { + "name": "UnitMeasureCode", + "dataType": "nchar", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "Name", + "dataType": "Name", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "Vendor", + "schema": "Purchasing", + "columns": [ + { + "name": "BusinessEntityID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "AccountNumber", + "dataType": "AccountNumber", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Name", + "dataType": "Name", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "CreditRating", + "dataType": "tinyint", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "PreferredVendorStatus", + "dataType": "Flag", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ActiveFlag", + "dataType": "Flag", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "PurchasingWebServiceURL", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "ContactType", + "schema": "Person", + "columns": [ + { + "name": "ContactTypeID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "Name", + "dataType": "Name", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "CountryRegionCurrency", + "schema": "Sales", + "columns": [ + { + "name": "CountryRegionCode", + "dataType": "nvarchar", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "CurrencyCode", + "dataType": "nchar", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "CountryRegion", + "schema": "Person", + "columns": [ + { + "name": "CountryRegionCode", + "dataType": "nvarchar", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "Name", + "dataType": "Name", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "WorkOrder", + "schema": "Production", + "columns": [ + { + "name": "WorkOrderID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "ProductID", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "OrderQty", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "StockedQty", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ScrappedQty", + "dataType": "smallint", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "StartDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "EndDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "DueDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ScrapReasonID", + "dataType": "smallint", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "PurchaseOrderDetail", + "schema": "Purchasing", + "columns": [ + { + "name": "PurchaseOrderID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "PurchaseOrderDetailID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "DueDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "OrderQty", + "dataType": "smallint", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ProductID", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "UnitPrice", + "dataType": "money", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "LineTotal", + "dataType": "money", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ReceivedQty", + "dataType": "decimal", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "RejectedQty", + "dataType": "decimal", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "StockedQty", + "dataType": "decimal", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "CreditCard", + "schema": "Sales", + "columns": [ + { + "name": "CreditCardID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "CardType", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "CardNumber", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ExpMonth", + "dataType": "tinyint", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ExpYear", + "dataType": "smallint", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "Culture", + "schema": "Production", + "columns": [ + { + "name": "CultureID", + "dataType": "nchar", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "Name", + "dataType": "Name", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "WorkOrderRouting", + "schema": "Production", + "columns": [ + { + "name": "WorkOrderID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "ProductID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "OperationSequence", + "dataType": "smallint", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "LocationID", + "dataType": "smallint", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ScheduledStartDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ScheduledEndDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ActualStartDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ActualEndDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ActualResourceHrs", + "dataType": "decimal", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "PlannedCost", + "dataType": "money", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ActualCost", + "dataType": "money", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "Currency", + "schema": "Sales", + "columns": [ + { + "name": "CurrencyCode", + "dataType": "nchar", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "Name", + "dataType": "Name", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "PurchaseOrderHeader", + "schema": "Purchasing", + "columns": [ + { + "name": "PurchaseOrderID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "RevisionNumber", + "dataType": "tinyint", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Status", + "dataType": "tinyint", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "EmployeeID", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "VendorID", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ShipMethodID", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "OrderDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ShipDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "SubTotal", + "dataType": "money", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "TaxAmt", + "dataType": "money", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Freight", + "dataType": "money", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "TotalDue", + "dataType": "money", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "CurrencyRate", + "schema": "Sales", + "columns": [ + { + "name": "CurrencyRateID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "CurrencyRateDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "FromCurrencyCode", + "dataType": "nchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ToCurrencyCode", + "dataType": "nchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "AverageRate", + "dataType": "money", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "EndOfDayRate", + "dataType": "money", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "Customer", + "schema": "Sales", + "columns": [ + { + "name": "CustomerID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "PersonID", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "StoreID", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "TerritoryID", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "AccountNumber", + "dataType": "varchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "rowguid", + "dataType": "uniqueidentifier", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "Department", + "schema": "HumanResources", + "columns": [ + { + "name": "DepartmentID", + "dataType": "smallint", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "Name", + "dataType": "Name", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "GroupName", + "dataType": "Name", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "Document", + "schema": "Production", + "columns": [ + { + "name": "DocumentNode", + "dataType": "hierarchyid", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "DocumentLevel", + "dataType": "smallint", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Title", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Owner", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "FolderFlag", + "dataType": "bit", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "FileName", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "FileExtension", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Revision", + "dataType": "nchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ChangeNumber", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Status", + "dataType": "tinyint", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "DocumentSummary", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Document", + "dataType": "varbinary", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "rowguid", + "dataType": "uniqueidentifier", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "SalesOrderDetail", + "schema": "Sales", + "columns": [ + { + "name": "SalesOrderID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "SalesOrderDetailID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "CarrierTrackingNumber", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "OrderQty", + "dataType": "smallint", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ProductID", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "SpecialOfferID", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "UnitPrice", + "dataType": "money", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "UnitPriceDiscount", + "dataType": "money", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "LineTotal", + "dataType": "numeric", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "rowguid", + "dataType": "uniqueidentifier", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "EmailAddress", + "schema": "Person", + "columns": [ + { + "name": "BusinessEntityID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "EmailAddressID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "EmailAddress", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "rowguid", + "dataType": "uniqueidentifier", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "Employee", + "schema": "HumanResources", + "columns": [ + { + "name": "BusinessEntityID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "NationalIDNumber", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "LoginID", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "OrganizationNode", + "dataType": "hierarchyid", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "OrganizationLevel", + "dataType": "smallint", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "JobTitle", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "BirthDate", + "dataType": "date", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "MaritalStatus", + "dataType": "nchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Gender", + "dataType": "nchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "HireDate", + "dataType": "date", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "SalariedFlag", + "dataType": "Flag", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "VacationHours", + "dataType": "smallint", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "SickLeaveHours", + "dataType": "smallint", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "CurrentFlag", + "dataType": "Flag", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "rowguid", + "dataType": "uniqueidentifier", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "SalesOrderHeader", + "schema": "Sales", + "columns": [ + { + "name": "SalesOrderID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "RevisionNumber", + "dataType": "tinyint", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "OrderDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "DueDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ShipDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Status", + "dataType": "tinyint", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "OnlineOrderFlag", + "dataType": "Flag", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "SalesOrderNumber", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "PurchaseOrderNumber", + "dataType": "OrderNumber", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "AccountNumber", + "dataType": "AccountNumber", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "CustomerID", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "SalesPersonID", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "TerritoryID", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "BillToAddressID", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ShipToAddressID", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ShipMethodID", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "CreditCardID", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "CreditCardApprovalCode", + "dataType": "varchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "CurrencyRateID", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "SubTotal", + "dataType": "money", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "TaxAmt", + "dataType": "money", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Freight", + "dataType": "money", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "TotalDue", + "dataType": "money", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Comment", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "rowguid", + "dataType": "uniqueidentifier", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "EmployeeDepartmentHistory", + "schema": "HumanResources", + "columns": [ + { + "name": "BusinessEntityID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "DepartmentID", + "dataType": "smallint", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "ShiftID", + "dataType": "tinyint", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "StartDate", + "dataType": "date", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "EndDate", + "dataType": "date", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "EmployeePayHistory", + "schema": "HumanResources", + "columns": [ + { + "name": "BusinessEntityID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "RateChangeDate", + "dataType": "datetime", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "Rate", + "dataType": "money", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "PayFrequency", + "dataType": "tinyint", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "SalesOrderHeaderSalesReason", + "schema": "Sales", + "columns": [ + { + "name": "SalesOrderID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "SalesReasonID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "SalesPerson", + "schema": "Sales", + "columns": [ + { + "name": "BusinessEntityID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "TerritoryID", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "SalesQuota", + "dataType": "money", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Bonus", + "dataType": "money", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "CommissionPct", + "dataType": "smallmoney", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "SalesYTD", + "dataType": "money", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "SalesLastYear", + "dataType": "money", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "rowguid", + "dataType": "uniqueidentifier", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "Illustration", + "schema": "Production", + "columns": [ + { + "name": "IllustrationID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "Diagram", + "dataType": "xml", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "JobCandidate", + "schema": "HumanResources", + "columns": [ + { + "name": "JobCandidateID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "BusinessEntityID", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Resume", + "dataType": "xml", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "Location", + "schema": "Production", + "columns": [ + { + "name": "LocationID", + "dataType": "smallint", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "Name", + "dataType": "Name", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "CostRate", + "dataType": "smallmoney", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Availability", + "dataType": "decimal", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "Password", + "schema": "Person", + "columns": [ + { + "name": "BusinessEntityID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "PasswordHash", + "dataType": "varchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "PasswordSalt", + "dataType": "varchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "rowguid", + "dataType": "uniqueidentifier", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "SalesPersonQuotaHistory", + "schema": "Sales", + "columns": [ + { + "name": "BusinessEntityID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "QuotaDate", + "dataType": "datetime", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "SalesQuota", + "dataType": "money", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "rowguid", + "dataType": "uniqueidentifier", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "Person", + "schema": "Person", + "columns": [ + { + "name": "BusinessEntityID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": false + }, + { + "name": "PersonType", + "dataType": "nchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "NameStyle", + "dataType": "NameStyle", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Title", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "FirstName", + "dataType": "Name", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "MiddleName", + "dataType": "Name", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "LastName", + "dataType": "Name", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Suffix", + "dataType": "nvarchar", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "EmailPromotion", + "dataType": "int", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "AdditionalContactInfo", + "dataType": "xml", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "Demographics", + "dataType": "xml", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "rowguid", + "dataType": "uniqueidentifier", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + }, + { + "name": "SalesReason", + "schema": "Sales", + "columns": [ + { + "name": "SalesReasonID", + "dataType": "int", + "isPrimaryKey": true, + "isIdentity": true + }, + { + "name": "Name", + "dataType": "Name", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ReasonType", + "dataType": "Name", + "isPrimaryKey": false, + "isIdentity": false + }, + { + "name": "ModifiedDate", + "dataType": "datetime", + "isPrimaryKey": false, + "isIdentity": false + } + ] + } + ], + "relationships": [ + { + "foreignKeyName": "FK_Customer_SalesTerritory_TerritoryID", + "entity": "Customer", + "column": "TerritoryID", + "referencedEntity": "SalesTerritory", + "referencedColumn": "TerritoryID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_SalesOrderHeader_SalesTerritory_TerritoryID", + "entity": "SalesOrderHeader", + "column": "TerritoryID", + "referencedEntity": "SalesTerritory", + "referencedColumn": "TerritoryID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_SalesPerson_SalesTerritory_TerritoryID", + "entity": "SalesPerson", + "column": "TerritoryID", + "referencedEntity": "SalesTerritory", + "referencedColumn": "TerritoryID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_SalesTerritoryHistory_SalesTerritory_TerritoryID", + "entity": "SalesTerritoryHistory", + "column": "TerritoryID", + "referencedEntity": "SalesTerritory", + "referencedColumn": "TerritoryID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_StateProvince_SalesTerritory_TerritoryID", + "entity": "StateProvince", + "column": "TerritoryID", + "referencedEntity": "SalesTerritory", + "referencedColumn": "TerritoryID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_PersonPhone_PhoneNumberType_PhoneNumberTypeID", + "entity": "PersonPhone", + "column": "PhoneNumberTypeID", + "referencedEntity": "PhoneNumberType", + "referencedColumn": "PhoneNumberTypeID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_BillOfMaterials_Product_ProductAssemblyID", + "entity": "BillOfMaterials", + "column": "ProductAssemblyID", + "referencedEntity": "Product", + "referencedColumn": "ProductID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_BillOfMaterials_Product_ComponentID", + "entity": "BillOfMaterials", + "column": "ComponentID", + "referencedEntity": "Product", + "referencedColumn": "ProductID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_ProductCostHistory_Product_ProductID", + "entity": "ProductCostHistory", + "column": "ProductID", + "referencedEntity": "Product", + "referencedColumn": "ProductID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_ProductDocument_Product_ProductID", + "entity": "ProductDocument", + "column": "ProductID", + "referencedEntity": "Product", + "referencedColumn": "ProductID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_ProductInventory_Product_ProductID", + "entity": "ProductInventory", + "column": "ProductID", + "referencedEntity": "Product", + "referencedColumn": "ProductID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_ProductListPriceHistory_Product_ProductID", + "entity": "ProductListPriceHistory", + "column": "ProductID", + "referencedEntity": "Product", + "referencedColumn": "ProductID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_ProductProductPhoto_Product_ProductID", + "entity": "ProductProductPhoto", + "column": "ProductID", + "referencedEntity": "Product", + "referencedColumn": "ProductID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_ProductReview_Product_ProductID", + "entity": "ProductReview", + "column": "ProductID", + "referencedEntity": "Product", + "referencedColumn": "ProductID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_ProductVendor_Product_ProductID", + "entity": "ProductVendor", + "column": "ProductID", + "referencedEntity": "Product", + "referencedColumn": "ProductID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_PurchaseOrderDetail_Product_ProductID", + "entity": "PurchaseOrderDetail", + "column": "ProductID", + "referencedEntity": "Product", + "referencedColumn": "ProductID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_ShoppingCartItem_Product_ProductID", + "entity": "ShoppingCartItem", + "column": "ProductID", + "referencedEntity": "Product", + "referencedColumn": "ProductID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_SpecialOfferProduct_Product_ProductID", + "entity": "SpecialOfferProduct", + "column": "ProductID", + "referencedEntity": "Product", + "referencedColumn": "ProductID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_TransactionHistory_Product_ProductID", + "entity": "TransactionHistory", + "column": "ProductID", + "referencedEntity": "Product", + "referencedColumn": "ProductID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_WorkOrder_Product_ProductID", + "entity": "WorkOrder", + "column": "ProductID", + "referencedEntity": "Product", + "referencedColumn": "ProductID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_WorkOrder_ScrapReason_ScrapReasonID", + "entity": "WorkOrder", + "column": "ScrapReasonID", + "referencedEntity": "ScrapReason", + "referencedColumn": "ScrapReasonID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_EmployeeDepartmentHistory_Shift_ShiftID", + "entity": "EmployeeDepartmentHistory", + "column": "ShiftID", + "referencedEntity": "Shift", + "referencedColumn": "ShiftID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_ProductSubcategory_ProductCategory_ProductCategoryID", + "entity": "ProductSubcategory", + "column": "ProductCategoryID", + "referencedEntity": "ProductCategory", + "referencedColumn": "ProductCategoryID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_PurchaseOrderHeader_ShipMethod_ShipMethodID", + "entity": "PurchaseOrderHeader", + "column": "ShipMethodID", + "referencedEntity": "ShipMethod", + "referencedColumn": "ShipMethodID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_SalesOrderHeader_ShipMethod_ShipMethodID", + "entity": "SalesOrderHeader", + "column": "ShipMethodID", + "referencedEntity": "ShipMethod", + "referencedColumn": "ShipMethodID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_ProductModelProductDescriptionCulture_ProductDescription_ProductDescriptionID", + "entity": "ProductModelProductDescriptionCulture", + "column": "ProductDescriptionID", + "referencedEntity": "ProductDescription", + "referencedColumn": "ProductDescriptionID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_SpecialOfferProduct_SpecialOffer_SpecialOfferID", + "entity": "SpecialOfferProduct", + "column": "SpecialOfferID", + "referencedEntity": "SpecialOffer", + "referencedColumn": "SpecialOfferID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_BusinessEntityAddress_Address_AddressID", + "entity": "BusinessEntityAddress", + "column": "AddressID", + "referencedEntity": "Address", + "referencedColumn": "AddressID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_SalesOrderHeader_Address_BillToAddressID", + "entity": "SalesOrderHeader", + "column": "BillToAddressID", + "referencedEntity": "Address", + "referencedColumn": "AddressID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_SalesOrderHeader_Address_ShipToAddressID", + "entity": "SalesOrderHeader", + "column": "ShipToAddressID", + "referencedEntity": "Address", + "referencedColumn": "AddressID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_SalesOrderDetail_SpecialOfferProduct_SpecialOfferIDProductID", + "entity": "SalesOrderDetail", + "column": "SpecialOfferID", + "referencedEntity": "SpecialOfferProduct", + "referencedColumn": "SpecialOfferID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_SalesOrderDetail_SpecialOfferProduct_SpecialOfferIDProductID", + "entity": "SalesOrderDetail", + "column": "ProductID", + "referencedEntity": "SpecialOfferProduct", + "referencedColumn": "ProductID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_Product_ProductModel_ProductModelID", + "entity": "Product", + "column": "ProductModelID", + "referencedEntity": "ProductModel", + "referencedColumn": "ProductModelID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_ProductModelIllustration_ProductModel_ProductModelID", + "entity": "ProductModelIllustration", + "column": "ProductModelID", + "referencedEntity": "ProductModel", + "referencedColumn": "ProductModelID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_ProductModelProductDescriptionCulture_ProductModel_ProductModelID", + "entity": "ProductModelProductDescriptionCulture", + "column": "ProductModelID", + "referencedEntity": "ProductModel", + "referencedColumn": "ProductModelID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_BusinessEntityAddress_AddressType_AddressTypeID", + "entity": "BusinessEntityAddress", + "column": "AddressTypeID", + "referencedEntity": "AddressType", + "referencedColumn": "AddressTypeID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_Address_StateProvince_StateProvinceID", + "entity": "Address", + "column": "StateProvinceID", + "referencedEntity": "StateProvince", + "referencedColumn": "StateProvinceID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_SalesTaxRate_StateProvince_StateProvinceID", + "entity": "SalesTaxRate", + "column": "StateProvinceID", + "referencedEntity": "StateProvince", + "referencedColumn": "StateProvinceID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_Customer_Store_StoreID", + "entity": "Customer", + "column": "StoreID", + "referencedEntity": "Store", + "referencedColumn": "BusinessEntityID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_ProductProductPhoto_ProductPhoto_ProductPhotoID", + "entity": "ProductProductPhoto", + "column": "ProductPhotoID", + "referencedEntity": "ProductPhoto", + "referencedColumn": "ProductPhotoID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_BusinessEntityAddress_BusinessEntity_BusinessEntityID", + "entity": "BusinessEntityAddress", + "column": "BusinessEntityID", + "referencedEntity": "BusinessEntity", + "referencedColumn": "BusinessEntityID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_BusinessEntityContact_BusinessEntity_BusinessEntityID", + "entity": "BusinessEntityContact", + "column": "BusinessEntityID", + "referencedEntity": "BusinessEntity", + "referencedColumn": "BusinessEntityID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_Person_BusinessEntity_BusinessEntityID", + "entity": "Person", + "column": "BusinessEntityID", + "referencedEntity": "BusinessEntity", + "referencedColumn": "BusinessEntityID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_Store_BusinessEntity_BusinessEntityID", + "entity": "Store", + "column": "BusinessEntityID", + "referencedEntity": "BusinessEntity", + "referencedColumn": "BusinessEntityID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_Vendor_BusinessEntity_BusinessEntityID", + "entity": "Vendor", + "column": "BusinessEntityID", + "referencedEntity": "BusinessEntity", + "referencedColumn": "BusinessEntityID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_Product_ProductSubcategory_ProductSubcategoryID", + "entity": "Product", + "column": "ProductSubcategoryID", + "referencedEntity": "ProductSubcategory", + "referencedColumn": "ProductSubcategoryID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_BillOfMaterials_UnitMeasure_UnitMeasureCode", + "entity": "BillOfMaterials", + "column": "UnitMeasureCode", + "referencedEntity": "UnitMeasure", + "referencedColumn": "UnitMeasureCode", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_Product_UnitMeasure_SizeUnitMeasureCode", + "entity": "Product", + "column": "SizeUnitMeasureCode", + "referencedEntity": "UnitMeasure", + "referencedColumn": "UnitMeasureCode", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_Product_UnitMeasure_WeightUnitMeasureCode", + "entity": "Product", + "column": "WeightUnitMeasureCode", + "referencedEntity": "UnitMeasure", + "referencedColumn": "UnitMeasureCode", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_ProductVendor_UnitMeasure_UnitMeasureCode", + "entity": "ProductVendor", + "column": "UnitMeasureCode", + "referencedEntity": "UnitMeasure", + "referencedColumn": "UnitMeasureCode", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_ProductVendor_Vendor_BusinessEntityID", + "entity": "ProductVendor", + "column": "BusinessEntityID", + "referencedEntity": "Vendor", + "referencedColumn": "BusinessEntityID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_PurchaseOrderHeader_Vendor_VendorID", + "entity": "PurchaseOrderHeader", + "column": "VendorID", + "referencedEntity": "Vendor", + "referencedColumn": "BusinessEntityID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_BusinessEntityContact_ContactType_ContactTypeID", + "entity": "BusinessEntityContact", + "column": "ContactTypeID", + "referencedEntity": "ContactType", + "referencedColumn": "ContactTypeID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_CountryRegionCurrency_CountryRegion_CountryRegionCode", + "entity": "CountryRegionCurrency", + "column": "CountryRegionCode", + "referencedEntity": "CountryRegion", + "referencedColumn": "CountryRegionCode", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_SalesTerritory_CountryRegion_CountryRegionCode", + "entity": "SalesTerritory", + "column": "CountryRegionCode", + "referencedEntity": "CountryRegion", + "referencedColumn": "CountryRegionCode", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_StateProvince_CountryRegion_CountryRegionCode", + "entity": "StateProvince", + "column": "CountryRegionCode", + "referencedEntity": "CountryRegion", + "referencedColumn": "CountryRegionCode", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_WorkOrderRouting_WorkOrder_WorkOrderID", + "entity": "WorkOrderRouting", + "column": "WorkOrderID", + "referencedEntity": "WorkOrder", + "referencedColumn": "WorkOrderID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_PersonCreditCard_CreditCard_CreditCardID", + "entity": "PersonCreditCard", + "column": "CreditCardID", + "referencedEntity": "CreditCard", + "referencedColumn": "CreditCardID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_SalesOrderHeader_CreditCard_CreditCardID", + "entity": "SalesOrderHeader", + "column": "CreditCardID", + "referencedEntity": "CreditCard", + "referencedColumn": "CreditCardID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_ProductModelProductDescriptionCulture_Culture_CultureID", + "entity": "ProductModelProductDescriptionCulture", + "column": "CultureID", + "referencedEntity": "Culture", + "referencedColumn": "CultureID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_CountryRegionCurrency_Currency_CurrencyCode", + "entity": "CountryRegionCurrency", + "column": "CurrencyCode", + "referencedEntity": "Currency", + "referencedColumn": "CurrencyCode", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_CurrencyRate_Currency_FromCurrencyCode", + "entity": "CurrencyRate", + "column": "FromCurrencyCode", + "referencedEntity": "Currency", + "referencedColumn": "CurrencyCode", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_CurrencyRate_Currency_ToCurrencyCode", + "entity": "CurrencyRate", + "column": "ToCurrencyCode", + "referencedEntity": "Currency", + "referencedColumn": "CurrencyCode", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_PurchaseOrderDetail_PurchaseOrderHeader_PurchaseOrderID", + "entity": "PurchaseOrderDetail", + "column": "PurchaseOrderID", + "referencedEntity": "PurchaseOrderHeader", + "referencedColumn": "PurchaseOrderID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_SalesOrderHeader_CurrencyRate_CurrencyRateID", + "entity": "SalesOrderHeader", + "column": "CurrencyRateID", + "referencedEntity": "CurrencyRate", + "referencedColumn": "CurrencyRateID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_SalesOrderHeader_Customer_CustomerID", + "entity": "SalesOrderHeader", + "column": "CustomerID", + "referencedEntity": "Customer", + "referencedColumn": "CustomerID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_EmployeeDepartmentHistory_Department_DepartmentID", + "entity": "EmployeeDepartmentHistory", + "column": "DepartmentID", + "referencedEntity": "Department", + "referencedColumn": "DepartmentID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_ProductDocument_Document_DocumentNode", + "entity": "ProductDocument", + "column": "DocumentNode", + "referencedEntity": "Document", + "referencedColumn": "DocumentNode", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_Document_Employee_Owner", + "entity": "Document", + "column": "Owner", + "referencedEntity": "Employee", + "referencedColumn": "BusinessEntityID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_EmployeeDepartmentHistory_Employee_BusinessEntityID", + "entity": "EmployeeDepartmentHistory", + "column": "BusinessEntityID", + "referencedEntity": "Employee", + "referencedColumn": "BusinessEntityID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_EmployeePayHistory_Employee_BusinessEntityID", + "entity": "EmployeePayHistory", + "column": "BusinessEntityID", + "referencedEntity": "Employee", + "referencedColumn": "BusinessEntityID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_JobCandidate_Employee_BusinessEntityID", + "entity": "JobCandidate", + "column": "BusinessEntityID", + "referencedEntity": "Employee", + "referencedColumn": "BusinessEntityID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_PurchaseOrderHeader_Employee_EmployeeID", + "entity": "PurchaseOrderHeader", + "column": "EmployeeID", + "referencedEntity": "Employee", + "referencedColumn": "BusinessEntityID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_SalesPerson_Employee_BusinessEntityID", + "entity": "SalesPerson", + "column": "BusinessEntityID", + "referencedEntity": "Employee", + "referencedColumn": "BusinessEntityID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_SalesOrderDetail_SalesOrderHeader_SalesOrderID", + "entity": "SalesOrderDetail", + "column": "SalesOrderID", + "referencedEntity": "SalesOrderHeader", + "referencedColumn": "SalesOrderID", + "onDeleteAction": 0, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_SalesOrderHeaderSalesReason_SalesOrderHeader_SalesOrderID", + "entity": "SalesOrderHeaderSalesReason", + "column": "SalesOrderID", + "referencedEntity": "SalesOrderHeader", + "referencedColumn": "SalesOrderID", + "onDeleteAction": 0, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_SalesOrderHeader_SalesPerson_SalesPersonID", + "entity": "SalesOrderHeader", + "column": "SalesPersonID", + "referencedEntity": "SalesPerson", + "referencedColumn": "BusinessEntityID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_SalesPersonQuotaHistory_SalesPerson_BusinessEntityID", + "entity": "SalesPersonQuotaHistory", + "column": "BusinessEntityID", + "referencedEntity": "SalesPerson", + "referencedColumn": "BusinessEntityID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_SalesTerritoryHistory_SalesPerson_BusinessEntityID", + "entity": "SalesTerritoryHistory", + "column": "BusinessEntityID", + "referencedEntity": "SalesPerson", + "referencedColumn": "BusinessEntityID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_Store_SalesPerson_SalesPersonID", + "entity": "Store", + "column": "SalesPersonID", + "referencedEntity": "SalesPerson", + "referencedColumn": "BusinessEntityID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_ProductModelIllustration_Illustration_IllustrationID", + "entity": "ProductModelIllustration", + "column": "IllustrationID", + "referencedEntity": "Illustration", + "referencedColumn": "IllustrationID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_ProductInventory_Location_LocationID", + "entity": "ProductInventory", + "column": "LocationID", + "referencedEntity": "Location", + "referencedColumn": "LocationID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_WorkOrderRouting_Location_LocationID", + "entity": "WorkOrderRouting", + "column": "LocationID", + "referencedEntity": "Location", + "referencedColumn": "LocationID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_BusinessEntityContact_Person_PersonID", + "entity": "BusinessEntityContact", + "column": "PersonID", + "referencedEntity": "Person", + "referencedColumn": "BusinessEntityID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_Customer_Person_PersonID", + "entity": "Customer", + "column": "PersonID", + "referencedEntity": "Person", + "referencedColumn": "BusinessEntityID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_EmailAddress_Person_BusinessEntityID", + "entity": "EmailAddress", + "column": "BusinessEntityID", + "referencedEntity": "Person", + "referencedColumn": "BusinessEntityID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_Employee_Person_BusinessEntityID", + "entity": "Employee", + "column": "BusinessEntityID", + "referencedEntity": "Person", + "referencedColumn": "BusinessEntityID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_Password_Person_BusinessEntityID", + "entity": "Password", + "column": "BusinessEntityID", + "referencedEntity": "Person", + "referencedColumn": "BusinessEntityID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_PersonCreditCard_Person_BusinessEntityID", + "entity": "PersonCreditCard", + "column": "BusinessEntityID", + "referencedEntity": "Person", + "referencedColumn": "BusinessEntityID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_PersonPhone_Person_BusinessEntityID", + "entity": "PersonPhone", + "column": "BusinessEntityID", + "referencedEntity": "Person", + "referencedColumn": "BusinessEntityID", + "onDeleteAction": 1, + "onUpdateAction": 1 + }, + { + "foreignKeyName": "FK_SalesOrderHeaderSalesReason_SalesReason_SalesReasonID", + "entity": "SalesOrderHeaderSalesReason", + "column": "SalesReasonID", + "referencedEntity": "SalesReason", + "referencedColumn": "SalesReasonID", + "onDeleteAction": 1, + "onUpdateAction": 1 + } + ] +}; \ No newline at end of file diff --git a/ts-examples/bigSchema.html b/ts-examples/bigSchema.html index 85573b4..9912bfa 100644 --- a/ts-examples/bigSchema.html +++ b/ts-examples/bigSchema.html @@ -7,20 +7,29 @@ + + + +
+ + diff --git a/ts-examples/resources/datatype_custom.svg b/ts-examples/resources/datatype_custom.svg new file mode 100644 index 0000000..f86dccb --- /dev/null +++ b/ts-examples/resources/datatype_custom.svg @@ -0,0 +1,3 @@ + + + \ No newline at end of file diff --git a/ts-examples/resources/datatype_money.svg b/ts-examples/resources/datatype_money.svg new file mode 100644 index 0000000..3f8155c --- /dev/null +++ b/ts-examples/resources/datatype_money.svg @@ -0,0 +1,3 @@ + + + \ No newline at end of file diff --git a/ts-examples/resources/zoomFit.svg b/ts-examples/resources/zoomFit.svg new file mode 100644 index 0000000..dac8d01 --- /dev/null +++ b/ts-examples/resources/zoomFit.svg @@ -0,0 +1,3 @@ + + + \ No newline at end of file diff --git a/ts-examples/smallSchema.html b/ts-examples/smallSchema.html index 31361cd..ed0fb93 100644 --- a/ts-examples/smallSchema.html +++ b/ts-examples/smallSchema.html @@ -7,9 +7,7 @@