@dataform/core
Advanced tools
Comparing version 1.3.0 to 1.3.1
/// <amd-module name="@dataform/core/adapters/base" /> | ||
import { dataform } from "@dataform/protos"; | ||
export declare abstract class Adapter { | ||
where(query: string, where: string): string; | ||
abstract resolveTarget(target: dataform.ITarget): string; | ||
normalizeIdentifier(identifier: string): string; | ||
dropIfExists(target: dataform.ITarget, type: string): string; | ||
baseTableType(type: string): string; | ||
oppositeTableType(type: string): "table" | "view"; | ||
insertInto(target: dataform.ITarget, columns: string[], query: string): string; | ||
dropIfExists(target: dataform.ITarget, type: string): string; | ||
abstract resolveTarget(target: dataform.ITarget): string; | ||
protected insertInto(target: dataform.ITarget, columns: string[], query: string): string; | ||
protected oppositeTableType(type: string): "table" | "view"; | ||
protected where(query: string, where: string): string; | ||
} |
@@ -13,8 +13,10 @@ (function (factory) { | ||
class Adapter { | ||
where(query, where) { | ||
return `select * from (${query}) as subquery | ||
where ${where}`; | ||
normalizeIdentifier(identifier) { | ||
return identifier; | ||
} | ||
dropIfExists(target, type) { | ||
return `drop ${this.baseTableType(type)} if exists ${this.resolveTarget(target)} ${this.baseTableType(type) == "table" ? "cascade" : ""}`; | ||
} | ||
baseTableType(type) { | ||
if (type == "incremental") { | ||
if (type === "incremental") { | ||
return "table"; | ||
@@ -24,5 +26,2 @@ } | ||
} | ||
oppositeTableType(type) { | ||
return this.baseTableType(type) == "table" ? "view" : "table"; | ||
} | ||
insertInto(target, columns, query) { | ||
@@ -35,8 +34,12 @@ return ` | ||
} | ||
dropIfExists(target, type) { | ||
return `drop ${this.baseTableType(type)} if exists ${this.resolveTarget(target)} ${this.baseTableType(type) == "table" ? "cascade" : ""}`; | ||
oppositeTableType(type) { | ||
return this.baseTableType(type) === "table" ? "view" : "table"; | ||
} | ||
where(query, where) { | ||
return `select * from (${query}) as subquery | ||
where ${where}`; | ||
} | ||
} | ||
exports.Adapter = Adapter; | ||
}); | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYm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1xuICAgIHJldHVybiBgc2VsZWN0ICogZnJvbSAoJHtxdWVyeX0pIGFzIHN1YnF1ZXJ5XG4gICAgICAgIHdoZXJlICR7d2hlcmV9YDtcbiAgfVxufVxuIl19 |
@@ -6,2 +6,3 @@ /// <amd-module name="@dataform/core/adapters/index" /> | ||
resolveTarget(target: dataform.ITarget): string; | ||
normalizeIdentifier(identifier: string): string; | ||
publishTasks(table: dataform.ITable, runConfig: dataform.IRunConfig, tableMetadata: dataform.ITableMetadata): Tasks; | ||
@@ -8,0 +9,0 @@ assertTasks(assertion: dataform.IAssertion, projectConfig: dataform.IProjectConfig): Tasks; |
@@ -82,2 +82,2 @@ (function (factory) { | ||
}); | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi9jb3JlL2FkYXB0ZXJzL2luZGV4LnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7Ozs7Ozs7Ozs7O0lBQUEsK0RBQW1FO0lBQ25FLCtEQUFtRTtJQUNuRSxpRUFBcUU7SUFDckUsK0VBQW1GO0lBc0JuRixJQUFZLGFBTVg7SUFORCxXQUFZLGFBQWE7UUFDdkIsc0NBQXFCLENBQUE7UUFDckIsc0NBQXFCLENBQUE7UUFDckIsc0NBQXFCLENBQUE7UUFDckIsd0NBQXVCLENBQUE7UUFDdkIsc0RBQXFDLENBQUE7SUFDdkMsQ0FBQyxFQU5XLGFBQWEsR0FBYixxQkFBYSxLQUFiLHFCQUFhLFFBTXhCO0lBRUQsTUFBTSxzQkFBc0IsR0FBRyxDQUFDLGFBQWEsQ0FBQyxRQUFRLEVBQUUsYUFBYSxDQUFDLGdCQUFnQixDQUFDLENBQUM7SUFFeEYsU0FBZ0IsY0FBYyxDQUFDLGFBQTRCO1FBQ3pELE9BQU8sc0JBQXNCLENBQUMsSUFBSSxDQUFDLENBQUMsQ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xucmVnaXN0ZXIoXCJzcWxkYXRhd2FyZWhvdXNlXCIsIFNRTERhdGFXYXJlaG91c2VBZGFwdGVyKTtcbiJdfQ== |
@@ -10,2 +10,3 @@ /// <amd-module name="@dataform/core/adapters/snowflake" /> | ||
resolveTarget(target: dataform.ITarget): string; | ||
normalizeIdentifier(identifier: string): string; | ||
publishTasks(table: dataform.ITable, runConfig: dataform.IRunConfig, tableMetadata: dataform.ITableMetadata): Tasks; | ||
@@ -12,0 +13,0 @@ assertTasks(assertion: dataform.IAssertion, projectConfig: dataform.IProjectConfig): Tasks; |
@@ -23,2 +23,5 @@ (function (factory) { | ||
} | ||
normalizeIdentifier(identifier) { | ||
return identifier.toUpperCase(); | ||
} | ||
publishTasks(table, runConfig, tableMetadata) { | ||
@@ -63,2 +66,2 @@ const tasks = tasks_1.Tasks.create(); | ||
}); | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoic25vd2ZsYWtlLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vY29yZS9hZGFwdGVycy9zbm93Zmxha2UudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7Ozs7Ozs7Ozs7SUFBQSw2Q0FBNEM7SUFDNUMsZ0RBQXVDO0lBQ3ZDLHVEQUFpQztJQUdqQyxNQUFhLGdCQUFpQixTQUFRLGNBQU87UUFHM0MsWUFBWSxPQUFnQztZQUMxQyxLQUFLLEVBQUUsQ0FBQztZQUNSLElBQUksQ0FBQyxPQUFPLEdBQUcsT0FBTyxDQUFDO1FBQ3pCLENBQUM7UUFFTSxhQUFhLENBQUMsTUFBd0I7WUFDM0MsT0FBTyxJQUFJLE1BQU0sQ0FBQyxNQUFNLE1BQU0sTUFBTSxDQUFDLElBQUksR0FBRyxDQUFDO1FBQy9DLENBQUM7UUFFTSxZQUFZLENBQ2pCLEtBQXNCLEVBQ3RCLFNBQThCLEVBQzlCLGFBQXN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RhZm9ybS5JVGFibGUpIHtcbiAgICByZXR1cm4gYGNyZWF0ZSBvciByZXBsYWNlICR7dGhpcy5iYXNlVGFibGVUeXBlKHRhYmxlLnR5cGUgfHwgXCJ0YWJsZVwiKX0gJHt0aGlzLnJlc29sdmVUYXJnZXQoXG4gICAgICB0YWJsZS50YXJnZXRcbiAgICApfSBhcyAke3RhYmxlLnF1ZXJ5fWA7XG4gIH1cbn1cbiJdfQ== |
@@ -43,2 +43,3 @@ (function (factory) { | ||
.join("\n"); | ||
const projectOverridesJsonString = JSON.stringify(protos_1.dataform.ProjectConfig.create(config.compileConfig.projectConfigOverride).toJSON()); | ||
return ` | ||
@@ -49,4 +50,7 @@ require("@dataform/core"); | ||
${includeRequires} | ||
const projectConfig = require("./dataform.json"); | ||
let projectConfig = require("./dataform.json"); | ||
// For backwards compatibility, in case core version is ahead of api. | ||
projectConfig.schemaSuffix = "${config.compileConfig.schemaSuffixOverride}" || projectConfig.schemaSuffix; | ||
// Merge in general project config overrides. | ||
projectConfig = { ...projectConfig, ...${projectOverridesJsonString} }; | ||
global.session.init("${config.compileConfig.projectDir}", projectConfig); | ||
@@ -64,2 +68,2 @@ ${definitionRequires} | ||
}); | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZ2VuX2luZGV4LmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vY29yZS9nZW5faW5kZXgudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7Ozs7Ozs7Ozs7SUFBQSw4Q0FBOEM7SUFDOUMsNkNBQTRDO0lBQzVDLDJDQUFrQztJQUVsQyxTQUFnQixRQUFRLENBQUMsbUJBQTJCO1FBQ2xELE1BQU0saUJBQWlCLEdBQUcsSUFBSSxVQUFVLENBQUMsaUJBQUksQ0FBQyxNQUFNLENBQUMsTUFBTSxDQUFDLG1CQUFtQixDQUFDLENBQUMsQ0FBQztRQUNsRixpQkF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pID8gcHJvdG9zLmRhdGFmb3JtIDogcHJvdG9zO1xuICAgIC8vIFdlIHJldHVybiBhIGJhc2U2NCBlbmNvZGVkIHByb3RvIHZpYSBOb2RlVk0sIGFzIHJldHVybmluZyBhIFVpbnQ4QXJyYXkgZGlyZWN0bHkgY2F1c2VzIGlzc3Vlcy5cbiAgICBjb25zdCBlbmNvZGVkR3JhcGhCeXRlcyA9IHByb3RvTmFtZXNwYWNlLkNvbXBpbGVkR3JhcGguZW5jb2RlKGNvbXBpbGVkR3JhcGgpLmZpbmlzaCgpO1xuICAgIGNvbnN0IGJhc2U2NEVuY29kZWRHcmFwaEJ5dGVzID0gdXRpbC5iYXNlNjQuZW5jb2RlKGVuY29kZWRHcmFwaEJ5dGVzLCAwLCBlbmNvZGVkR3JhcGhCeXRlcy5sZW5ndGgpO1xuICAgIHJldHVybiAke2NvbmZpZy5yZXR1cm5PdmVycmlkZSB8fCBcImJhc2U2NEVuY29kZWRHcmFwaEJ5dGVzXCJ9O2A7XG59XG4iXX0= |
{ | ||
"version": "1.3.0", | ||
"version": "1.3.1", | ||
"homepage": "https://github.com/dataform-co/dataform", | ||
@@ -24,3 +24,3 @@ "license": "MIT", | ||
"dependencies": { | ||
"@dataform/protos": "1.3.0", | ||
"@dataform/protos": "1.3.1", | ||
"moo": "^0.5.0", | ||
@@ -27,0 +27,0 @@ "protobufjs": "^6.8.8" |
@@ -136,9 +136,13 @@ (function (factory) { | ||
target(target, defaultSchema) { | ||
const adapter = this.adapter(); | ||
if (target.includes(".")) { | ||
const [schema, name] = target.split("."); | ||
return protos_1.dataform.Target.create({ name, schema: schema + this.getSuffixWithUnderscore() }); | ||
return protos_1.dataform.Target.create({ | ||
name: adapter.normalizeIdentifier(name), | ||
schema: adapter.normalizeIdentifier(schema + this.getSuffixWithUnderscore()) | ||
}); | ||
} | ||
return protos_1.dataform.Target.create({ | ||
name: target, | ||
schema: (defaultSchema || this.config.defaultSchema) + this.getSuffixWithUnderscore() | ||
name: adapter.normalizeIdentifier(target), | ||
schema: adapter.normalizeIdentifier((defaultSchema || this.config.defaultSchema) + this.getSuffixWithUnderscore()) | ||
}); | ||
@@ -298,7 +302,9 @@ } | ||
findActions(res) { | ||
const adapter = this.adapter(); | ||
return this.actions.filter(action => { | ||
if (typeof res === "string") { | ||
return action.proto.target.name === res; | ||
return action.proto.target.name === adapter.normalizeIdentifier(res); | ||
} | ||
return action.proto.target.schema === res.schema && action.proto.target.name === res.name; | ||
return (action.proto.target.schema === adapter.normalizeIdentifier(res.schema) && | ||
action.proto.target.name === adapter.normalizeIdentifier(res.name)); | ||
}); | ||
@@ -336,2 +342,2 @@ } | ||
}); | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoic2Vzc2lvbi5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uL2NvcmUvc2Vzc2lvbi50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7Ozs7Ozs7OztJQUFBLDBEQUFvRDtJQUNwRCx3REFBNEU7SUFDNUUsNERBQWtFO0lBQ2xFLHdEQUE0RTtJQUM1RSw4Q0FBOEM7SUFDOUMsNENBQTRDO0lBQzVDLDhDQUE4QztJQUM5Qyw2Q0FBNEM7SUErQjVDLFNBQWdCLHFCQUFxQixDQUFDLE9BQTJCO1FBQy9ELE9BQU8sS0FBSyxDQUFDLE9BQU8sQ0FDbEIsTUFBTSxDQUFDLElBQUksQ0FBQyxPQUFPLENBQUMsQ0FBQyxHQUFHLENBQUMsTUFBTSxDQUFDLEVBQUUsQ0FBQywyQkFBMkIsQ0FBQyxDQUFDLE1BQU0sQ0FBQyxFQUFFLE9BQU8sQ0FBQyxNQUFNLENBQUMsQ0FBQyxDQUFDLENBQzNGLENBQUM7SUFDSixDQUFDO0lBSkQsc0RBSUM7SUFFRCxTQUFTLDJCQUEyQixDQUNsQyxXQUFxQixFQUNyQixXQUF1QztRQUV2QyxJQUFJLE9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FzT3V0cHV0PzogYm9vbGVhbikge1xuICByZXR1cm4gZGVmaW5lc0RhdGFzZXQodHlwZSkgfHwgdHlwZSA9PT0gXCJkZWNsYXJhdGlvblwiIHx8IGhhc091dHB1dDtcbn1cblxuZnVuY3Rpb24gZGVmaW5lc0RhdGFzZXQodHlwZTogc3RyaW5nKSB7XG4gIHJldHVybiB0eXBlID09PSBcInZpZXdcIiB8fCB0eXBlID09PSBcInRhYmxlXCIgfHwgdHlwZSA9PT0gXCJpbmxpbmVcIiB8fCB0eXBlID09PSBcImluY3JlbWVudGFsXCI7XG59XG4iXX0= |
341611
2788
+ Added@dataform/protos@1.3.1(transitive)
- Removed@dataform/protos@1.3.0(transitive)
Updated@dataform/protos@1.3.1