Details | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
2504 | - | 1 | <?xml version="1.0"?> |
2 | <doc> |
||
3 | <assembly> |
||
4 | <name>System.Data.SQLite.Linq</name> |
||
5 | </assembly> |
||
6 | <members> |
||
7 | <member name="T:System.Data.SQLite.Linq.Properties.Resources"> |
||
8 | <summary> |
||
9 | A strongly-typed resource class, for looking up localized strings, etc. |
||
10 | </summary> |
||
11 | </member> |
||
12 | <member name="P:System.Data.SQLite.Linq.Properties.Resources.ResourceManager"> |
||
13 | <summary> |
||
14 | Returns the cached ResourceManager instance used by this class. |
||
15 | </summary> |
||
16 | </member> |
||
17 | <member name="P:System.Data.SQLite.Linq.Properties.Resources.Culture"> |
||
18 | <summary> |
||
19 | Overrides the current thread's CurrentUICulture property for all |
||
20 | resource lookups using this strongly typed resource class. |
||
21 | </summary> |
||
22 | </member> |
||
23 | <member name="P:System.Data.SQLite.Linq.Properties.Resources.SQL_CONSTRAINTCOLUMNS"> |
||
24 | <summary> |
||
25 | Looks up a localized string similar to CREATE TEMP VIEW SCHEMACONSTRAINTCOLUMNS AS |
||
26 | SELECT CONSTRAINT_CATALOG, NULL AS CONSTRAINT_SCHEMA, CONSTRAINT_NAME, TABLE_CATALOG, NULL AS TABLE_SCHEMA, TABLE_NAME, COLUMN_NAME |
||
27 | FROM TEMP.SCHEMAINDEXCOLUMNS |
||
28 | UNION |
||
29 | SELECT CONSTRAINT_CATALOG, NULL, CONSTRAINT_NAME, TABLE_CATALOG, NULL, TABLE_NAME, FKEY_FROM_COLUMN |
||
30 | FROM TEMP.SCHEMAFOREIGNKEYS;. |
||
31 | </summary> |
||
32 | </member> |
||
33 | <member name="P:System.Data.SQLite.Linq.Properties.Resources.SQL_CONSTRAINTS"> |
||
34 | <summary> |
||
35 | Looks up a localized string similar to CREATE TEMP VIEW SCHEMACONSTRAINTS AS |
||
36 | SELECT INDEX_CATALOG AS CONSTRAINT_CATALOG, NULL AS CONSTRAINT_SCHEMA, INDEX_NAME AS CONSTRAINT_NAME, TABLE_CATALOG, NULL AS TABLE_SCHEMA, TABLE_NAME, 'PRIMARY KEY' AS CONSTRAINT_TYPE, 0 AS IS_DEFERRABLE, 0 AS INITIALLY_DEFERRED, NULL AS CHECK_CLAUSE |
||
37 | FROM TEMP.SCHEMAINDEXES WHERE PRIMARY_KEY = 1 |
||
38 | UNION |
||
39 | SELECT INDEX_CATALOG, NULL, INDEX_NAME, TABLE_CATALOG, NULL, TABLE_NAME, 'UNIQUE', 0, 0, NULL |
||
40 | FROM TEMP.SCHEMAINDEXES WHERE PRIMARY_KEY = 0 AND [UNIQUE] = 1 |
||
41 | UNION |
||
42 | [rest of string was truncated]";. |
||
43 | </summary> |
||
44 | </member> |
||
45 | <member name="T:System.Data.SQLite.Linq.DmlSqlGenerator"> |
||
46 | <summary> |
||
47 | Class generating SQL for a DML command tree. |
||
48 | </summary> |
||
49 | </member> |
||
50 | <member name="M:System.Data.SQLite.Linq.DmlSqlGenerator.IsIntegerPrimaryKey(System.Data.Metadata.Edm.EntitySetBase,System.Data.Metadata.Edm.ReadOnlyMetadataCollection{System.Data.Metadata.Edm.EdmMember}@,System.Data.Metadata.Edm.EdmMember@)"> |
||
51 | <summary> |
||
52 | This method attempts to determine if the specified table has an integer |
||
53 | primary key (i.e. "rowid"). If so, it sets the |
||
54 | <paramref name="primaryKeyMember"/> parameter to the right |
||
55 | <see cref="T:System.Data.Metadata.Edm.EdmMember"/>; otherwise, the |
||
56 | <paramref name="primaryKeyMember"/> parameter is set to null. |
||
57 | </summary> |
||
58 | <param name="table">The table to check.</param> |
||
59 | <param name="keyMembers"> |
||
60 | The collection of key members. An attempt is always made to set this |
||
61 | parameter to a valid value. |
||
62 | </param> |
||
63 | <param name="primaryKeyMember"> |
||
64 | The <see cref="T:System.Data.Metadata.Edm.EdmMember"/> that represents the integer primary key |
||
65 | -OR- null if no such <see cref="T:System.Data.Metadata.Edm.EdmMember"/> exists. |
||
66 | </param> |
||
67 | <returns> |
||
68 | Non-zero if the specified table has an integer primary key. |
||
69 | </returns> |
||
70 | </member> |
||
71 | <member name="M:System.Data.SQLite.Linq.DmlSqlGenerator.DoAllKeyMembersHaveValues(System.Data.SQLite.Linq.DmlSqlGenerator.ExpressionTranslator,System.Data.Metadata.Edm.ReadOnlyMetadataCollection{System.Data.Metadata.Edm.EdmMember},System.Data.Metadata.Edm.EdmMember@)"> |
||
72 | <summary> |
||
73 | This method attempts to determine if all the specified key members have |
||
74 | values available. |
||
75 | </summary> |
||
76 | <param name="translator"> |
||
77 | The <see cref="T:System.Data.SQLite.Linq.DmlSqlGenerator.ExpressionTranslator"/> to use. |
||
78 | </param> |
||
79 | <param name="keyMembers"> |
||
80 | The collection of key members to check. |
||
81 | </param> |
||
82 | <param name="missingKeyMember"> |
||
83 | The first missing key member that is found. This is only set to a valid |
||
84 | value if the method is returning false. |
||
85 | </param> |
||
86 | <returns> |
||
87 | Non-zero if all key members have values; otherwise, zero. |
||
88 | </returns> |
||
89 | </member> |
||
90 | <member name="M:System.Data.SQLite.Linq.DmlSqlGenerator.GenerateReturningSql(System.Text.StringBuilder,System.Data.Common.CommandTrees.DbModificationCommandTree,System.Data.SQLite.Linq.DmlSqlGenerator.ExpressionTranslator,System.Data.Common.CommandTrees.DbExpression,System.Boolean)"> |
||
91 | <summary> |
||
92 | Generates SQL fragment returning server-generated values. |
||
93 | Requires: translator knows about member values so that we can figure out |
||
94 | how to construct the key predicate. |
||
95 | <code> |
||
96 | Sample SQL: |
||
97 | |||
98 | select IdentityValue |
||
99 | from dbo.MyTable |
||
100 | where @@ROWCOUNT > 0 and IdentityValue = scope_identity() |
||
101 | |||
102 | or |
||
103 | |||
104 | select TimestamptValue |
||
105 | from dbo.MyTable |
||
106 | where @@ROWCOUNT > 0 and Id = 1 |
||
107 | |||
108 | Note that we filter on rowcount to ensure no rows are returned if no rows were modified. |
||
109 | </code> |
||
110 | </summary> |
||
111 | <param name="commandText">Builder containing command text</param> |
||
112 | <param name="tree">Modification command tree</param> |
||
113 | <param name="translator">Translator used to produce DML SQL statement |
||
114 | for the tree</param> |
||
115 | <param name="returning">Returning expression. If null, the method returns |
||
116 | immediately without producing a SELECT statement.</param> |
||
117 | <param name="wasInsert"> |
||
118 | Non-zero if this method is being called as part of processing an INSERT; |
||
119 | otherwise (e.g. UPDATE), zero. |
||
120 | </param> |
||
121 | </member> |
||
122 | <member name="T:System.Data.SQLite.Linq.DmlSqlGenerator.ExpressionTranslator"> |
||
123 | <summary> |
||
124 | Lightweight expression translator for DML expression trees, which have constrained |
||
125 | scope and support. |
||
126 | </summary> |
||
127 | </member> |
||
128 | <member name="M:System.Data.SQLite.Linq.DmlSqlGenerator.ExpressionTranslator.#ctor(System.Text.StringBuilder,System.Data.Common.CommandTrees.DbModificationCommandTree,System.Boolean,System.String)"> |
||
129 | <summary> |
||
130 | Initialize a new expression translator populating the given string builder |
||
131 | with command text. Command text builder and command tree must not be null. |
||
132 | </summary> |
||
133 | <param name="commandText">Command text with which to populate commands</param> |
||
134 | <param name="commandTree">Command tree generating SQL</param> |
||
135 | <param name="preserveMemberValues">Indicates whether the translator should preserve |
||
136 | member values while compiling t-SQL (only needed for server generation)</param> |
||
137 | <param name="kind"></param> |
||
138 | </member> |
||
139 | <member name="M:System.Data.SQLite.Linq.DmlSqlGenerator.ExpressionTranslator.RegisterMemberValue(System.Data.Common.CommandTrees.DbExpression,System.Data.Common.CommandTrees.DbExpression)"> |
||
140 | <summary> |
||
141 | Call this method to register a property value pair so the translator "remembers" |
||
142 | the values for members of the row being modified. These values can then be used |
||
143 | to form a predicate for server-generation (based on the key of the row) |
||
144 | </summary> |
||
145 | <param name="propertyExpression">DbExpression containing the column reference (property expression).</param> |
||
146 | <param name="value">DbExpression containing the value of the column.</param> |
||
147 | </member> |
||
148 | <member name="T:System.Data.SQLite.Linq.ISqlFragment"> |
||
149 | <summary> |
||
150 | Represents the sql fragment for any node in the query tree. |
||
151 | </summary> |
||
152 | <remarks> |
||
153 | The nodes in a query tree produce various kinds of sql |
||
154 | <list type="bullet"> |
||
155 | <item>A select statement.</item> |
||
156 | <item>A reference to an extent. (symbol)</item> |
||
157 | <item>A raw string.</item> |
||
158 | </list> |
||
159 | We have this interface to allow for a common return type for the methods |
||
160 | in the expression visitor <see cref="T:System.Data.Common.CommandTrees.DbExpressionVisitor`1"/> |
||
161 | |||
162 | At the end of translation, the sql fragments are converted into real strings. |
||
163 | </remarks> |
||
164 | </member> |
||
165 | <member name="M:System.Data.SQLite.Linq.ISqlFragment.WriteSql(System.Data.SQLite.Linq.SqlWriter,System.Data.SQLite.Linq.SqlGenerator)"> |
||
166 | <summary> |
||
167 | Write the string represented by this fragment into the stream. |
||
168 | </summary> |
||
169 | <param name="writer">The stream that collects the strings.</param> |
||
170 | <param name="sqlGenerator">Context information used for renaming. |
||
171 | The global lists are used to generated new names without collisions.</param> |
||
172 | </member> |
||
173 | <member name="T:System.Data.SQLite.Linq.JoinSymbol"> |
||
174 | <summary> |
||
175 | A Join symbol is a special kind of Symbol. |
||
176 | It has to carry additional information |
||
177 | <list type="bullet"> |
||
178 | <item>ColumnList for the list of columns in the select clause if this |
||
179 | symbol represents a sql select statement. This is set by <see cref="M:System.Data.SQLite.Linq.SqlGenerator.AddDefaultColumns(System.Data.SQLite.Linq.SqlSelectStatement)"/>. </item> |
||
180 | <item>ExtentList is the list of extents in the select clause.</item> |
||
181 | <item>FlattenedExtentList - if the Join has multiple extents flattened at the |
||
182 | top level, we need this information to ensure that extent aliases are renamed |
||
183 | correctly in <see cref="M:System.Data.SQLite.Linq.SqlSelectStatement.WriteSql(System.Data.SQLite.Linq.SqlWriter,System.Data.SQLite.Linq.SqlGenerator)"/></item> |
||
184 | <item>NameToExtent has all the extents in ExtentList as a dictionary. |
||
185 | This is used by <see cref="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbPropertyExpression)"/> to flatten |
||
186 | record accesses.</item> |
||
187 | <item>IsNestedJoin - is used to determine whether a JoinSymbol is an |
||
188 | ordinary join symbol, or one that has a corresponding SqlSelectStatement.</item> |
||
189 | </list> |
||
190 | |||
191 | All the lists are set exactly once, and then used for lookups/enumerated. |
||
192 | </summary> |
||
193 | </member> |
||
194 | <member name="T:System.Data.SQLite.Linq.Symbol"> |
||
195 | <summary> |
||
196 | <see cref="T:System.Data.SQLite.Linq.SymbolTable"/> |
||
197 | This class represents an extent/nested select statement, |
||
198 | or a column. |
||
199 | |||
200 | The important fields are Name, Type and NewName. |
||
201 | NewName starts off the same as Name, and is then modified as necessary. |
||
202 | |||
203 | |||
204 | The rest are used by special symbols. |
||
205 | e.g. NeedsRenaming is used by columns to indicate that a new name must |
||
206 | be picked for the column in the second phase of translation. |
||
207 | |||
208 | IsUnnest is used by symbols for a collection expression used as a from clause. |
||
209 | This allows <see cref="M:System.Data.SQLite.Linq.SqlGenerator.AddFromSymbol(System.Data.SQLite.Linq.SqlSelectStatement,System.String,System.Data.SQLite.Linq.Symbol,System.Boolean)"/> to add the column list |
||
210 | after the alias. |
||
211 | |||
212 | </summary> |
||
213 | </member> |
||
214 | <member name="M:System.Data.SQLite.Linq.Symbol.WriteSql(System.Data.SQLite.Linq.SqlWriter,System.Data.SQLite.Linq.SqlGenerator)"> |
||
215 | <summary> |
||
216 | Write this symbol out as a string for sql. This is just |
||
217 | the new name of the symbol (which could be the same as the old name). |
||
218 | |||
219 | We rename columns here if necessary. |
||
220 | </summary> |
||
221 | <param name="writer"></param> |
||
222 | <param name="sqlGenerator"></param> |
||
223 | </member> |
||
224 | <member name="T:System.Data.SQLite.Linq.MetadataHelpers"> |
||
225 | <summary> |
||
226 | A set of static helpers for type metadata |
||
227 | </summary> |
||
228 | </member> |
||
229 | <member name="F:System.Data.SQLite.Linq.MetadataHelpers.NullableFacetName"> |
||
230 | <summary> |
||
231 | Name of the Nullable Facet |
||
232 | </summary> |
||
233 | </member> |
||
234 | <member name="M:System.Data.SQLite.Linq.MetadataHelpers.GetEdmType``1(System.Data.Metadata.Edm.TypeUsage)"> |
||
235 | <summary> |
||
236 | Cast the EdmType of the given type usage to the given TEdmType |
||
237 | </summary> |
||
238 | <typeparam name="TEdmType"></typeparam> |
||
239 | <param name="typeUsage"></param> |
||
240 | <returns></returns> |
||
241 | </member> |
||
242 | <member name="M:System.Data.SQLite.Linq.MetadataHelpers.GetElementTypeUsage(System.Data.Metadata.Edm.TypeUsage)"> |
||
243 | <summary> |
||
244 | Gets the TypeUsage of the elment if the given type is a collection type |
||
245 | </summary> |
||
246 | <param name="type"></param> |
||
247 | <returns></returns> |
||
248 | </member> |
||
249 | <member name="M:System.Data.SQLite.Linq.MetadataHelpers.GetProperties(System.Data.Metadata.Edm.TypeUsage)"> |
||
250 | <summary> |
||
251 | Retrieves the properties of in the EdmType underlying the input type usage, |
||
252 | if that EdmType is a structured type (EntityType, RowType). |
||
253 | </summary> |
||
254 | <param name="typeUsage"></param> |
||
255 | <returns></returns> |
||
256 | </member> |
||
257 | <member name="M:System.Data.SQLite.Linq.MetadataHelpers.GetProperties(System.Data.Metadata.Edm.EdmType)"> |
||
258 | <summary> |
||
259 | Retrieves the properties of the given EdmType, if it is |
||
260 | a structured type (EntityType, RowType). |
||
261 | </summary> |
||
262 | <param name="edmType"></param> |
||
263 | <returns></returns> |
||
264 | </member> |
||
265 | <member name="M:System.Data.SQLite.Linq.MetadataHelpers.IsCollectionType(System.Data.Metadata.Edm.TypeUsage)"> |
||
266 | <summary> |
||
267 | Is the given type usage over a collection type |
||
268 | </summary> |
||
269 | <param name="typeUsage"></param> |
||
270 | <returns></returns> |
||
271 | </member> |
||
272 | <member name="M:System.Data.SQLite.Linq.MetadataHelpers.IsCollectionType(System.Data.Metadata.Edm.EdmType)"> |
||
273 | <summary> |
||
274 | Is the given type a collection type |
||
275 | </summary> |
||
276 | <param name="type"></param> |
||
277 | <returns></returns> |
||
278 | </member> |
||
279 | <member name="M:System.Data.SQLite.Linq.MetadataHelpers.IsPrimitiveType(System.Data.Metadata.Edm.TypeUsage)"> |
||
280 | <summary> |
||
281 | Is the given type usage over a primitive type |
||
282 | </summary> |
||
283 | <param name="type"></param> |
||
284 | <returns></returns> |
||
285 | </member> |
||
286 | <member name="M:System.Data.SQLite.Linq.MetadataHelpers.IsPrimitiveType(System.Data.Metadata.Edm.EdmType)"> |
||
287 | <summary> |
||
288 | Is the given type a primitive type |
||
289 | </summary> |
||
290 | <param name="type"></param> |
||
291 | <returns></returns> |
||
292 | </member> |
||
293 | <member name="M:System.Data.SQLite.Linq.MetadataHelpers.IsRowType(System.Data.Metadata.Edm.TypeUsage)"> |
||
294 | <summary> |
||
295 | Is the given type usage over a row type |
||
296 | </summary> |
||
297 | <param name="type"></param> |
||
298 | <returns></returns> |
||
299 | </member> |
||
300 | <member name="M:System.Data.SQLite.Linq.MetadataHelpers.IsRowType(System.Data.Metadata.Edm.EdmType)"> |
||
301 | <summary> |
||
302 | Is the given type a row type |
||
303 | </summary> |
||
304 | <param name="type"></param> |
||
305 | <returns></returns> |
||
306 | </member> |
||
307 | <member name="M:System.Data.SQLite.Linq.MetadataHelpers.TryGetPrimitiveTypeKind(System.Data.Metadata.Edm.TypeUsage,System.Data.Metadata.Edm.PrimitiveTypeKind@)"> |
||
308 | <summary> |
||
309 | Gets the type of the given type usage if it is a primitive type |
||
310 | </summary> |
||
311 | <param name="type"></param> |
||
312 | <param name="typeKind"></param> |
||
313 | <returns></returns> |
||
314 | </member> |
||
315 | <member name="M:System.Data.SQLite.Linq.MetadataHelpers.TryGetValueForMetadataProperty``1(System.Data.Metadata.Edm.MetadataItem,System.String)"> |
||
316 | <summary> |
||
317 | Gets the value for the metadata property with the given name |
||
318 | </summary> |
||
319 | <typeparam name="T"></typeparam> |
||
320 | <param name="item"></param> |
||
321 | <param name="propertyName"></param> |
||
322 | <returns></returns> |
||
323 | </member> |
||
324 | <member name="F:System.Data.SQLite.Linq.MetadataHelpers.MaxLengthFacetName"> |
||
325 | <summary> |
||
326 | Name of the MaxLength Facet |
||
327 | </summary> |
||
328 | </member> |
||
329 | <member name="F:System.Data.SQLite.Linq.MetadataHelpers.UnicodeFacetName"> |
||
330 | <summary> |
||
331 | Name of the Unicode Facet |
||
332 | </summary> |
||
333 | </member> |
||
334 | <member name="F:System.Data.SQLite.Linq.MetadataHelpers.FixedLengthFacetName"> |
||
335 | <summary> |
||
336 | Name of the FixedLength Facet |
||
337 | </summary> |
||
338 | </member> |
||
339 | <member name="F:System.Data.SQLite.Linq.MetadataHelpers.PreserveSecondsFacetName"> |
||
340 | <summary> |
||
341 | Name of the PreserveSeconds Facet |
||
342 | </summary> |
||
343 | </member> |
||
344 | <member name="F:System.Data.SQLite.Linq.MetadataHelpers.PrecisionFacetName"> |
||
345 | <summary> |
||
346 | Name of the Precision Facet |
||
347 | </summary> |
||
348 | </member> |
||
349 | <member name="F:System.Data.SQLite.Linq.MetadataHelpers.ScaleFacetName"> |
||
350 | <summary> |
||
351 | Name of the Scale Facet |
||
352 | </summary> |
||
353 | </member> |
||
354 | <member name="F:System.Data.SQLite.Linq.MetadataHelpers.DefaultValueFacetName"> |
||
355 | <summary> |
||
356 | Name of the DefaultValue Facet |
||
357 | </summary> |
||
358 | </member> |
||
359 | <member name="M:System.Data.SQLite.Linq.MetadataHelpers.GetFacetValueOrDefault``1(System.Data.Metadata.Edm.TypeUsage,System.String,``0)"> |
||
360 | <summary> |
||
361 | Get the value specified on the given type usage for the given facet name. |
||
362 | If the faces does not have a value specifid or that value is null returns |
||
363 | the default value for that facet. |
||
364 | </summary> |
||
365 | <typeparam name="T"></typeparam> |
||
366 | <param name="type"></param> |
||
367 | <param name="facetName"></param> |
||
368 | <param name="defaultValue"></param> |
||
369 | <returns></returns> |
||
370 | </member> |
||
371 | <member name="M:System.Data.SQLite.Linq.MetadataHelpers.TryGetTypeFacetDescriptionByName(System.Data.Metadata.Edm.EdmType,System.String,System.Data.Metadata.Edm.FacetDescription@)"> |
||
372 | <summary> |
||
373 | Given a facet name and an EdmType, tries to get that facet's description. |
||
374 | </summary> |
||
375 | <param name="edmType"></param> |
||
376 | <param name="facetName"></param> |
||
377 | <param name="facetDescription"></param> |
||
378 | <returns></returns> |
||
379 | </member> |
||
380 | <member name="T:System.Data.SQLite.Linq.SkipClause"> |
||
381 | <summary> |
||
382 | SkipClause represents the a SKIP expression in a SqlSelectStatement. |
||
383 | It has a count property, which indicates how many rows should be skipped. |
||
384 | </summary> |
||
385 | </member> |
||
386 | <member name="M:System.Data.SQLite.Linq.SkipClause.#ctor(System.Data.SQLite.Linq.ISqlFragment)"> |
||
387 | <summary> |
||
388 | Creates a SkipClause with the given skipCount. |
||
389 | </summary> |
||
390 | <param name="skipCount"></param> |
||
391 | </member> |
||
392 | <member name="M:System.Data.SQLite.Linq.SkipClause.#ctor(System.Int32)"> |
||
393 | <summary> |
||
394 | Creates a SkipClause with the given skipCount. |
||
395 | </summary> |
||
396 | <param name="skipCount"></param> |
||
397 | </member> |
||
398 | <member name="M:System.Data.SQLite.Linq.SkipClause.WriteSql(System.Data.SQLite.Linq.SqlWriter,System.Data.SQLite.Linq.SqlGenerator)"> |
||
399 | <summary> |
||
400 | Write out the SKIP part of sql select statement |
||
401 | It basically writes OFFSET (X). |
||
402 | </summary> |
||
403 | <param name="writer"></param> |
||
404 | <param name="sqlGenerator"></param> |
||
405 | </member> |
||
406 | <member name="P:System.Data.SQLite.Linq.SkipClause.SkipCount"> |
||
407 | <summary> |
||
408 | How many rows should be skipped. |
||
409 | </summary> |
||
410 | </member> |
||
411 | <member name="T:System.Data.SQLite.Linq.SqlBuilder"> |
||
412 | <summary> |
||
413 | This class is like StringBuilder. While traversing the tree for the first time, |
||
414 | we do not know all the strings that need to be appended e.g. things that need to be |
||
415 | renamed, nested select statements etc. So, we use a builder that can collect |
||
416 | all kinds of sql fragments. |
||
417 | </summary> |
||
418 | </member> |
||
419 | <member name="M:System.Data.SQLite.Linq.SqlBuilder.Append(System.Object)"> |
||
420 | <summary> |
||
421 | Add an object to the list - we do not verify that it is a proper sql fragment |
||
422 | since this is an internal method. |
||
423 | </summary> |
||
424 | <param name="s"></param> |
||
425 | </member> |
||
426 | <member name="M:System.Data.SQLite.Linq.SqlBuilder.AppendLine"> |
||
427 | <summary> |
||
428 | This is to pretty print the SQL. The writer <see cref="M:System.Data.SQLite.Linq.SqlWriter.Write(System.String)"/> |
||
429 | needs to know about new lines so that it can add the right amount of |
||
430 | indentation at the beginning of lines. |
||
431 | </summary> |
||
432 | </member> |
||
433 | <member name="M:System.Data.SQLite.Linq.SqlBuilder.WriteSql(System.Data.SQLite.Linq.SqlWriter,System.Data.SQLite.Linq.SqlGenerator)"> |
||
434 | <summary> |
||
435 | We delegate the writing of the fragment to the appropriate type. |
||
436 | </summary> |
||
437 | <param name="writer"></param> |
||
438 | <param name="sqlGenerator"></param> |
||
439 | </member> |
||
440 | <member name="P:System.Data.SQLite.Linq.SqlBuilder.IsEmpty"> |
||
441 | <summary> |
||
442 | Whether the builder is empty. This is used by the <see cref="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbProjectExpression)"/> |
||
443 | to determine whether a sql statement can be reused. |
||
444 | </summary> |
||
445 | </member> |
||
446 | <member name="T:System.Data.SQLite.Linq.SqlGenerator"> |
||
447 | <summary> |
||
448 | Translates the command object into a SQL string that can be executed on |
||
449 | SQLite. |
||
450 | </summary> |
||
451 | <remarks> |
||
452 | The translation is implemented as a visitor <see cref="T:System.Data.Common.CommandTrees.DbExpressionVisitor`1"/> |
||
453 | over the query tree. It makes a single pass over the tree, collecting the sql |
||
454 | fragments for the various nodes in the tree <see cref="T:System.Data.SQLite.Linq.ISqlFragment"/>. |
||
455 | |||
456 | The major operations are |
||
457 | <list type="bullet"> |
||
458 | <item>Select statement minimization. Multiple nodes in the query tree |
||
459 | that can be part of a single SQL select statement are merged. e.g. a |
||
460 | Filter node that is the input of a Project node can typically share the |
||
461 | same SQL statement.</item> |
||
462 | <item>Alpha-renaming. As a result of the statement minimization above, there |
||
463 | could be name collisions when using correlated subqueries |
||
464 | <example> |
||
465 | <code> |
||
466 | Filter( |
||
467 | b = Project( c.x |
||
468 | c = Extent(foo) |
||
469 | ) |
||
470 | exists ( |
||
471 | Filter( |
||
472 | c = Extent(foo) |
||
473 | b.x = c.x |
||
474 | ) |
||
475 | ) |
||
476 | ) |
||
477 | </code> |
||
478 | The first Filter, Project and Extent will share the same SQL select statement. |
||
479 | The alias for the Project i.e. b, will be replaced with c. |
||
480 | If the alias c for the Filter within the exists clause is not renamed, |
||
481 | we will get <c>c.x = c.x</c>, which is incorrect. |
||
482 | Instead, the alias c within the second filter should be renamed to c1, to give |
||
483 | <c>c.x = c1.x</c> i.e. b is renamed to c, and c is renamed to c1. |
||
484 | </example> |
||
485 | </item> |
||
486 | <item>Join flattening. In the query tree, a list of join nodes is typically |
||
487 | represented as a tree of Join nodes, each with 2 children. e.g. |
||
488 | <example> |
||
489 | <code> |
||
490 | a = Join(InnerJoin |
||
491 | b = Join(CrossJoin |
||
492 | c = Extent(foo) |
||
493 | d = Extent(foo) |
||
494 | ) |
||
495 | e = Extent(foo) |
||
496 | on b.c.x = e.x |
||
497 | ) |
||
498 | </code> |
||
499 | If translated directly, this will be translated to |
||
500 | <code> |
||
501 | FROM ( SELECT c.*, d.* |
||
502 | FROM foo as c |
||
503 | CROSS JOIN foo as d) as b |
||
504 | INNER JOIN foo as e on b.x' = e.x |
||
505 | </code> |
||
506 | It would be better to translate this as |
||
507 | <code> |
||
508 | FROM foo as c |
||
509 | CROSS JOIN foo as d |
||
510 | INNER JOIN foo as e on c.x = e.x |
||
511 | </code> |
||
512 | This allows the optimizer to choose an appropriate join ordering for evaluation. |
||
513 | </example> |
||
514 | </item> |
||
515 | <item>Select * and column renaming. In the example above, we noticed that |
||
516 | in some cases we add <c>SELECT * FROM ...</c> to complete the SQL |
||
517 | statement. i.e. there is no explicit PROJECT list. |
||
518 | In this case, we enumerate all the columns available in the FROM clause |
||
519 | This is particularly problematic in the case of Join trees, since the columns |
||
520 | from the extents joined might have the same name - this is illegal. To solve |
||
521 | this problem, we will have to rename columns if they are part of a SELECT * |
||
522 | for a JOIN node - we do not need renaming in any other situation. |
||
523 | <see cref="M:System.Data.SQLite.Linq.SqlGenerator.AddDefaultColumns(System.Data.SQLite.Linq.SqlSelectStatement)"/>. |
||
524 | </item> |
||
525 | </list> |
||
526 | |||
527 | <para> |
||
528 | Renaming issues. |
||
529 | When rows or columns are renamed, we produce names that are unique globally |
||
530 | with respect to the query. The names are derived from the original names, |
||
531 | with an integer as a suffix. e.g. CustomerId will be renamed to CustomerId1, |
||
532 | CustomerId2 etc. |
||
533 | |||
534 | Since the names generated are globally unique, they will not conflict when the |
||
535 | columns of a JOIN SELECT statement are joined with another JOIN. |
||
536 | |||
537 | </para> |
||
538 | |||
539 | <para> |
||
540 | Record flattening. |
||
541 | SQL server does not have the concept of records. However, a join statement |
||
542 | produces records. We have to flatten the record accesses into a simple |
||
543 | <c>alias.column</c> form. <see cref="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbPropertyExpression)"/> |
||
544 | </para> |
||
545 | |||
546 | <para> |
||
547 | Building the SQL. |
||
548 | There are 2 phases |
||
549 | <list type="numbered"> |
||
550 | <item>Traverse the tree, producing a sql builder <see cref="T:System.Data.SQLite.Linq.SqlBuilder"/></item> |
||
551 | <item>Write the SqlBuilder into a string, renaming the aliases and columns |
||
552 | as needed.</item> |
||
553 | </list> |
||
554 | |||
555 | In the first phase, we traverse the tree. We cannot generate the SQL string |
||
556 | right away, since |
||
557 | <list type="bullet"> |
||
558 | <item>The WHERE clause has to be visited before the from clause.</item> |
||
559 | <item>extent aliases and column aliases need to be renamed. To minimize |
||
560 | renaming collisions, all the names used must be known, before any renaming |
||
561 | choice is made.</item> |
||
562 | </list> |
||
563 | To defer the renaming choices, we use symbols <see cref="T:System.Data.SQLite.Linq.Symbol"/>. These |
||
564 | are renamed in the second phase. |
||
565 | |||
566 | Since visitor methods cannot transfer information to child nodes through |
||
567 | parameters, we use some global stacks, |
||
568 | <list type="bullet"> |
||
569 | <item>A stack for the current SQL select statement. This is needed by |
||
570 | <see cref="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbVariableReferenceExpression)"/> to create a |
||
571 | list of free variables used by a select statement. This is needed for |
||
572 | alias renaming. |
||
573 | </item> |
||
574 | <item>A stack for the join context. When visiting a <see cref="T:System.Data.Common.CommandTrees.DbScanExpression"/>, |
||
575 | we need to know whether we are inside a join or not. If we are inside |
||
576 | a join, we do not create a new SELECT statement.</item> |
||
577 | </list> |
||
578 | </para> |
||
579 | |||
580 | <para> |
||
581 | Global state. |
||
582 | To enable renaming, we maintain |
||
583 | <list type="bullet"> |
||
584 | <item>The set of all extent aliases used.</item> |
||
585 | <item>The set of all column aliases used.</item> |
||
586 | </list> |
||
587 | |||
588 | Finally, we have a symbol table to lookup variable references. All references |
||
589 | to the same extent have the same symbol. |
||
590 | </para> |
||
591 | |||
592 | <para> |
||
593 | Sql select statement sharing. |
||
594 | |||
595 | Each of the relational operator nodes |
||
596 | <list type="bullet"> |
||
597 | <item>Project</item> |
||
598 | <item>Filter</item> |
||
599 | <item>GroupBy</item> |
||
600 | <item>Sort/OrderBy</item> |
||
601 | </list> |
||
602 | can add its non-input (e.g. project, predicate, sort order etc.) to |
||
603 | the SQL statement for the input, or create a new SQL statement. |
||
604 | If it chooses to reuse the input's SQL statement, we play the following |
||
605 | symbol table trick to accomplish renaming. The symbol table entry for |
||
606 | the alias of the current node points to the symbol for the input in |
||
607 | the input's SQL statement. |
||
608 | <example> |
||
609 | <code> |
||
610 | Project(b.x |
||
611 | b = Filter( |
||
612 | c = Extent(foo) |
||
613 | c.x = 5) |
||
614 | ) |
||
615 | </code> |
||
616 | The Extent node creates a new SqlSelectStatement. This is added to the |
||
617 | symbol table by the Filter as {c, Symbol(c)}. Thus, <c>c.x</c> is resolved to |
||
618 | <c>Symbol(c).x</c>. |
||
619 | Looking at the project node, we add {b, Symbol(c)} to the symbol table if the |
||
620 | SQL statement is reused, and {b, Symbol(b)}, if there is no reuse. |
||
621 | |||
622 | Thus, <c>b.x</c> is resolved to <c>Symbol(c).x</c> if there is reuse, and to |
||
623 | <c>Symbol(b).x</c> if there is no reuse. |
||
624 | </example> |
||
625 | </para> |
||
626 | </remarks> |
||
627 | </member> |
||
628 | <member name="F:System.Data.SQLite.Linq.SqlGenerator.selectStatementStack"> |
||
629 | <summary> |
||
630 | Every relational node has to pass its SELECT statement to its children |
||
631 | This allows them (DbVariableReferenceExpression eventually) to update the list of |
||
632 | outer extents (free variables) used by this select statement. |
||
633 | </summary> |
||
634 | </member> |
||
635 | <member name="F:System.Data.SQLite.Linq.SqlGenerator.isParentAJoinStack"> |
||
636 | <summary> |
||
637 | Nested joins and extents need to know whether they should create |
||
638 | a new Select statement, or reuse the parent's. This flag |
||
639 | indicates whether the parent is a join or not. |
||
640 | </summary> |
||
641 | </member> |
||
642 | <member name="F:System.Data.SQLite.Linq.SqlGenerator.isVarRefSingle"> |
||
643 | <summary> |
||
644 | VariableReferenceExpressions are allowed only as children of DbPropertyExpression |
||
645 | or MethodExpression. The cheapest way to ensure this is to set the following |
||
646 | property in DbVariableReferenceExpression and reset it in the allowed parent expressions. |
||
647 | </summary> |
||
648 | </member> |
||
649 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.InitializeBuiltInFunctionHandlers"> |
||
650 | <summary> |
||
651 | All special built-in functions and their handlers |
||
652 | </summary> |
||
653 | <returns></returns> |
||
654 | </member> |
||
655 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.InitializeCanonicalFunctionHandlers"> |
||
656 | <summary> |
||
657 | All special non-aggregate canonical functions and their handlers |
||
658 | </summary> |
||
659 | <returns></returns> |
||
660 | </member> |
||
661 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.InitializeDatepartKeywords"> |
||
662 | <summary> |
||
663 | Valid datepart values |
||
664 | </summary> |
||
665 | <returns></returns> |
||
666 | </member> |
||
667 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.InitializeFunctionNameToOperatorDictionary"> |
||
668 | <summary> |
||
669 | Initializes the mapping from functions to T-SQL operators |
||
670 | for all functions that translate to T-SQL operators |
||
671 | </summary> |
||
672 | <returns></returns> |
||
673 | </member> |
||
674 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.#ctor(System.Data.SQLite.Linq.SQLiteProviderManifest)"> |
||
675 | <summary> |
||
676 | Basic constructor. |
||
677 | </summary> |
||
678 | </member> |
||
679 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.GenerateSql(System.Data.SQLite.Linq.SQLiteProviderManifest,System.Data.Common.CommandTrees.DbCommandTree,System.Collections.Generic.List{System.Data.Common.DbParameter}@,System.Data.CommandType@)"> |
||
680 | <summary> |
||
681 | General purpose static function that can be called from System.Data assembly |
||
682 | </summary> |
||
683 | <param name="manifest"></param> |
||
684 | <param name="tree">command tree</param> |
||
685 | <param name="parameters">Parameters to add to the command tree corresponding |
||
686 | to constants in the command tree. Used only in ModificationCommandTrees.</param> |
||
687 | <param name="commandType"></param> |
||
688 | <returns>The string representing the SQL to be executed.</returns> |
||
689 | </member> |
||
690 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.GenerateSql(System.Data.Common.CommandTrees.DbQueryCommandTree)"> |
||
691 | <summary> |
||
692 | Translate a command tree to a SQL string. |
||
693 | |||
694 | The input tree could be translated to either a SQL SELECT statement |
||
695 | or a SELECT expression. This choice is made based on the return type |
||
696 | of the expression |
||
697 | CollectionType => select statement |
||
698 | non collection type => select expression |
||
699 | </summary> |
||
700 | <param name="tree"></param> |
||
701 | <returns>The string representing the SQL to be executed.</returns> |
||
702 | </member> |
||
703 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.GenerateFunctionSql(System.Data.Common.CommandTrees.DbFunctionCommandTree,System.Data.CommandType@)"> |
||
704 | <summary> |
||
705 | Translate a function command tree to a SQL string. |
||
706 | </summary> |
||
707 | </member> |
||
708 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.WriteSql(System.Data.SQLite.Linq.ISqlFragment)"> |
||
709 | <summary> |
||
710 | Convert the SQL fragments to a string. |
||
711 | We have to setup the Stream for writing. |
||
712 | </summary> |
||
713 | <param name="sqlStatement"></param> |
||
714 | <returns>A string representing the SQL to be executed.</returns> |
||
715 | </member> |
||
716 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbAndExpression)"> |
||
717 | <summary> |
||
718 | Translate(left) AND Translate(right) |
||
719 | </summary> |
||
720 | <param name="e"></param> |
||
721 | <returns>A <see cref="T:System.Data.SQLite.Linq.SqlBuilder"/>.</returns> |
||
722 | </member> |
||
723 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbApplyExpression)"> |
||
724 | <summary> |
||
725 | An apply is just like a join, so it shares the common join processing |
||
726 | in <see cref="M:System.Data.SQLite.Linq.SqlGenerator.VisitJoinExpression(System.Collections.Generic.IList{System.Data.Common.CommandTrees.DbExpressionBinding},System.Data.Common.CommandTrees.DbExpressionKind,System.String,System.Data.Common.CommandTrees.DbExpression)"/> |
||
727 | </summary> |
||
728 | <param name="e"></param> |
||
729 | <returns>A <see cref="T:System.Data.SQLite.Linq.SqlSelectStatement"/>.</returns> |
||
730 | </member> |
||
731 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbArithmeticExpression)"> |
||
732 | <summary> |
||
733 | For binary expressions, we delegate to <see cref="M:System.Data.SQLite.Linq.SqlGenerator.VisitBinaryExpression(System.String,System.Data.Common.CommandTrees.DbExpression,System.Data.Common.CommandTrees.DbExpression)"/>. |
||
734 | We handle the other expressions directly. |
||
735 | </summary> |
||
736 | <param name="e"></param> |
||
737 | <returns>A <see cref="T:System.Data.SQLite.Linq.SqlBuilder"/></returns> |
||
738 | </member> |
||
739 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbCaseExpression)"> |
||
740 | <summary> |
||
741 | If the ELSE clause is null, we do not write it out. |
||
742 | </summary> |
||
743 | <param name="e"></param> |
||
744 | <returns>A <see cref="T:System.Data.SQLite.Linq.SqlBuilder"/></returns> |
||
745 | </member> |
||
746 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbCastExpression)"> |
||
747 | <summary> |
||
748 | |||
749 | </summary> |
||
750 | <param name="e"></param> |
||
751 | <returns></returns> |
||
752 | </member> |
||
753 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbComparisonExpression)"> |
||
754 | <summary> |
||
755 | The parser generates Not(Equals(...)) for <>. |
||
756 | </summary> |
||
757 | <param name="e"></param> |
||
758 | <returns>A <see cref="T:System.Data.SQLite.Linq.SqlBuilder"/>.</returns> |
||
759 | </member> |
||
760 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbConstantExpression)"> |
||
761 | <summary> |
||
762 | Constants will be send to the store as part of the generated TSQL, not as parameters |
||
763 | </summary> |
||
764 | <param name="e"></param> |
||
765 | <returns>A <see cref="T:System.Data.SQLite.Linq.SqlBuilder"/>. Strings are wrapped in single |
||
766 | quotes and escaped. Numbers are written literally.</returns> |
||
767 | </member> |
||
768 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbDerefExpression)"> |
||
769 | <summary> |
||
770 | <see cref="T:System.Data.Common.CommandTrees.DbDerefExpression"/> is illegal at this stage |
||
771 | </summary> |
||
772 | <param name="e"></param> |
||
773 | <returns></returns> |
||
774 | </member> |
||
775 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbDistinctExpression)"> |
||
776 | <summary> |
||
777 | The DISTINCT has to be added to the beginning of SqlSelectStatement.Select, |
||
778 | but it might be too late for that. So, we use a flag on SqlSelectStatement |
||
779 | instead, and add the "DISTINCT" in the second phase. |
||
780 | </summary> |
||
781 | <param name="e"></param> |
||
782 | <returns>A <see cref="T:System.Data.SQLite.Linq.SqlSelectStatement"/></returns> |
||
783 | </member> |
||
784 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbElementExpression)"> |
||
785 | <summary> |
||
786 | An element expression returns a scalar - so it is translated to |
||
787 | ( Select ... ) |
||
788 | </summary> |
||
789 | <param name="e"></param> |
||
790 | <returns></returns> |
||
791 | </member> |
||
792 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbExceptExpression)"> |
||
793 | <summary> |
||
794 | <see cref="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbUnionAllExpression)"/> |
||
795 | </summary> |
||
796 | <param name="e"></param> |
||
797 | <returns></returns> |
||
798 | </member> |
||
799 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbExpression)"> |
||
800 | <summary> |
||
801 | Only concrete expression types will be visited. |
||
802 | </summary> |
||
803 | <param name="e"></param> |
||
804 | <returns></returns> |
||
805 | </member> |
||
806 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbScanExpression)"> |
||
807 | <summary> |
||
808 | |||
809 | </summary> |
||
810 | <param name="e"></param> |
||
811 | <returns>If we are in a Join context, returns a <see cref="T:System.Data.SQLite.Linq.SqlBuilder"/> |
||
812 | with the extent name, otherwise, a new <see cref="T:System.Data.SQLite.Linq.SqlSelectStatement"/> |
||
813 | with the From field set.</returns> |
||
814 | </member> |
||
815 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.GetTargetTSql(System.Data.Metadata.Edm.EntitySetBase)"> |
||
816 | <summary> |
||
817 | Gets escaped TSql identifier describing this entity set. |
||
818 | </summary> |
||
819 | <returns></returns> |
||
820 | </member> |
||
821 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbFilterExpression)"> |
||
822 | <summary> |
||
823 | The bodies of <see cref="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbFilterExpression)"/>, <see cref="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbGroupByExpression)"/>, |
||
824 | <see cref="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbProjectExpression)"/>, <see cref="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbSortExpression)"/> are similar. |
||
825 | Each does the following. |
||
826 | <list type="number"> |
||
827 | <item> Visit the input expression</item> |
||
828 | <item> Determine if the input's SQL statement can be reused, or a new |
||
829 | one must be created.</item> |
||
830 | <item>Create a new symbol table scope</item> |
||
831 | <item>Push the Sql statement onto a stack, so that children can |
||
832 | update the free variable list.</item> |
||
833 | <item>Visit the non-input expression.</item> |
||
834 | <item>Cleanup</item> |
||
835 | </list> |
||
836 | </summary> |
||
837 | <param name="e"></param> |
||
838 | <returns>A <see cref="T:System.Data.SQLite.Linq.SqlSelectStatement"/></returns> |
||
839 | </member> |
||
840 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbFunctionExpression)"> |
||
841 | <summary> |
||
842 | Lambda functions are not supported. |
||
843 | The functions supported are: |
||
844 | <list type="number"> |
||
845 | <item>Canonical Functions - We recognize these by their dataspace, it is DataSpace.CSpace</item> |
||
846 | <item>Store Functions - We recognize these by the BuiltInAttribute and not being Canonical</item> |
||
847 | <item>User-defined Functions - All the rest except for Lambda functions</item> |
||
848 | </list> |
||
849 | We handle Canonical and Store functions the same way: If they are in the list of functions |
||
850 | that need special handling, we invoke the appropriate handler, otherwise we translate them to |
||
851 | FunctionName(arg1, arg2, ..., argn). |
||
852 | We translate user-defined functions to NamespaceName.FunctionName(arg1, arg2, ..., argn). |
||
853 | </summary> |
||
854 | <param name="e"></param> |
||
855 | <returns>A <see cref="T:System.Data.SQLite.Linq.SqlBuilder"/></returns> |
||
856 | </member> |
||
857 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbEntityRefExpression)"> |
||
858 | <summary> |
||
859 | <see cref="T:System.Data.Common.CommandTrees.DbEntityRefExpression"/> is illegal at this stage |
||
860 | </summary> |
||
861 | <param name="e"></param> |
||
862 | <returns></returns> |
||
863 | </member> |
||
864 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbRefKeyExpression)"> |
||
865 | <summary> |
||
866 | <see cref="T:System.Data.Common.CommandTrees.DbRefKeyExpression"/> is illegal at this stage |
||
867 | </summary> |
||
868 | <param name="e"></param> |
||
869 | <returns></returns> |
||
870 | </member> |
||
871 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbGroupByExpression)"> |
||
872 | <summary> |
||
873 | <see cref="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbFilterExpression)"/> for general details. |
||
874 | We modify both the GroupBy and the Select fields of the SqlSelectStatement. |
||
875 | GroupBy gets just the keys without aliases, |
||
876 | and Select gets the keys and the aggregates with aliases. |
||
877 | |||
878 | Whenever there exists at least one aggregate with an argument that is not is not a simple |
||
879 | <see cref="T:System.Data.Common.CommandTrees.DbPropertyExpression"/> over <see cref="T:System.Data.Common.CommandTrees.DbVariableReferenceExpression"/>, |
||
880 | we create a nested query in which we alias the arguments to the aggregates. |
||
881 | That is due to the following two limitations of Sql Server: |
||
882 | <list type="number"> |
||
883 | <item>If an expression being aggregated contains an outer reference, then that outer |
||
884 | reference must be the only column referenced in the expression </item> |
||
885 | <item>Sql Server cannot perform an aggregate function on an expression containing |
||
886 | an aggregate or a subquery. </item> |
||
887 | </list> |
||
888 | |||
889 | The default translation, without inner query is: |
||
890 | |||
891 | SELECT |
||
892 | kexp1 AS key1, kexp2 AS key2,... kexpn AS keyn, |
||
893 | aggf1(aexpr1) AS agg1, .. aggfn(aexprn) AS aggn |
||
894 | FROM input AS a |
||
895 | GROUP BY kexp1, kexp2, .. kexpn |
||
896 | |||
897 | When we inject an innner query, the equivalent translation is: |
||
898 | |||
899 | SELECT |
||
900 | key1 AS key1, key2 AS key2, .. keyn AS keys, |
||
901 | aggf1(agg1) AS agg1, aggfn(aggn) AS aggn |
||
902 | FROM ( |
||
903 | SELECT |
||
904 | kexp1 AS key1, kexp2 AS key2,... kexpn AS keyn, |
||
905 | aexpr1 AS agg1, .. aexprn AS aggn |
||
906 | FROM input AS a |
||
907 | ) as a |
||
908 | GROUP BY key1, key2, keyn |
||
909 | |||
910 | </summary> |
||
911 | <param name="e"></param> |
||
912 | <returns>A <see cref="T:System.Data.SQLite.Linq.SqlSelectStatement"/></returns> |
||
913 | </member> |
||
914 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbIntersectExpression)"> |
||
915 | <summary> |
||
916 | <see cref="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbUnionAllExpression)"/> |
||
917 | </summary> |
||
918 | <param name="e"></param> |
||
919 | <returns></returns> |
||
920 | </member> |
||
921 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbIsEmptyExpression)"> |
||
922 | <summary> |
||
923 | Not(IsEmpty) has to be handled specially, so we delegate to |
||
924 | <see cref="M:System.Data.SQLite.Linq.SqlGenerator.VisitIsEmptyExpression(System.Data.Common.CommandTrees.DbIsEmptyExpression,System.Boolean)"/>. |
||
925 | |||
926 | </summary> |
||
927 | <param name="e"></param> |
||
928 | <returns>A <see cref="T:System.Data.SQLite.Linq.SqlBuilder"/>. |
||
929 | <code>[NOT] EXISTS( ... )</code> |
||
930 | </returns> |
||
931 | </member> |
||
932 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbIsNullExpression)"> |
||
933 | <summary> |
||
934 | Not(IsNull) is handled specially, so we delegate to |
||
935 | <see cref="M:System.Data.SQLite.Linq.SqlGenerator.VisitIsNullExpression(System.Data.Common.CommandTrees.DbIsNullExpression,System.Boolean)"/> |
||
936 | </summary> |
||
937 | <param name="e"></param> |
||
938 | <returns>A <see cref="T:System.Data.SQLite.Linq.SqlBuilder"/> |
||
939 | <code>IS [NOT] NULL</code> |
||
940 | </returns> |
||
941 | </member> |
||
942 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbIsOfExpression)"> |
||
943 | <summary> |
||
944 | <see cref="T:System.Data.Common.CommandTrees.DbIsOfExpression"/> is illegal at this stage |
||
945 | </summary> |
||
946 | <param name="e"></param> |
||
947 | <returns>A <see cref="T:System.Data.SQLite.Linq.SqlBuilder"/></returns> |
||
948 | </member> |
||
949 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbCrossJoinExpression)"> |
||
950 | <summary> |
||
951 | <see cref="M:System.Data.SQLite.Linq.SqlGenerator.VisitJoinExpression(System.Collections.Generic.IList{System.Data.Common.CommandTrees.DbExpressionBinding},System.Data.Common.CommandTrees.DbExpressionKind,System.String,System.Data.Common.CommandTrees.DbExpression)"/> |
||
952 | </summary> |
||
953 | <param name="e"></param> |
||
954 | <returns>A <see cref="T:System.Data.SQLite.Linq.SqlSelectStatement"/>.</returns> |
||
955 | </member> |
||
956 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbJoinExpression)"> |
||
957 | <summary> |
||
958 | <see cref="M:System.Data.SQLite.Linq.SqlGenerator.VisitJoinExpression(System.Collections.Generic.IList{System.Data.Common.CommandTrees.DbExpressionBinding},System.Data.Common.CommandTrees.DbExpressionKind,System.String,System.Data.Common.CommandTrees.DbExpression)"/> |
||
959 | </summary> |
||
960 | <param name="e"></param> |
||
961 | <returns>A <see cref="T:System.Data.SQLite.Linq.SqlSelectStatement"/>.</returns> |
||
962 | </member> |
||
963 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbLikeExpression)"> |
||
964 | <summary> |
||
965 | |||
966 | </summary> |
||
967 | <param name="e"></param> |
||
968 | <returns>A <see cref="T:System.Data.SQLite.Linq.SqlBuilder"/></returns> |
||
969 | </member> |
||
970 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbLimitExpression)"> |
||
971 | <summary> |
||
972 | Translates to TOP expression. |
||
973 | </summary> |
||
974 | <param name="e"></param> |
||
975 | <returns>A <see cref="T:System.Data.SQLite.Linq.SqlBuilder"/></returns> |
||
976 | </member> |
||
977 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbNewInstanceExpression)"> |
||
978 | <summary> |
||
979 | DbNewInstanceExpression is allowed as a child of DbProjectExpression only. |
||
980 | If anyone else is the parent, we throw. |
||
981 | We also perform special casing for collections - where we could convert |
||
982 | them into Unions |
||
983 | |||
984 | <see cref="M:System.Data.SQLite.Linq.SqlGenerator.VisitNewInstanceExpression(System.Data.Common.CommandTrees.DbNewInstanceExpression)"/> for the actual implementation. |
||
985 | |||
986 | </summary> |
||
987 | <param name="e"></param> |
||
988 | <returns></returns> |
||
989 | </member> |
||
990 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbNotExpression)"> |
||
991 | <summary> |
||
992 | The Not expression may cause the translation of its child to change. |
||
993 | These children are |
||
994 | <list type="bullet"> |
||
995 | <item><see cref="T:System.Data.Common.CommandTrees.DbNotExpression"/>NOT(Not(x)) becomes x</item> |
||
996 | <item><see cref="T:System.Data.Common.CommandTrees.DbIsEmptyExpression"/>NOT EXISTS becomes EXISTS</item> |
||
997 | <item><see cref="T:System.Data.Common.CommandTrees.DbIsNullExpression"/>IS NULL becomes IS NOT NULL</item> |
||
998 | <item><see cref="T:System.Data.Common.CommandTrees.DbComparisonExpression"/>= becomes<> </item> |
||
999 | </list> |
||
1000 | </summary> |
||
1001 | <param name="e"></param> |
||
1002 | <returns>A <see cref="T:System.Data.SQLite.Linq.SqlBuilder"/></returns> |
||
1003 | </member> |
||
1004 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbNullExpression)"> |
||
1005 | <summary> |
||
1006 | </summary> |
||
1007 | <param name="e"></param> |
||
1008 | <returns><see cref="T:System.Data.SQLite.Linq.SqlBuilder"/></returns> |
||
1009 | </member> |
||
1010 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbOfTypeExpression)"> |
||
1011 | <summary> |
||
1012 | <see cref="T:System.Data.Common.CommandTrees.DbOfTypeExpression"/> is illegal at this stage |
||
1013 | </summary> |
||
1014 | <param name="e"></param> |
||
1015 | <returns>A <see cref="T:System.Data.SQLite.Linq.SqlBuilder"/></returns> |
||
1016 | </member> |
||
1017 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbOrExpression)"> |
||
1018 | <summary> |
||
1019 | |||
1020 | </summary> |
||
1021 | <param name="e"></param> |
||
1022 | <returns>A <see cref="T:System.Data.SQLite.Linq.SqlBuilder"/></returns> |
||
1023 | <seealso cref="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbAndExpression)"/> |
||
1024 | </member> |
||
1025 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbParameterReferenceExpression)"> |
||
1026 | <summary> |
||
1027 | |||
1028 | </summary> |
||
1029 | <param name="e"></param> |
||
1030 | <returns>A <see cref="T:System.Data.SQLite.Linq.SqlBuilder"/></returns> |
||
1031 | </member> |
||
1032 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbProjectExpression)"> |
||
1033 | <summary> |
||
1034 | <see cref="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbFilterExpression)"/> for the general ideas. |
||
1035 | </summary> |
||
1036 | <param name="e"></param> |
||
1037 | <returns>A <see cref="T:System.Data.SQLite.Linq.SqlSelectStatement"/></returns> |
||
1038 | <seealso cref="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbFilterExpression)"/> |
||
1039 | </member> |
||
1040 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbPropertyExpression)"> |
||
1041 | <summary> |
||
1042 | This method handles record flattening, which works as follows. |
||
1043 | consider an expression <c>Prop(y, Prop(x, Prop(d, Prop(c, Prop(b, Var(a)))))</c> |
||
1044 | where a,b,c are joins, d is an extent and x and y are fields. |
||
1045 | b has been flattened into a, and has its own SELECT statement. |
||
1046 | c has been flattened into b. |
||
1047 | d has been flattened into c. |
||
1048 | |||
1049 | We visit the instance, so we reach Var(a) first. This gives us a (join)symbol. |
||
1050 | Symbol(a).b gives us a join symbol, with a SELECT statement i.e. Symbol(b). |
||
1051 | From this point on , we need to remember Symbol(b) as the source alias, |
||
1052 | and then try to find the column. So, we use a SymbolPair. |
||
1053 | |||
1054 | We have reached the end when the symbol no longer points to a join symbol. |
||
1055 | </summary> |
||
1056 | <param name="e"></param> |
||
1057 | <returns>A <see cref="T:System.Data.SQLite.Linq.JoinSymbol"/> if we have not reached the first |
||
1058 | Join node that has a SELECT statement. |
||
1059 | A <see cref="T:System.Data.SQLite.Linq.SymbolPair"/> if we have seen the JoinNode, and it has |
||
1060 | a SELECT statement. |
||
1061 | A <see cref="T:System.Data.SQLite.Linq.SqlBuilder"/> with {Input}.propertyName otherwise. |
||
1062 | </returns> |
||
1063 | </member> |
||
1064 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbQuantifierExpression)"> |
||
1065 | <summary> |
||
1066 | Any(input, x) => Exists(Filter(input,x)) |
||
1067 | All(input, x) => Not Exists(Filter(input, not(x)) |
||
1068 | </summary> |
||
1069 | <param name="e"></param> |
||
1070 | <returns></returns> |
||
1071 | </member> |
||
1072 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbRefExpression)"> |
||
1073 | <summary> |
||
1074 | <see cref="T:System.Data.Common.CommandTrees.DbRefExpression"/> is illegal at this stage |
||
1075 | </summary> |
||
1076 | <param name="e"></param> |
||
1077 | <returns></returns> |
||
1078 | </member> |
||
1079 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbRelationshipNavigationExpression)"> |
||
1080 | <summary> |
||
1081 | <see cref="T:System.Data.Common.CommandTrees.DbRelationshipNavigationExpression"/> is illegal at this stage |
||
1082 | </summary> |
||
1083 | <param name="e"></param> |
||
1084 | <returns></returns> |
||
1085 | </member> |
||
1086 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbSkipExpression)"> |
||
1087 | <summary> |
||
1088 | For Sql9 it translates to: |
||
1089 | SELECT Y.x1, Y.x2, ..., Y.xn |
||
1090 | FROM ( |
||
1091 | SELECT X.x1, X.x2, ..., X.xn, row_number() OVER (ORDER BY sk1, sk2, ...) AS [row_number] |
||
1092 | FROM input as X |
||
1093 | ) as Y |
||
1094 | WHERE Y.[row_number] > count |
||
1095 | ORDER BY sk1, sk2, ... |
||
1096 | </summary> |
||
1097 | <param name="e"></param> |
||
1098 | <returns>A <see cref="T:System.Data.SQLite.Linq.SqlBuilder"/></returns> |
||
1099 | </member> |
||
1100 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbSortExpression)"> |
||
1101 | <summary> |
||
1102 | <see cref="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbFilterExpression)"/> |
||
1103 | </summary> |
||
1104 | <param name="e"></param> |
||
1105 | <returns>A <see cref="T:System.Data.SQLite.Linq.SqlSelectStatement"/></returns> |
||
1106 | <seealso cref="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbFilterExpression)"/> |
||
1107 | </member> |
||
1108 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbTreatExpression)"> |
||
1109 | <summary> |
||
1110 | <see cref="T:System.Data.Common.CommandTrees.DbTreatExpression"/> is illegal at this stage |
||
1111 | </summary> |
||
1112 | <param name="e"></param> |
||
1113 | <returns>A <see cref="T:System.Data.SQLite.Linq.SqlBuilder"/></returns> |
||
1114 | </member> |
||
1115 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbUnionAllExpression)"> |
||
1116 | <summary> |
||
1117 | This code is shared by <see cref="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbExceptExpression)"/> |
||
1118 | and <see cref="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbIntersectExpression)"/> |
||
1119 | |||
1120 | <see cref="M:System.Data.SQLite.Linq.SqlGenerator.VisitSetOpExpression(System.Data.Common.CommandTrees.DbExpression,System.Data.Common.CommandTrees.DbExpression,System.String)"/> |
||
1121 | Since the left and right expression may not be Sql select statements, |
||
1122 | we must wrap them up to look like SQL select statements. |
||
1123 | </summary> |
||
1124 | <param name="e"></param> |
||
1125 | <returns></returns> |
||
1126 | </member> |
||
1127 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbVariableReferenceExpression)"> |
||
1128 | <summary> |
||
1129 | This method determines whether an extent from an outer scope(free variable) |
||
1130 | is used in the CurrentSelectStatement. |
||
1131 | |||
1132 | An extent in an outer scope, if its symbol is not in the FromExtents |
||
1133 | of the CurrentSelectStatement. |
||
1134 | </summary> |
||
1135 | <param name="e"></param> |
||
1136 | <returns>A <see cref="T:System.Data.SQLite.Linq.Symbol"/>.</returns> |
||
1137 | </member> |
||
1138 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.VisitAggregate(System.Data.Common.CommandTrees.DbAggregate,System.Object)"> |
||
1139 | <summary> |
||
1140 | Aggregates are not visited by the normal visitor walk. |
||
1141 | </summary> |
||
1142 | <param name="aggregate">The aggreate to be translated</param> |
||
1143 | <param name="aggregateArgument">The translated aggregate argument</param> |
||
1144 | <returns></returns> |
||
1145 | </member> |
||
1146 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.VisitInputExpression(System.Data.Common.CommandTrees.DbExpression,System.String,System.Data.Metadata.Edm.TypeUsage,System.Data.SQLite.Linq.Symbol@)"> |
||
1147 | <summary> |
||
1148 | This is called by the relational nodes. It does the following |
||
1149 | <list> |
||
1150 | <item>If the input is not a SqlSelectStatement, it assumes that the input |
||
1151 | is a collection expression, and creates a new SqlSelectStatement </item> |
||
1152 | </list> |
||
1153 | </summary> |
||
1154 | <param name="inputExpression"></param> |
||
1155 | <param name="inputVarName"></param> |
||
1156 | <param name="inputVarType"></param> |
||
1157 | <param name="fromSymbol"></param> |
||
1158 | <returns>A <see cref="T:System.Data.SQLite.Linq.SqlSelectStatement"/> and the main fromSymbol |
||
1159 | for this select statement.</returns> |
||
1160 | </member> |
||
1161 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.VisitIsEmptyExpression(System.Data.Common.CommandTrees.DbIsEmptyExpression,System.Boolean)"> |
||
1162 | <summary> |
||
1163 | <see cref="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbIsEmptyExpression)"/> |
||
1164 | </summary> |
||
1165 | <param name="e"></param> |
||
1166 | <param name="negate">Was the parent a DbNotExpression?</param> |
||
1167 | <returns></returns> |
||
1168 | </member> |
||
1169 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.VisitCollectionConstructor(System.Data.Common.CommandTrees.DbNewInstanceExpression)"> |
||
1170 | <summary> |
||
1171 | Translate a NewInstance(Element(X)) expression into |
||
1172 | "select top(1) * from X" |
||
1173 | </summary> |
||
1174 | <param name="e"></param> |
||
1175 | <returns></returns> |
||
1176 | </member> |
||
1177 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.VisitIsNullExpression(System.Data.Common.CommandTrees.DbIsNullExpression,System.Boolean)"> |
||
1178 | <summary> |
||
1179 | <see cref="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbIsNullExpression)"/> |
||
1180 | </summary> |
||
1181 | <param name="e"></param> |
||
1182 | <param name="negate">Was the parent a DbNotExpression?</param> |
||
1183 | <returns></returns> |
||
1184 | </member> |
||
1185 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.VisitJoinExpression(System.Collections.Generic.IList{System.Data.Common.CommandTrees.DbExpressionBinding},System.Data.Common.CommandTrees.DbExpressionKind,System.String,System.Data.Common.CommandTrees.DbExpression)"> |
||
1186 | <summary> |
||
1187 | This handles the processing of join expressions. |
||
1188 | The extents on a left spine are flattened, while joins |
||
1189 | not on the left spine give rise to new nested sub queries. |
||
1190 | |||
1191 | Joins work differently from the rest of the visiting, in that |
||
1192 | the parent (i.e. the join node) creates the SqlSelectStatement |
||
1193 | for the children to use. |
||
1194 | |||
1195 | The "parameter" IsInJoinContext indicates whether a child extent should |
||
1196 | add its stuff to the existing SqlSelectStatement, or create a new SqlSelectStatement |
||
1197 | By passing true, we ask the children to add themselves to the parent join, |
||
1198 | by passing false, we ask the children to create new Select statements for |
||
1199 | themselves. |
||
1200 | |||
1201 | This method is called from <see cref="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbApplyExpression)"/> and |
||
1202 | <see cref="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbJoinExpression)"/>. |
||
1203 | </summary> |
||
1204 | <param name="inputs"></param> |
||
1205 | <param name="joinKind"></param> |
||
1206 | <param name="joinString"></param> |
||
1207 | <param name="joinCondition"></param> |
||
1208 | <returns> A <see cref="T:System.Data.SQLite.Linq.SqlSelectStatement"/></returns> |
||
1209 | </member> |
||
1210 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.ProcessJoinInputResult(System.Data.SQLite.Linq.ISqlFragment,System.Data.SQLite.Linq.SqlSelectStatement,System.Data.Common.CommandTrees.DbExpressionBinding,System.Int32)"> |
||
1211 | <summary> |
||
1212 | This is called from <see cref="M:System.Data.SQLite.Linq.SqlGenerator.VisitJoinExpression(System.Collections.Generic.IList{System.Data.Common.CommandTrees.DbExpressionBinding},System.Data.Common.CommandTrees.DbExpressionKind,System.String,System.Data.Common.CommandTrees.DbExpression)"/>. |
||
1213 | |||
1214 | This is responsible for maintaining the symbol table after visiting |
||
1215 | a child of a join expression. |
||
1216 | |||
1217 | The child's sql statement may need to be completed. |
||
1218 | |||
1219 | The child's result could be one of |
||
1220 | <list type="number"> |
||
1221 | <item>The same as the parent's - this is treated specially.</item> |
||
1222 | <item>A sql select statement, which may need to be completed</item> |
||
1223 | <item>An extent - just copy it to the from clause</item> |
||
1224 | <item>Anything else (from a collection-valued expression) - |
||
1225 | unnest and copy it.</item> |
||
1226 | </list> |
||
1227 | |||
1228 | If the input was a Join, we need to create a new join symbol, |
||
1229 | otherwise, we create a normal symbol. |
||
1230 | |||
1231 | We then call AddFromSymbol to add the AS clause, and update the symbol table. |
||
1232 | |||
1233 | |||
1234 | |||
1235 | If the child's result was the same as the parent's, we have to clean up |
||
1236 | the list of symbols in the FromExtents list, since this contains symbols from |
||
1237 | the children of both the parent and the child. |
||
1238 | The happens when the child visited is a Join, and is the leftmost child of |
||
1239 | the parent. |
||
1240 | </summary> |
||
1241 | <param name="fromExtentFragment"></param> |
||
1242 | <param name="result"></param> |
||
1243 | <param name="input"></param> |
||
1244 | <param name="fromSymbolStart"></param> |
||
1245 | </member> |
||
1246 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.VisitNewInstanceExpression(System.Data.Common.CommandTrees.DbNewInstanceExpression)"> |
||
1247 | <summary> |
||
1248 | We assume that this is only called as a child of a Project. |
||
1249 | |||
1250 | This replaces <see cref="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbNewInstanceExpression)"/>, since |
||
1251 | we do not allow DbNewInstanceExpression as a child of any node other than |
||
1252 | DbProjectExpression. |
||
1253 | |||
1254 | We write out the translation of each of the columns in the record. |
||
1255 | </summary> |
||
1256 | <param name="e"></param> |
||
1257 | <returns>A <see cref="T:System.Data.SQLite.Linq.SqlBuilder"/></returns> |
||
1258 | </member> |
||
1259 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.IsSpecialBuiltInFunction(System.Data.Common.CommandTrees.DbFunctionExpression)"> |
||
1260 | <summary> |
||
1261 | Determines whether the given function is a built-in function that requires special handling |
||
1262 | </summary> |
||
1263 | <param name="e"></param> |
||
1264 | <returns></returns> |
||
1265 | </member> |
||
1266 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.IsSpecialCanonicalFunction(System.Data.Common.CommandTrees.DbFunctionExpression)"> |
||
1267 | <summary> |
||
1268 | Determines whether the given function is a canonical function that requires special handling |
||
1269 | </summary> |
||
1270 | <param name="e"></param> |
||
1271 | <returns></returns> |
||
1272 | </member> |
||
1273 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.HandleFunctionDefault(System.Data.Common.CommandTrees.DbFunctionExpression)"> |
||
1274 | <summary> |
||
1275 | Default handling for functions |
||
1276 | Translates them to FunctionName(arg1, arg2, ..., argn) |
||
1277 | </summary> |
||
1278 | <param name="e"></param> |
||
1279 | <returns></returns> |
||
1280 | </member> |
||
1281 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.HandleFunctionDefaultGivenName(System.Data.Common.CommandTrees.DbFunctionExpression,System.String)"> |
||
1282 | <summary> |
||
1283 | Default handling for functions with a given name. |
||
1284 | Translates them to functionName(arg1, arg2, ..., argn) |
||
1285 | </summary> |
||
1286 | <param name="e"></param> |
||
1287 | <param name="functionName"></param> |
||
1288 | <returns></returns> |
||
1289 | </member> |
||
1290 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.HandleFunctionArgumentsDefault(System.Data.Common.CommandTrees.DbFunctionExpression,System.Data.SQLite.Linq.SqlBuilder)"> |
||
1291 | <summary> |
||
1292 | Default handling on function arguments |
||
1293 | Appends the list of arguments to the given result |
||
1294 | If the function is niladic it does not append anything, |
||
1295 | otherwise it appends (arg1, arg2, ..., argn) |
||
1296 | </summary> |
||
1297 | <param name="e"></param> |
||
1298 | <param name="result"></param> |
||
1299 | </member> |
||
1300 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.HandleSpecialBuiltInFunction(System.Data.Common.CommandTrees.DbFunctionExpression)"> |
||
1301 | <summary> |
||
1302 | Handler for special built in functions |
||
1303 | </summary> |
||
1304 | <param name="e"></param> |
||
1305 | <returns></returns> |
||
1306 | </member> |
||
1307 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.HandleSpecialCanonicalFunction(System.Data.Common.CommandTrees.DbFunctionExpression)"> |
||
1308 | <summary> |
||
1309 | Handler for special canonical functions |
||
1310 | </summary> |
||
1311 | <param name="e"></param> |
||
1312 | <returns></returns> |
||
1313 | </member> |
||
1314 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.HandleSpecialFunction(System.Collections.Generic.Dictionary{System.String,System.Data.SQLite.Linq.SqlGenerator.FunctionHandler},System.Data.Common.CommandTrees.DbFunctionExpression)"> |
||
1315 | <summary> |
||
1316 | Dispatches the special function processing to the appropriate handler |
||
1317 | </summary> |
||
1318 | <param name="handlers"></param> |
||
1319 | <param name="e"></param> |
||
1320 | <returns></returns> |
||
1321 | </member> |
||
1322 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.HandleSpecialFunctionToOperator(System.Data.Common.CommandTrees.DbFunctionExpression,System.Boolean)"> |
||
1323 | <summary> |
||
1324 | Handles functions that are translated into TSQL operators. |
||
1325 | The given function should have one or two arguments. |
||
1326 | Functions with one arguemnt are translated into |
||
1327 | op arg |
||
1328 | Functions with two arguments are translated into |
||
1329 | arg0 op arg1 |
||
1330 | Also, the arguments can be optionaly enclosed in parethesis |
||
1331 | </summary> |
||
1332 | <param name="e"></param> |
||
1333 | <param name="parenthesiseArguments">Whether the arguments should be enclosed in parethesis</param> |
||
1334 | <returns></returns> |
||
1335 | </member> |
||
1336 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.HandleConcatFunction(System.Data.SQLite.Linq.SqlGenerator,System.Data.Common.CommandTrees.DbFunctionExpression)"> |
||
1337 | <summary> |
||
1338 | <see cref="M:System.Data.SQLite.Linq.SqlGenerator.HandleSpecialFunctionToOperator(System.Data.Common.CommandTrees.DbFunctionExpression,System.Boolean)"></see> |
||
1339 | </summary> |
||
1340 | <param name="sqlgen"></param> |
||
1341 | <param name="e"></param> |
||
1342 | <returns></returns> |
||
1343 | </member> |
||
1344 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.HandleCanonicalFunctionBitwise(System.Data.SQLite.Linq.SqlGenerator,System.Data.Common.CommandTrees.DbFunctionExpression)"> |
||
1345 | <summary> |
||
1346 | <see cref="M:System.Data.SQLite.Linq.SqlGenerator.HandleSpecialFunctionToOperator(System.Data.Common.CommandTrees.DbFunctionExpression,System.Boolean)"></see> |
||
1347 | </summary> |
||
1348 | <param name="sqlgen"></param> |
||
1349 | <param name="e"></param> |
||
1350 | <returns></returns> |
||
1351 | </member> |
||
1352 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.HandleDatepartDateFunction(System.Data.SQLite.Linq.SqlGenerator,System.Data.Common.CommandTrees.DbFunctionExpression)"> |
||
1353 | <summary> |
||
1354 | Handles special case in which datepart 'type' parameter is present. all the functions |
||
1355 | handles here have *only* the 1st parameter as datepart. datepart value is passed along |
||
1356 | the QP as string and has to be expanded as TSQL keyword. |
||
1357 | </summary> |
||
1358 | <param name="sqlgen"></param> |
||
1359 | <param name="e"></param> |
||
1360 | <returns></returns> |
||
1361 | </member> |
||
1362 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.HandleCanonicalFunctionDateAdd(System.Data.SQLite.Linq.SqlGenerator,System.Data.Common.CommandTrees.DbFunctionExpression)"> |
||
1363 | <summary> |
||
1364 | DateAdd(datetime, secondsToAdd) -> DATEADD ( seconds , number, date) |
||
1365 | </summary> |
||
1366 | <param name="sqlgen"></param> |
||
1367 | <param name="e"></param> |
||
1368 | <returns></returns> |
||
1369 | </member> |
||
1370 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.HandleCanonicalFunctionDateSubtract(System.Data.SQLite.Linq.SqlGenerator,System.Data.Common.CommandTrees.DbFunctionExpression)"> |
||
1371 | <summary> |
||
1372 | DateSubtract(datetime1, datetime2) -> DATEDIFF ( seconds , startdate , enddate ) |
||
1373 | </summary> |
||
1374 | <param name="sqlgen"></param> |
||
1375 | <param name="e"></param> |
||
1376 | <returns></returns> |
||
1377 | </member> |
||
1378 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.HandleCanonicalFunctionDatepart(System.Data.SQLite.Linq.SqlGenerator,System.Data.Common.CommandTrees.DbFunctionExpression)"> |
||
1379 | <summary> |
||
1380 | Handler for canonical functions for extracting date parts. |
||
1381 | For example: |
||
1382 | Year(date) -> DATEPART( year, date) |
||
1383 | </summary> |
||
1384 | <param name="sqlgen"></param> |
||
1385 | <param name="e"></param> |
||
1386 | <returns></returns> |
||
1387 | </member> |
||
1388 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.HandleCanonicalFunctionIndexOf(System.Data.SQLite.Linq.SqlGenerator,System.Data.Common.CommandTrees.DbFunctionExpression)"> |
||
1389 | <summary> |
||
1390 | Function rename IndexOf -> CHARINDEX |
||
1391 | </summary> |
||
1392 | <param name="sqlgen"></param> |
||
1393 | <param name="e"></param> |
||
1394 | <returns></returns> |
||
1395 | </member> |
||
1396 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.HandleCanonicalFunctionNewGuid(System.Data.SQLite.Linq.SqlGenerator,System.Data.Common.CommandTrees.DbFunctionExpression)"> |
||
1397 | <summary> |
||
1398 | Function rename NewGuid -> NEWID |
||
1399 | </summary> |
||
1400 | <param name="sqlgen"></param> |
||
1401 | <param name="e"></param> |
||
1402 | <returns></returns> |
||
1403 | </member> |
||
1404 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.HandleCanonicalFunctionLength(System.Data.SQLite.Linq.SqlGenerator,System.Data.Common.CommandTrees.DbFunctionExpression)"> |
||
1405 | <summary> |
||
1406 | Length(arg) -> LEN(arg + '.') - LEN('.') |
||
1407 | </summary> |
||
1408 | <param name="sqlgen"></param> |
||
1409 | <param name="e"></param> |
||
1410 | <returns></returns> |
||
1411 | </member> |
||
1412 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.HandleCanonicalFunctionRound(System.Data.SQLite.Linq.SqlGenerator,System.Data.Common.CommandTrees.DbFunctionExpression)"> |
||
1413 | <summary> |
||
1414 | Round(numericExpression) -> Round(numericExpression, 0); |
||
1415 | Round(numericExpression, N) -> Round(numericExpression, N); |
||
1416 | </summary> |
||
1417 | <param name="sqlgen"></param> |
||
1418 | <param name="e"></param> |
||
1419 | <returns></returns> |
||
1420 | </member> |
||
1421 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.HandleCanonicalFunctionTrim(System.Data.SQLite.Linq.SqlGenerator,System.Data.Common.CommandTrees.DbFunctionExpression)"> |
||
1422 | <summary> |
||
1423 | TRIM(string) -> LTRIM(RTRIM(string)) |
||
1424 | </summary> |
||
1425 | <param name="sqlgen"></param> |
||
1426 | <param name="e"></param> |
||
1427 | <returns></returns> |
||
1428 | </member> |
||
1429 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.HandleCanonicalFunctionLeft(System.Data.SQLite.Linq.SqlGenerator,System.Data.Common.CommandTrees.DbFunctionExpression)"> |
||
1430 | <summary> |
||
1431 | LEFT(string, length) -> SUBSTR(string, 1, length) |
||
1432 | </summary> |
||
1433 | <param name="sqlgen"></param> |
||
1434 | <param name="e"></param> |
||
1435 | <returns></returns> |
||
1436 | </member> |
||
1437 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.HandleCanonicalFunctionRight(System.Data.SQLite.Linq.SqlGenerator,System.Data.Common.CommandTrees.DbFunctionExpression)"> |
||
1438 | <summary> |
||
1439 | RIGHT(string, length) -> SUBSTR(string, -(length), length) |
||
1440 | </summary> |
||
1441 | <param name="sqlgen"></param> |
||
1442 | <param name="e"></param> |
||
1443 | <returns></returns> |
||
1444 | </member> |
||
1445 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.HandleCanonicalFunctionSubstring(System.Data.SQLite.Linq.SqlGenerator,System.Data.Common.CommandTrees.DbFunctionExpression)"> |
||
1446 | <summary> |
||
1447 | SUBSTRING(string, start) -> SUBSTR(string, start) |
||
1448 | SUBSTRING(string, start, length) -> SUBSTR(string, start, length) |
||
1449 | </summary> |
||
1450 | <param name="sqlgen"></param> |
||
1451 | <param name="e"></param> |
||
1452 | <returns></returns> |
||
1453 | </member> |
||
1454 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.HandleCanonicalFunctionToLower(System.Data.SQLite.Linq.SqlGenerator,System.Data.Common.CommandTrees.DbFunctionExpression)"> |
||
1455 | <summary> |
||
1456 | Function rename ToLower -> LOWER |
||
1457 | </summary> |
||
1458 | <param name="sqlgen"></param> |
||
1459 | <param name="e"></param> |
||
1460 | <returns></returns> |
||
1461 | </member> |
||
1462 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.HandleCanonicalFunctionToUpper(System.Data.SQLite.Linq.SqlGenerator,System.Data.Common.CommandTrees.DbFunctionExpression)"> |
||
1463 | <summary> |
||
1464 | Function rename ToUpper -> UPPER |
||
1465 | </summary> |
||
1466 | <param name="sqlgen"></param> |
||
1467 | <param name="e"></param> |
||
1468 | <returns></returns> |
||
1469 | </member> |
||
1470 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.AddColumns(System.Data.SQLite.Linq.SqlSelectStatement,System.Data.SQLite.Linq.Symbol,System.Collections.Generic.List{System.Data.SQLite.Linq.Symbol},System.Collections.Generic.Dictionary{System.String,System.Data.SQLite.Linq.Symbol},System.String@)"> |
||
1471 | <summary> |
||
1472 | <see cref="M:System.Data.SQLite.Linq.SqlGenerator.AddDefaultColumns(System.Data.SQLite.Linq.SqlSelectStatement)"/> |
||
1473 | Add the column names from the referenced extent/join to the |
||
1474 | select statement. |
||
1475 | |||
1476 | If the symbol is a JoinSymbol, we recursively visit all the extents, |
||
1477 | halting at real extents and JoinSymbols that have an associated SqlSelectStatement. |
||
1478 | |||
1479 | The column names for a real extent can be derived from its type. |
||
1480 | The column names for a Join Select statement can be got from the |
||
1481 | list of columns that was created when the Join's select statement |
||
1482 | was created. |
||
1483 | |||
1484 | We do the following for each column. |
||
1485 | <list type="number"> |
||
1486 | <item>Add the SQL string for each column to the SELECT clause</item> |
||
1487 | <item>Add the column to the list of columns - so that it can |
||
1488 | become part of the "type" of a JoinSymbol</item> |
||
1489 | <item>Check if the column name collides with a previous column added |
||
1490 | to the same select statement. Flag both the columns for renaming if true.</item> |
||
1491 | <item>Add the column to a name lookup dictionary for collision detection.</item> |
||
1492 | </list> |
||
1493 | </summary> |
||
1494 | <param name="selectStatement">The select statement that started off as SELECT *</param> |
||
1495 | <param name="symbol">The symbol containing the type information for |
||
1496 | the columns to be added.</param> |
||
1497 | <param name="columnList">Columns that have been added to the Select statement. |
||
1498 | This is created in <see cref="M:System.Data.SQLite.Linq.SqlGenerator.AddDefaultColumns(System.Data.SQLite.Linq.SqlSelectStatement)"/>.</param> |
||
1499 | <param name="columnDictionary">A dictionary of the columns above.</param> |
||
1500 | <param name="separator">Comma or nothing, depending on whether the SELECT |
||
1501 | clause is empty.</param> |
||
1502 | </member> |
||
1503 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.AddDefaultColumns(System.Data.SQLite.Linq.SqlSelectStatement)"> |
||
1504 | <summary> |
||
1505 | Expands Select * to "select the_list_of_columns" |
||
1506 | If the columns are taken from an extent, they are written as |
||
1507 | {original_column_name AS Symbol(original_column)} to allow renaming. |
||
1508 | |||
1509 | If the columns are taken from a Join, they are written as just |
||
1510 | {original_column_name}, since there cannot be a name collision. |
||
1511 | |||
1512 | We concatenate the columns from each of the inputs to the select statement. |
||
1513 | Since the inputs may be joins that are flattened, we need to recurse. |
||
1514 | The inputs are inferred from the symbols in FromExtents. |
||
1515 | </summary> |
||
1516 | <param name="selectStatement"></param> |
||
1517 | <returns></returns> |
||
1518 | </member> |
||
1519 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.AddFromSymbol(System.Data.SQLite.Linq.SqlSelectStatement,System.String,System.Data.SQLite.Linq.Symbol)"> |
||
1520 | <summary> |
||
1521 | <see cref="M:System.Data.SQLite.Linq.SqlGenerator.AddFromSymbol(System.Data.SQLite.Linq.SqlSelectStatement,System.String,System.Data.SQLite.Linq.Symbol,System.Boolean)"/> |
||
1522 | </summary> |
||
1523 | <param name="selectStatement"></param> |
||
1524 | <param name="inputVarName"></param> |
||
1525 | <param name="fromSymbol"></param> |
||
1526 | </member> |
||
1527 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.AddFromSymbol(System.Data.SQLite.Linq.SqlSelectStatement,System.String,System.Data.SQLite.Linq.Symbol,System.Boolean)"> |
||
1528 | <summary> |
||
1529 | This method is called after the input to a relational node is visited. |
||
1530 | <see cref="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbProjectExpression)"/> and <see cref="M:System.Data.SQLite.Linq.SqlGenerator.ProcessJoinInputResult(System.Data.SQLite.Linq.ISqlFragment,System.Data.SQLite.Linq.SqlSelectStatement,System.Data.Common.CommandTrees.DbExpressionBinding,System.Int32)"/> |
||
1531 | There are 2 scenarios |
||
1532 | <list type="number"> |
||
1533 | <item>The fromSymbol is new i.e. the select statement has just been |
||
1534 | created, or a join extent has been added.</item> |
||
1535 | <item>The fromSymbol is old i.e. we are reusing a select statement.</item> |
||
1536 | </list> |
||
1537 | |||
1538 | If we are not reusing the select statement, we have to complete the |
||
1539 | FROM clause with the alias |
||
1540 | <code> |
||
1541 | -- if the input was an extent |
||
1542 | FROM = [SchemaName].[TableName] |
||
1543 | -- if the input was a Project |
||
1544 | FROM = (SELECT ... FROM ... WHERE ...) |
||
1545 | </code> |
||
1546 | |||
1547 | These become |
||
1548 | <code> |
||
1549 | -- if the input was an extent |
||
1550 | FROM = [SchemaName].[TableName] AS alias |
||
1551 | -- if the input was a Project |
||
1552 | FROM = (SELECT ... FROM ... WHERE ...) AS alias |
||
1553 | </code> |
||
1554 | and look like valid FROM clauses. |
||
1555 | |||
1556 | Finally, we have to add the alias to the global list of aliases used, |
||
1557 | and also to the current symbol table. |
||
1558 | </summary> |
||
1559 | <param name="selectStatement"></param> |
||
1560 | <param name="inputVarName">The alias to be used.</param> |
||
1561 | <param name="fromSymbol"></param> |
||
1562 | <param name="addToSymbolTable"></param> |
||
1563 | </member> |
||
1564 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.AddSortKeys(System.Data.SQLite.Linq.SqlBuilder,System.Collections.Generic.IList{System.Data.Common.CommandTrees.DbSortClause})"> |
||
1565 | <summary> |
||
1566 | Translates a list of SortClauses. |
||
1567 | Used in the translation of OrderBy |
||
1568 | </summary> |
||
1569 | <param name="orderByClause">The SqlBuilder to which the sort keys should be appended</param> |
||
1570 | <param name="sortKeys"></param> |
||
1571 | </member> |
||
1572 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.CreateNewSelectStatement(System.Data.SQLite.Linq.SqlSelectStatement,System.String,System.Data.Metadata.Edm.TypeUsage,System.Data.SQLite.Linq.Symbol@)"> |
||
1573 | <summary> |
||
1574 | <see cref="M:System.Data.SQLite.Linq.SqlGenerator.CreateNewSelectStatement(System.Data.SQLite.Linq.SqlSelectStatement,System.String,System.Data.Metadata.Edm.TypeUsage,System.Boolean,System.Data.SQLite.Linq.Symbol@)"/> |
||
1575 | </summary> |
||
1576 | <param name="oldStatement"></param> |
||
1577 | <param name="inputVarName"></param> |
||
1578 | <param name="inputVarType"></param> |
||
1579 | <param name="fromSymbol"></param> |
||
1580 | <returns>A new select statement, with the old one as the from clause.</returns> |
||
1581 | </member> |
||
1582 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.CreateNewSelectStatement(System.Data.SQLite.Linq.SqlSelectStatement,System.String,System.Data.Metadata.Edm.TypeUsage,System.Boolean,System.Data.SQLite.Linq.Symbol@)"> |
||
1583 | <summary> |
||
1584 | This is called after a relational node's input has been visited, and the |
||
1585 | input's sql statement cannot be reused. <see cref="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbProjectExpression)"/> |
||
1586 | |||
1587 | When the input's sql statement cannot be reused, we create a new sql |
||
1588 | statement, with the old one as the from clause of the new statement. |
||
1589 | |||
1590 | The old statement must be completed i.e. if it has an empty select list, |
||
1591 | the list of columns must be projected out. |
||
1592 | |||
1593 | If the old statement being completed has a join symbol as its from extent, |
||
1594 | the new statement must have a clone of the join symbol as its extent. |
||
1595 | We cannot reuse the old symbol, but the new select statement must behave |
||
1596 | as though it is working over the "join" record. |
||
1597 | </summary> |
||
1598 | <param name="oldStatement"></param> |
||
1599 | <param name="inputVarName"></param> |
||
1600 | <param name="inputVarType"></param> |
||
1601 | <param name="finalizeOldStatement"></param> |
||
1602 | <param name="fromSymbol"></param> |
||
1603 | <returns>A new select statement, with the old one as the from clause.</returns> |
||
1604 | </member> |
||
1605 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.NeedSingleQuotes(System.Data.SQLite.SQLiteDateFormats)"> |
||
1606 | <summary> |
||
1607 | Determines if values of the specified <see cref="T:System.Data.SQLite.SQLiteDateFormats"/> |
||
1608 | require wrapping in single quotes. |
||
1609 | </summary> |
||
1610 | <param name="format"> |
||
1611 | The <see cref="T:System.Data.SQLite.SQLiteDateFormats"/> format. |
||
1612 | </param> |
||
1613 | <returns> |
||
1614 | Non-zero if single quotes are required for a value in the specified |
||
1615 | <see cref="T:System.Data.SQLite.SQLiteDateFormats"/>. |
||
1616 | </returns> |
||
1617 | </member> |
||
1618 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.EscapeSingleQuote(System.String,System.Boolean)"> |
||
1619 | <summary> |
||
1620 | Before we embed a string literal in a SQL string, we should |
||
1621 | convert all ' to '', and enclose the whole string in single quotes. |
||
1622 | </summary> |
||
1623 | <param name="s"></param> |
||
1624 | <param name="isUnicode"></param> |
||
1625 | <returns>The escaped sql string.</returns> |
||
1626 | </member> |
||
1627 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.GetSqlPrimitiveType(System.Data.Metadata.Edm.TypeUsage)"> |
||
1628 | <summary> |
||
1629 | Returns the sql primitive/native type name. |
||
1630 | It will include size, precision or scale depending on type information present in the |
||
1631 | type facets |
||
1632 | </summary> |
||
1633 | <param name="type"></param> |
||
1634 | <returns></returns> |
||
1635 | </member> |
||
1636 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.HandleCountExpression(System.Data.Common.CommandTrees.DbExpression)"> |
||
1637 | <summary> |
||
1638 | Handles the expression represending DbLimitExpression.Limit and DbSkipExpression.Count. |
||
1639 | If it is a constant expression, it simply does to string thus avoiding casting it to the specific value |
||
1640 | (which would be done if <see cref="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbConstantExpression)"/> is called) |
||
1641 | </summary> |
||
1642 | <param name="e"></param> |
||
1643 | <returns></returns> |
||
1644 | </member> |
||
1645 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.IsApplyExpression(System.Data.Common.CommandTrees.DbExpression)"> |
||
1646 | <summary> |
||
1647 | This is used to determine if a particular expression is an Apply operation. |
||
1648 | This is only the case when the DbExpressionKind is CrossApply or OuterApply. |
||
1649 | </summary> |
||
1650 | <param name="e"></param> |
||
1651 | <returns></returns> |
||
1652 | </member> |
||
1653 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.IsJoinExpression(System.Data.Common.CommandTrees.DbExpression)"> |
||
1654 | <summary> |
||
1655 | This is used to determine if a particular expression is a Join operation. |
||
1656 | This is true for DbCrossJoinExpression and DbJoinExpression, the |
||
1657 | latter of which may have one of several different ExpressionKinds. |
||
1658 | </summary> |
||
1659 | <param name="e"></param> |
||
1660 | <returns></returns> |
||
1661 | </member> |
||
1662 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.IsComplexExpression(System.Data.Common.CommandTrees.DbExpression)"> |
||
1663 | <summary> |
||
1664 | This is used to determine if a calling expression needs to place |
||
1665 | round brackets around the translation of the expression e. |
||
1666 | |||
1667 | Constants, parameters and properties do not require brackets, |
||
1668 | everything else does. |
||
1669 | </summary> |
||
1670 | <param name="e"></param> |
||
1671 | <returns>true, if the expression needs brackets </returns> |
||
1672 | </member> |
||
1673 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.IsCompatible(System.Data.SQLite.Linq.SqlSelectStatement,System.Data.Common.CommandTrees.DbExpressionKind)"> |
||
1674 | <summary> |
||
1675 | Determine if the owner expression can add its unique sql to the input's |
||
1676 | SqlSelectStatement |
||
1677 | </summary> |
||
1678 | <param name="result">The SqlSelectStatement of the input to the relational node.</param> |
||
1679 | <param name="expressionKind">The kind of the expression node(not the input's)</param> |
||
1680 | <returns></returns> |
||
1681 | </member> |
||
1682 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.QuoteIdentifier(System.String)"> |
||
1683 | <summary> |
||
1684 | We use the normal box quotes for SQL server. We do not deal with ANSI quotes |
||
1685 | i.e. double quotes. |
||
1686 | </summary> |
||
1687 | <param name="name"></param> |
||
1688 | <returns></returns> |
||
1689 | </member> |
||
1690 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.VisitExpressionEnsureSqlStatement(System.Data.Common.CommandTrees.DbExpression)"> |
||
1691 | <summary> |
||
1692 | Simply calls <see cref="M:System.Data.SQLite.Linq.SqlGenerator.VisitExpressionEnsureSqlStatement(System.Data.Common.CommandTrees.DbExpression,System.Boolean)"/> |
||
1693 | with addDefaultColumns set to true |
||
1694 | </summary> |
||
1695 | <param name="e"></param> |
||
1696 | <returns></returns> |
||
1697 | </member> |
||
1698 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.VisitExpressionEnsureSqlStatement(System.Data.Common.CommandTrees.DbExpression,System.Boolean)"> |
||
1699 | <summary> |
||
1700 | This is called from <see cref="M:System.Data.SQLite.Linq.SqlGenerator.GenerateSql(System.Data.Common.CommandTrees.DbQueryCommandTree)"/> and nodes which require a |
||
1701 | select statement as an argument e.g. <see cref="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbIsEmptyExpression)"/>, |
||
1702 | <see cref="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbUnionAllExpression)"/>. |
||
1703 | |||
1704 | SqlGenerator needs its child to have a proper alias if the child is |
||
1705 | just an extent or a join. |
||
1706 | |||
1707 | The normal relational nodes result in complete valid SQL statements. |
||
1708 | For the rest, we need to treat them as there was a dummy |
||
1709 | <code> |
||
1710 | -- originally {expression} |
||
1711 | -- change that to |
||
1712 | SELECT * |
||
1713 | FROM {expression} as c |
||
1714 | </code> |
||
1715 | |||
1716 | DbLimitExpression needs to start the statement but not add the default columns |
||
1717 | </summary> |
||
1718 | <param name="e"></param> |
||
1719 | <param name="addDefaultColumns"></param> |
||
1720 | <returns></returns> |
||
1721 | </member> |
||
1722 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.VisitFilterExpression(System.Data.Common.CommandTrees.DbExpressionBinding,System.Data.Common.CommandTrees.DbExpression,System.Boolean)"> |
||
1723 | <summary> |
||
1724 | This method is called by <see cref="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbFilterExpression)"/> and |
||
1725 | <see cref="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbQuantifierExpression)"/> |
||
1726 | |||
1727 | </summary> |
||
1728 | <param name="input"></param> |
||
1729 | <param name="predicate"></param> |
||
1730 | <param name="negatePredicate">This is passed from <see cref="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbQuantifierExpression)"/> |
||
1731 | in the All(...) case.</param> |
||
1732 | <returns></returns> |
||
1733 | </member> |
||
1734 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.WrapNonQueryExtent(System.Data.SQLite.Linq.SqlSelectStatement,System.Data.SQLite.Linq.ISqlFragment,System.Data.Common.CommandTrees.DbExpressionKind)"> |
||
1735 | <summary> |
||
1736 | If the sql fragment for an input expression is not a SqlSelect statement |
||
1737 | or other acceptable form (e.g. an extent as a SqlBuilder), we need |
||
1738 | to wrap it in a form acceptable in a FROM clause. These are |
||
1739 | primarily the |
||
1740 | <list type="bullet"> |
||
1741 | <item>The set operation expressions - union all, intersect, except</item> |
||
1742 | <item>TVFs, which are conceptually similar to tables</item> |
||
1743 | </list> |
||
1744 | </summary> |
||
1745 | <param name="result"></param> |
||
1746 | <param name="sqlFragment"></param> |
||
1747 | <param name="expressionKind"></param> |
||
1748 | </member> |
||
1749 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.IsBuiltinFunction(System.Data.Metadata.Edm.EdmFunction)"> |
||
1750 | <summary> |
||
1751 | Is this a builtin function (ie) does it have the builtinAttribute specified? |
||
1752 | </summary> |
||
1753 | <param name="function"></param> |
||
1754 | <returns></returns> |
||
1755 | </member> |
||
1756 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.WriteFunctionName(System.Data.SQLite.Linq.SqlBuilder,System.Data.Metadata.Edm.EdmFunction)"> |
||
1757 | <summary> |
||
1758 | |||
1759 | </summary> |
||
1760 | <param name="function"></param> |
||
1761 | <param name="result"></param> |
||
1762 | </member> |
||
1763 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.ToBlobLiteral(System.Byte[],System.Data.SQLite.Linq.SqlBuilder)"> |
||
1764 | <summary> |
||
1765 | Appends the literal BLOB string representation of the specified |
||
1766 | byte array to the <see cref="T:System.Data.SQLite.Linq.SqlBuilder"/>. |
||
1767 | </summary> |
||
1768 | <param name="bytes"> |
||
1769 | The byte array to be formatted as a literal BLOB string. |
||
1770 | </param> |
||
1771 | <param name="builder"> |
||
1772 | The <see cref="T:System.Data.SQLite.Linq.SqlBuilder"/> object to use. If null, an exception |
||
1773 | will be thrown. |
||
1774 | </param> |
||
1775 | </member> |
||
1776 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.NeedsInnerQuery(System.Collections.Generic.IList{System.Data.Common.CommandTrees.DbAggregate})"> |
||
1777 | <summary> |
||
1778 | Helper method for the Group By visitor |
||
1779 | Returns true if at least one of the aggregates in the given list |
||
1780 | has an argument that is not a <see cref="T:System.Data.Common.CommandTrees.DbPropertyExpression"/> |
||
1781 | over <see cref="T:System.Data.Common.CommandTrees.DbVariableReferenceExpression"/> |
||
1782 | </summary> |
||
1783 | <param name="aggregates"></param> |
||
1784 | <returns></returns> |
||
1785 | </member> |
||
1786 | <member name="M:System.Data.SQLite.Linq.SqlGenerator.IsPropertyOverVarRef(System.Data.Common.CommandTrees.DbExpression)"> |
||
1787 | <summary> |
||
1788 | Determines whether the given expression is a <see cref="T:System.Data.Common.CommandTrees.DbPropertyExpression"/> |
||
1789 | over <see cref="T:System.Data.Common.CommandTrees.DbVariableReferenceExpression"/> |
||
1790 | </summary> |
||
1791 | <param name="expression"></param> |
||
1792 | <returns></returns> |
||
1793 | </member> |
||
1794 | <member name="P:System.Data.SQLite.Linq.SqlGenerator.CurrentSelectStatement"> |
||
1795 | <summary> |
||
1796 | The top of the stack |
||
1797 | </summary> |
||
1798 | </member> |
||
1799 | <member name="P:System.Data.SQLite.Linq.SqlGenerator.IsParentAJoin"> |
||
1800 | <summary> |
||
1801 | The top of the stack |
||
1802 | </summary> |
||
1803 | </member> |
||
1804 | <member name="T:System.Data.SQLite.Linq.SqlSelectStatement"> |
||
1805 | <summary> |
||
1806 | A SqlSelectStatement represents a canonical SQL SELECT statement. |
||
1807 | It has fields for the 5 main clauses |
||
1808 | <list type="number"> |
||
1809 | <item>SELECT</item> |
||
1810 | <item>FROM</item> |
||
1811 | <item>WHERE</item> |
||
1812 | <item>GROUP BY</item> |
||
1813 | <item>ORDER BY</item> |
||
1814 | </list> |
||
1815 | We do not have HAVING, since it does not correspond to anything in the DbCommandTree. |
||
1816 | Each of the fields is a SqlBuilder, so we can keep appending SQL strings |
||
1817 | or other fragments to build up the clause. |
||
1818 | |||
1819 | We have a IsDistinct property to indicate that we want distict columns. |
||
1820 | This is given out of band, since the input expression to the select clause |
||
1821 | may already have some columns projected out, and we use append-only SqlBuilders. |
||
1822 | The DISTINCT is inserted when we finally write the object into a string. |
||
1823 | |||
1824 | Also, we have a Top property, which is non-null if the number of results should |
||
1825 | be limited to certain number. It is given out of band for the same reasons as DISTINCT. |
||
1826 | |||
1827 | The FromExtents contains the list of inputs in use for the select statement. |
||
1828 | There is usually just one element in this - Select statements for joins may |
||
1829 | temporarily have more than one. |
||
1830 | |||
1831 | If the select statement is created by a Join node, we maintain a list of |
||
1832 | all the extents that have been flattened in the join in AllJoinExtents |
||
1833 | <example> |
||
1834 | in J(j1= J(a,b), c) |
||
1835 | FromExtents has 2 nodes JoinSymbol(name=j1, ...) and Symbol(name=c) |
||
1836 | AllJoinExtents has 3 nodes Symbol(name=a), Symbol(name=b), Symbol(name=c) |
||
1837 | </example> |
||
1838 | |||
1839 | If any expression in the non-FROM clause refers to an extent in a higher scope, |
||
1840 | we add that extent to the OuterExtents list. This list denotes the list |
||
1841 | of extent aliases that may collide with the aliases used in this select statement. |
||
1842 | It is set by <see cref="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbVariableReferenceExpression)"/>. |
||
1843 | An extent is an outer extent if it is not one of the FromExtents. |
||
1844 | |||
1845 | |||
1846 | </summary> |
||
1847 | </member> |
||
1848 | <member name="M:System.Data.SQLite.Linq.SqlSelectStatement.HaveOrderByLimitOrOffset"> |
||
1849 | <summary> |
||
1850 | Checks if the statement has an ORDER BY, LIMIT, or OFFSET clause. |
||
1851 | </summary> |
||
1852 | <returns> |
||
1853 | Non-zero if there is an ORDER BY, LIMIT, or OFFSET clause; |
||
1854 | otherwise, zero. |
||
1855 | </returns> |
||
1856 | </member> |
||
1857 | <member name="M:System.Data.SQLite.Linq.SqlSelectStatement.WriteSql(System.Data.SQLite.Linq.SqlWriter,System.Data.SQLite.Linq.SqlGenerator)"> |
||
1858 | <summary> |
||
1859 | Write out a SQL select statement as a string. |
||
1860 | We have to |
||
1861 | <list type="number"> |
||
1862 | <item>Check whether the aliases extents we use in this statement have |
||
1863 | to be renamed. |
||
1864 | We first create a list of all the aliases used by the outer extents. |
||
1865 | For each of the FromExtents( or AllJoinExtents if it is non-null), |
||
1866 | rename it if it collides with the previous list. |
||
1867 | </item> |
||
1868 | <item>Write each of the clauses (if it exists) as a string</item> |
||
1869 | </list> |
||
1870 | </summary> |
||
1871 | <param name="writer"></param> |
||
1872 | <param name="sqlGenerator"></param> |
||
1873 | </member> |
||
1874 | <member name="P:System.Data.SQLite.Linq.SqlSelectStatement.IsDistinct"> |
||
1875 | <summary> |
||
1876 | Do we need to add a DISTINCT at the beginning of the SELECT |
||
1877 | </summary> |
||
1878 | </member> |
||
1879 | <member name="T:System.Data.SQLite.Linq.SqlWriter"> |
||
1880 | <summary> |
||
1881 | This extends StringWriter primarily to add the ability to add an indent |
||
1882 | to each line that is written out. |
||
1883 | </summary> |
||
1884 | </member> |
||
1885 | <member name="M:System.Data.SQLite.Linq.SqlWriter.#ctor(System.Text.StringBuilder)"> |
||
1886 | <summary> |
||
1887 | |||
1888 | </summary> |
||
1889 | <param name="b"></param> |
||
1890 | </member> |
||
1891 | <member name="M:System.Data.SQLite.Linq.SqlWriter.Write(System.String)"> |
||
1892 | <summary> |
||
1893 | Reset atBeginningofLine if we detect the newline string. |
||
1894 | <see cref="M:System.Data.SQLite.Linq.SqlBuilder.AppendLine"/> |
||
1895 | Add as many tabs as the value of indent if we are at the |
||
1896 | beginning of a line. |
||
1897 | </summary> |
||
1898 | <param name="value"></param> |
||
1899 | </member> |
||
1900 | <member name="M:System.Data.SQLite.Linq.SqlWriter.WriteLine"> |
||
1901 | <summary> |
||
1902 | |||
1903 | </summary> |
||
1904 | </member> |
||
1905 | <member name="P:System.Data.SQLite.Linq.SqlWriter.Indent"> |
||
1906 | <summary> |
||
1907 | The number of tabs to be added at the beginning of each new line. |
||
1908 | </summary> |
||
1909 | </member> |
||
1910 | <member name="T:System.Data.SQLite.Linq.SymbolPair"> |
||
1911 | <summary> |
||
1912 | The SymbolPair exists to solve the record flattening problem. |
||
1913 | <see cref="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbPropertyExpression)"/> |
||
1914 | Consider a property expression D(v, "j3.j2.j1.a.x") |
||
1915 | where v is a VarRef, j1, j2, j3 are joins, a is an extent and x is a columns. |
||
1916 | This has to be translated eventually into {j'}.{x'} |
||
1917 | |||
1918 | The source field represents the outermost SqlStatement representing a join |
||
1919 | expression (say j2) - this is always a Join symbol. |
||
1920 | |||
1921 | The column field keeps moving from one join symbol to the next, until it |
||
1922 | stops at a non-join symbol. |
||
1923 | |||
1924 | This is returned by <see cref="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbPropertyExpression)"/>, |
||
1925 | but never makes it into a SqlBuilder. |
||
1926 | </summary> |
||
1927 | </member> |
||
1928 | <member name="T:System.Data.SQLite.Linq.SymbolTable"> |
||
1929 | <summary> |
||
1930 | The symbol table is quite primitive - it is a stack with a new entry for |
||
1931 | each scope. Lookups search from the top of the stack to the bottom, until |
||
1932 | an entry is found. |
||
1933 | |||
1934 | The symbols are of the following kinds |
||
1935 | <list type="bullet"> |
||
1936 | <item><see cref="T:System.Data.SQLite.Linq.Symbol"/> represents tables (extents/nested selects/unnests)</item> |
||
1937 | <item><see cref="T:System.Data.SQLite.Linq.JoinSymbol"/> represents Join nodes</item> |
||
1938 | <item><see cref="T:System.Data.SQLite.Linq.Symbol"/> columns.</item> |
||
1939 | </list> |
||
1940 | |||
1941 | Symbols represent names <see cref="M:System.Data.SQLite.Linq.SqlGenerator.Visit(System.Data.Common.CommandTrees.DbVariableReferenceExpression)"/> to be resolved, |
||
1942 | or things to be renamed. |
||
1943 | </summary> |
||
1944 | </member> |
||
1945 | <member name="T:System.Data.SQLite.Linq.TopClause"> |
||
1946 | <summary> |
||
1947 | TopClause represents the a TOP expression in a SqlSelectStatement. |
||
1948 | It has a count property, which indicates how many TOP rows should be selected and a |
||
1949 | boolen WithTies property. |
||
1950 | </summary> |
||
1951 | </member> |
||
1952 | <member name="M:System.Data.SQLite.Linq.TopClause.#ctor(System.Data.SQLite.Linq.ISqlFragment,System.Boolean)"> |
||
1953 | <summary> |
||
1954 | Creates a TopClause with the given topCount and withTies. |
||
1955 | </summary> |
||
1956 | <param name="topCount"></param> |
||
1957 | <param name="withTies"></param> |
||
1958 | </member> |
||
1959 | <member name="M:System.Data.SQLite.Linq.TopClause.#ctor(System.Int32,System.Boolean)"> |
||
1960 | <summary> |
||
1961 | Creates a TopClause with the given topCount and withTies. |
||
1962 | </summary> |
||
1963 | <param name="topCount"></param> |
||
1964 | <param name="withTies"></param> |
||
1965 | </member> |
||
1966 | <member name="M:System.Data.SQLite.Linq.TopClause.WriteSql(System.Data.SQLite.Linq.SqlWriter,System.Data.SQLite.Linq.SqlGenerator)"> |
||
1967 | <summary> |
||
1968 | Write out the TOP part of sql select statement |
||
1969 | It basically writes LIMIT (X). |
||
1970 | </summary> |
||
1971 | <param name="writer"></param> |
||
1972 | <param name="sqlGenerator"></param> |
||
1973 | </member> |
||
1974 | <member name="P:System.Data.SQLite.Linq.TopClause.WithTies"> |
||
1975 | <summary> |
||
1976 | Do we need to add a WITH_TIES to the top statement |
||
1977 | </summary> |
||
1978 | </member> |
||
1979 | <member name="P:System.Data.SQLite.Linq.TopClause.TopCount"> |
||
1980 | <summary> |
||
1981 | How many top rows should be selected. |
||
1982 | </summary> |
||
1983 | </member> |
||
1984 | <member name="T:System.Data.SQLite.Linq.SQLiteProviderFactory"> |
||
1985 | <summary> |
||
1986 | SQLite implementation of <see cref="T:System.Data.Common.DbProviderFactory"/>. |
||
1987 | </summary> |
||
1988 | </member> |
||
1989 | <member name="F:System.Data.SQLite.Linq.SQLiteProviderFactory.Instance"> |
||
1990 | <summary> |
||
1991 | Static instance member which returns an instanced |
||
1992 | <see cref="T:System.Data.SQLite.Linq.SQLiteProviderFactory"/> class. |
||
1993 | </summary> |
||
1994 | </member> |
||
1995 | <member name="M:System.Data.SQLite.Linq.SQLiteProviderFactory.#ctor"> |
||
1996 | <summary> |
||
1997 | Constructs a new instance. |
||
1998 | </summary> |
||
1999 | </member> |
||
2000 | <member name="M:System.Data.SQLite.Linq.SQLiteProviderFactory.CreateCommand"> |
||
2001 | <summary> |
||
2002 | Creates and returns a new <see cref="T:System.Data.SQLite.SQLiteCommand"/> object. |
||
2003 | </summary> |
||
2004 | <returns>The new object.</returns> |
||
2005 | </member> |
||
2006 | <member name="M:System.Data.SQLite.Linq.SQLiteProviderFactory.CreateCommandBuilder"> |
||
2007 | <summary> |
||
2008 | Creates and returns a new <see cref="T:System.Data.SQLite.SQLiteCommandBuilder"/> object. |
||
2009 | </summary> |
||
2010 | <returns>The new object.</returns> |
||
2011 | </member> |
||
2012 | <member name="M:System.Data.SQLite.Linq.SQLiteProviderFactory.CreateConnection"> |
||
2013 | <summary> |
||
2014 | Creates and returns a new <see cref="T:System.Data.SQLite.SQLiteConnection"/> object. |
||
2015 | </summary> |
||
2016 | <returns>The new object.</returns> |
||
2017 | </member> |
||
2018 | <member name="M:System.Data.SQLite.Linq.SQLiteProviderFactory.CreateConnectionStringBuilder"> |
||
2019 | <summary> |
||
2020 | Creates and returns a new <see cref="T:System.Data.SQLite.SQLiteConnectionStringBuilder"/> |
||
2021 | object. |
||
2022 | </summary> |
||
2023 | <returns>The new object.</returns> |
||
2024 | </member> |
||
2025 | <member name="M:System.Data.SQLite.Linq.SQLiteProviderFactory.CreateDataAdapter"> |
||
2026 | <summary> |
||
2027 | Creates and returns a new <see cref="T:System.Data.SQLite.SQLiteDataAdapter"/> object. |
||
2028 | </summary> |
||
2029 | <returns>The new object.</returns> |
||
2030 | </member> |
||
2031 | <member name="M:System.Data.SQLite.Linq.SQLiteProviderFactory.CreateParameter"> |
||
2032 | <summary> |
||
2033 | Creates and returns a new <see cref="T:System.Data.SQLite.SQLiteParameter"/> object. |
||
2034 | </summary> |
||
2035 | <returns>The new object.</returns> |
||
2036 | </member> |
||
2037 | <member name="M:System.Data.SQLite.Linq.SQLiteProviderFactory.GetService(System.Type)"> |
||
2038 | <summary> |
||
2039 | Gets the service object of the specified type. |
||
2040 | </summary> |
||
2041 | <param name="serviceType"> |
||
2042 | An object that specifies the type of service object to get. |
||
2043 | </param> |
||
2044 | <returns> |
||
2045 | A service object of type serviceType -OR- a null reference if |
||
2046 | there is no service object of type serviceType. |
||
2047 | </returns> |
||
2048 | </member> |
||
2049 | <member name="T:System.Data.SQLite.Linq.SQLiteProviderManifest"> |
||
2050 | <summary> |
||
2051 | The Provider Manifest for SQL Server |
||
2052 | </summary> |
||
2053 | </member> |
||
2054 | <member name="M:System.Data.SQLite.Linq.SQLiteProviderManifest.#ctor(System.String)"> |
||
2055 | <summary> |
||
2056 | Constructs the provider manifest. |
||
2057 | </summary> |
||
2058 | <remarks> |
||
2059 | Previously, the manifest token was interpreted as a <see cref="T:System.Data.SQLite.SQLiteDateFormats"/>, |
||
2060 | because the <see cref="T:System.DateTime"/> functions are vastly different depending on the |
||
2061 | connection was opened. However, the manifest token may specify a connection string |
||
2062 | instead. WARNING: Only the "DateTimeFormat", "DateTimeKind", "DateTimeFormatString", |
||
2063 | and "BinaryGUID" connection parameters are extracted from it. All other connection |
||
2064 | parameters, if any are present, are silently ignored. |
||
2065 | </remarks> |
||
2066 | <param name="manifestToken"> |
||
2067 | A token used to infer the capabilities of the store. |
||
2068 | </param> |
||
2069 | </member> |
||
2070 | <member name="M:System.Data.SQLite.Linq.SQLiteProviderManifest.GetProviderManifestToken(System.String)"> |
||
2071 | <summary> |
||
2072 | Determines and returns the effective provider manifest token to use, |
||
2073 | based on the specified provider manifest token and the environment, |
||
2074 | if applicable. |
||
2075 | </summary> |
||
2076 | <param name="manifestToken"> |
||
2077 | The original provider manifest token passed to the constructor for this |
||
2078 | class. |
||
2079 | </param> |
||
2080 | <returns> |
||
2081 | The effective provider manifest token. |
||
2082 | </returns> |
||
2083 | </member> |
||
2084 | <member name="M:System.Data.SQLite.Linq.SQLiteProviderManifest.ParseProviderManifestToken(System.String)"> |
||
2085 | <summary> |
||
2086 | Attempts to parse a provider manifest token. It must contain either a |
||
2087 | legacy string that specifies the <see cref="T:System.Data.SQLite.SQLiteDateFormats"/> value |
||
2088 | -OR- string that uses the standard connection string syntax; otherwise, |
||
2089 | the results are undefined. |
||
2090 | </summary> |
||
2091 | <param name="manifestToken"> |
||
2092 | The manifest token to parse. |
||
2093 | </param> |
||
2094 | <returns> |
||
2095 | The dictionary containing the connection string parameters. |
||
2096 | </returns> |
||
2097 | </member> |
||
2098 | <member name="M:System.Data.SQLite.Linq.SQLiteProviderManifest.SetFromOptions(System.Collections.Generic.SortedList{System.String,System.String})"> |
||
2099 | <summary> |
||
2100 | Attempts to set the provider manifest options from the specified |
||
2101 | connection string parameters. An exception may be thrown if one |
||
2102 | or more of the connection string parameter values do not conform |
||
2103 | to the expected type. |
||
2104 | </summary> |
||
2105 | <param name="opts"> |
||
2106 | The dictionary containing the connection string parameters. |
||
2107 | </param> |
||
2108 | </member> |
||
2109 | <member name="M:System.Data.SQLite.Linq.SQLiteProviderManifest.GetDbInformation(System.String)"> |
||
2110 | <summary> |
||
2111 | Returns manifest information for the provider |
||
2112 | </summary> |
||
2113 | <param name="informationType">The name of the information to be retrieved.</param> |
||
2114 | <returns>An XmlReader at the begining of the information requested.</returns> |
||
2115 | </member> |
||
2116 | <member name="M:System.Data.SQLite.Linq.SQLiteProviderManifest.GetEdmType(System.Data.Metadata.Edm.TypeUsage)"> |
||
2117 | <summary> |
||
2118 | This method takes a type and a set of facets and returns the best mapped equivalent type |
||
2119 | in EDM. |
||
2120 | </summary> |
||
2121 | <param name="storeType">A TypeUsage encapsulating a store type and a set of facets</param> |
||
2122 | <returns>A TypeUsage encapsulating an EDM type and a set of facets</returns> |
||
2123 | </member> |
||
2124 | <member name="M:System.Data.SQLite.Linq.SQLiteProviderManifest.GetStoreType(System.Data.Metadata.Edm.TypeUsage)"> |
||
2125 | <summary> |
||
2126 | This method takes a type and a set of facets and returns the best mapped equivalent type |
||
2127 | </summary> |
||
2128 | <param name="edmType">A TypeUsage encapsulating an EDM type and a set of facets</param> |
||
2129 | <returns>A TypeUsage encapsulating a store type and a set of facets</returns> |
||
2130 | </member> |
||
2131 | <member name="M:System.Data.SQLite.Linq.SQLiteProviderServices.CreateSqlParameter(System.Data.SQLite.Linq.SQLiteProviderManifest,System.String,System.Data.Metadata.Edm.TypeUsage,System.Data.Metadata.Edm.ParameterMode,System.Object)"> |
||
2132 | <summary> |
||
2133 | Creates a SQLiteParameter given a name, type, and direction |
||
2134 | </summary> |
||
2135 | </member> |
||
2136 | <member name="M:System.Data.SQLite.Linq.SQLiteProviderServices.GetSqlDbType(System.Data.Metadata.Edm.TypeUsage,System.Boolean,System.Nullable{System.Int32}@)"> |
||
2137 | <summary> |
||
2138 | Determines DbType for the given primitive type. Extracts facet |
||
2139 | information as well. |
||
2140 | </summary> |
||
2141 | </member> |
||
2142 | <member name="M:System.Data.SQLite.Linq.SQLiteProviderServices.GetParameterSize(System.Data.Metadata.Edm.TypeUsage,System.Boolean)"> |
||
2143 | <summary> |
||
2144 | Determines preferred value for SqlParameter.Size. Returns null |
||
2145 | where there is no preference. |
||
2146 | </summary> |
||
2147 | </member> |
||
2148 | <member name="M:System.Data.SQLite.Linq.SQLiteProviderServices.GetStringDbType(System.Data.Metadata.Edm.TypeUsage)"> |
||
2149 | <summary> |
||
2150 | Chooses the appropriate DbType for the given string type. |
||
2151 | </summary> |
||
2152 | </member> |
||
2153 | <member name="M:System.Data.SQLite.Linq.SQLiteProviderServices.GetBinaryDbType(System.Data.Metadata.Edm.TypeUsage)"> |
||
2154 | <summary> |
||
2155 | Chooses the appropriate DbType for the given binary type. |
||
2156 | </summary> |
||
2157 | </member> |
||
2158 | <member name="M:System.Data.SQLite.Linq.SQLiteProviderServices.System#Data#SQLite#ISQLiteSchemaExtensions#BuildTempSchema(System.Data.SQLite.SQLiteConnection)"> |
||
2159 | <summary> |
||
2160 | Creates temporary tables on the connection so schema information can be queried |
||
2161 | </summary> |
||
2162 | <remarks> |
||
2163 | There's a lot of work involved in getting schema information out of SQLite, but LINQ expects to |
||
2164 | be able to query on schema tables. Therefore we need to "fake" it by generating temporary tables |
||
2165 | filled with the schema of the current connection. We get away with making this information static |
||
2166 | because schema information seems to always be queried on a new connection object, so the schema is |
||
2167 | always fresh. |
||
2168 | </remarks> |
||
2169 | <param name="cnn">The connection upon which to build the schema tables.</param> |
||
2170 | </member> |
||
2171 | <member name="M:System.Data.SQLite.Linq.SQLiteProviderServices.DataTableToTable(System.Data.SQLite.SQLiteConnection,System.Data.DataTable,System.String)"> |
||
2172 | <summary> |
||
2173 | Turn a datatable into a table in the temporary database for the connection |
||
2174 | </summary> |
||
2175 | <param name="cnn">The connection to make the temporary table in</param> |
||
2176 | <param name="table">The table to write out</param> |
||
2177 | <param name="dest">The temporary table name to write to</param> |
||
2178 | </member> |
||
2179 | </members> |
||
2180 | </doc> |