Re: [sqlite] How to find records in a table which are not in a second table?

2018-08-28 Thread Jay Kreibich
> On Aug 28, 2018, at 1:22 PM, David Raymond wrote: > > Embarrassing confession time: I didn't think you could use "using" to do this > while selecting "a.*" > > https://www.sqlite.org/lang_select.html > "For each pair of columns identified by a USING clause, the column from the > right-hand

Re: [sqlite] How to find records in a table which are not in a second table?

2018-08-28 Thread R Smith
On 2018/08/28 7:18 PM, Jay Kreibich wrote: On Aug 28, 2018, at 11:30 AM, Joe wrote: A (perhaps silly ) beginners question: My sqlite database contains several tables, two of them, table A and table B, have text colums called 'nam'. The tables have about 2 millions lines. What's the most

Re: [sqlite] How to find records in a table which are not in a second table?

2018-08-28 Thread David Raymond
Embarrassing confession time: I didn't think you could use "using" to do this while selecting "a.*" https://www.sqlite.org/lang_select.html "For each pair of columns identified by a USING clause, the column from the right-hand dataset is omitted from the joined dataset. This is the only

Re: [sqlite] How to find records in a table which are not in a second table?

2018-08-28 Thread Jay Kreibich
> On Aug 28, 2018, at 11:30 AM, Joe wrote: > > A (perhaps silly ) beginners question: > My sqlite database contains several tables, two of them, table A and table B, > have text colums called 'nam'. The tables have about 2 millions lines. > What's the most efficient way to select all lines

Re: [sqlite] How to find records in a table which are not in a second table?

2018-08-28 Thread Simon Slavin
On 28 Aug 2018, at 5:32pm, Richard Hipp wrote: > I suppose: > > SELECT * FROM A WHERE nam NOT IN (SELECT nam FROM B); Depending on how many names the tables have in column, a possible alternative might be to use the EXCEPT compound operator here. Something like SELECT nam FROM A

Re: [sqlite] How to find records in a table which are not in a second table?

2018-08-28 Thread Richard Hipp
On 8/28/18, Joe wrote: > A (perhaps silly ) beginners question: > My sqlite database contains several tables, two of them, table A and > table B, have text colums called 'nam'. The tables have about 2 > millions lines. > What's the most efficient way to select all lines from table A with nam >

[sqlite] How to find records in a table which are not in a second table?

2018-08-28 Thread Joe
A (perhaps silly ) beginners question: My sqlite database contains several tables, two of them, table A and table B,  have text colums called 'nam'. The tables have about 2 millions lines. What's the most efficient way to select all lines from table A with nam values, which are not present in