@ronin/compiler
Advanced tools
Comparing version 0.14.9-leo-ron-1099-1-experimental-341 to 0.14.9-leo-ron-1099-1-experimental-342
@@ -397,4 +397,2 @@ /** | ||
inlineParams?: boolean; | ||
/** Alias column names that are duplicated when joining multiple tables. */ | ||
expandColumns?: boolean; | ||
} | ||
@@ -401,0 +399,0 @@ declare class Transaction { |
{ | ||
"name": "@ronin/compiler", | ||
"version": "0.14.9-leo-ron-1099-1-experimental-341", | ||
"version": "0.14.9-leo-ron-1099-1-experimental-342", | ||
"type": "module", | ||
@@ -5,0 +5,0 @@ "description": "Compiles RONIN queries to SQL statements.", |
@@ -130,22 +130,3 @@ # RONIN Compiler | ||
// This option should only be used if the generated SQL will be manually verified. | ||
inlineParams: true, | ||
// By default, in the generated SQL statements, the compiler does not alias columns if | ||
// multiple different tables with the same column names are being joined. Only the table | ||
// names themselves are aliased. | ||
// | ||
// This ensures the cleanest possible SQL statements in conjunction with the default | ||
// behavior of SQL databases, where the result of a statement is a list (array) of | ||
// values, which are inherently not prone to conflicts. | ||
// | ||
// If the driver being used instead returns an object for every row, the driver must | ||
// ensure the uniqueness of every key in that object, which means prefixing duplicated | ||
// column names with the name of the respective table, if multiple tables are joined | ||
// (example for an object key: "table_name.column_name"). | ||
// | ||
// Drivers that return objects for rows offer this behavior as an option that is | ||
// usually called "expand columns". If the driver being used does not offer such an | ||
// option, you can instead activate the option in the compiler, which results in longer | ||
// SQL statements because all column names are aliased. | ||
expandColumns: true | ||
inlineParams: true | ||
}); | ||
@@ -152,0 +133,0 @@ ``` |
Sorry, the diff of this file is too big to display
110473
2554
167