You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Eliminates secondary table JOIN-only fields from returned DataTable.
Issue: If there's a SELECT * and the raw name of the column isn't what's used in the JOIN, it'll bust.
So if we have `Table1` with `Field1` with a raw name of `Fie` and we try...
SELECT * FROM Table1 INNER JOIN Table2 ON Table1.Field1 = Table2.Id
... it'll error out. You instead have to use...
SELECT * FROM Table1 INNER JOIN Table2 ON Table1.Fie = Table2.Id
... which is awkward.
I think I can fix that reasonably easily for the main table, but it'll be a little more difficult -- or at least potentially horribly inefficient -- for secondary tables. I think.
elseif(qSecondaryTableNames.Any(s =>toke.ToUpper().StartsWith(s.ToUpper()+".")))// TODO: this kinda suggests "." can't be in a table or column name either. Don't think we're checking that.
171
+
{
172
+
this.lstrJoinONLYFields.Add(toke);
173
+
}
174
+
175
+
// TODO: This makes JOIN a pretty hard keyword. I think that's safe, though.
176
+
// If you want a table named JOIN, it'll have to be in brackets, right?
Copy file name to clipboardExpand all lines: README.md
+3-3Lines changed: 3 additions & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -11,7 +11,7 @@
11
11
// ======================== EO LICENSE ===============================
12
12
13
13
14
-
### VERSION 0.0.4.2: Nothing is guaranteed to work. NOTHING. Use at your own risk.
14
+
### VERSION 0.0.4.3: Nothing is guaranteed to work. NOTHING. Use at your own risk.
15
15
16
16
###Usage
17
17
@@ -41,9 +41,9 @@ Step 2: Use the code below *at your own risk*.
41
41
###Mac OS X Notes
42
42
SqlDb# as a library works fine on Xamarin.Mac or MonoMac.
43
43
44
-
**The Isql project**, however, does not echo content entered into a `Console.Read` or `.ReadLine()`, so you can't, for example, see what you're typing in as your SQL statement. I've [filed a bug](https://bugzilla.xamarin.com/show_bug.cgi?id=22262) with Xamarin, but it hasn't gotten much attention. That's somewhat understandable; I haven't been able to make a test case simpler than SqlDb#'s Isql project that exhibits this behavior.
44
+
**The Isql project**, when run on OS X, however, does not echo content entered into a `Console.Read` or `.ReadLine()`, so you can't, for example, see what you're typing in as your SQL statement. I've [filed a bug](https://bugzilla.xamarin.com/show_bug.cgi?id=22262) with Xamarin, but it hasn't gotten much attention. That's somewhat understandable; I haven't been able to make a test case simpler than SqlDb#'s Isql project that exhibits this behavior.
45
45
46
-
To avoid this echo issue when *developing SqlDb#* (not developing *against* or using; again, the library works fine) using MonoMac or Xamarin.Mac, please use the `MacUI` branch (which contains a native UI ISQL client), merge latest from the `master` branch, set `SqlDbSharpMacUI` as your startup project, and use that interface to run queries during development.
46
+
To avoid this echo issue when *developing SqlDb#* (not developing *against* or using; again, the library works fine afaict) using MonoMac or Xamarin.Mac, please use the `MacUI` branch (which contains a native UI ISQL client), merge latest from the `master` branch, set `SqlDbSharpMacUI` as your startup project, and use that interface to run queries during development.
0 commit comments