How do I filter out new records?

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I am attempting to pull book titles from a data feed the first time that they appear. I get a weekly feed, so figured that I could compare this week's feed to last week's feed, and filter out the isbns that were new. I'm not sure how to run a 'and not anything on this whole table' query, though.

Can someone please advise?
 
Link the table with this week's feed to the last week's feed using the ISBN
number. Set the link so that all records from This weeks show but only
matching records from last weeks show. Then in the criteria for this week's
put Is Null. This will only show the new ISBN's

SELECT ThisWeek.ISBN, LastWeek.ISBN
FROM LastWeek RIGHT JOIN ThisWeek ON LastWeek.ISBN = ThisWeek.ISBN
WHERE (((LastWeek.ISBN) Is Null));

iris said:
I am attempting to pull book titles from a data feed the first time that
they appear. I get a weekly feed, so figured that I could compare this
week's feed to last week's feed, and filter out the isbns that were new.
I'm not sure how to run a 'and not anything on this whole table' query,
though.
 
Suzette -- I hate to bother you again, but I'm still not quite sure what you mean. I am in the design view of the query, and link up the two tables with no problem. But I'm not sure what you mean by put 'is null' in this week's criteria. And just linking the tables in that way would get me both the new books AND the ones that were out last week

The fields I have in the output are: isbn, title, author. All of them are coming from this week's table, obviously. But where do I write 'is null.'??

I"m new to all of this and, though i'm sure the SELECT // FROM // WHERE instructions you wrote out would make sense to someone else, i'm not at all sure what they mean....

I really appreciate the help
*iri
 
Hi Iris,

In the QBE (Query by Example) grid, you should see rows with labels such as:

Field:
Table:
Sort:
Show:
Criteria:
or:

Locate the column in the QBE grid, where ISBN is shown in the Field row, and LastWeek is
shown in the Table row. In this same column, click into the Criteria row. Type is null
You should see something like this, as soon as you move out of this cell:

Criteria: Is Null

Try running the query to see if it returns the expected results.

The SELECT // FROM // WHERE instructions that Suzette provided is the language of
relational databases. This is known as Structured Query Language (SQL). To view the SQL
for your query, click on the small black down arrow that you should see in query design
on the leftmost toolbar button. (When you hover your mouse over this button in query
design view, you should see a tooltip that reads: View). The small black arrow allows you
to select "SQL View" instead of the default "Datasheet View". Go ahead and select SQL
View. This opens up the SQL window. It is here that you could have pasted the SQL
statement in from Suzette's first post.

I hope this makes sense! As you further your knowledge about Access, and relational
databases in general, you may want to consider picking up a book called "SQL Queries for
Mere Mortals", written by John Viescas and Mike Hernandez.

Happy Holidays,

Tom

_________________________________


Suzette -- I hate to bother you again, but I'm still not quite sure what you mean. I am
in the design view of the query, and link up the two tables with no problem. But I'm not
sure what you mean by put 'is null' in this week's criteria. And just linking the tables
in that way would get me both the new books AND the ones that were out last week.

The fields I have in the output are: isbn, title, author. All of them are coming from
this week's table, obviously. But where do I write 'is null.'??

I"m new to all of this and, though i'm sure the SELECT // FROM // WHERE instructions you
wrote out would make sense to someone else, i'm not at all sure what they mean.....

I really appreciate the help!
*iris
 
Back
Top