need help on Query

  • Thread starter Thread starter william poh ben
  • Start date Start date
W

william poh ben

Hi,

How can I use "update query" or using "criteria" to filter the field of
PartNumbers that end only with the "W" behind ?

Any help is much appreciated.

An example as below:

PartNumber
33511001
33511001W
1120-60222
1120-60222B
1120-60222W
 
Dear William:

I find myself wondering just what you mean by leaving only the W
behind. Given the sample data, what does the result look like? Do
you want 5 rows of output, 3 which are empty and 2 with W? That
doesn't sound very useful. Do you want just 2 rows of output, showing
the full part number?

This latter sounds more useful. How about:

SELECT * FROM YourTable WHERE PartNumber LIKE "*W"

Tom Ellison
Microsoft Access MVP
Ellison Enterprises - Your One Stop IT Experts
 
Hi Tom,

sorry I didn't explain it clearly.

What happens is I want to filter out a list of PartNumbers that end
with "W" which means they are Warranty parts I intend to keep in a
separate table.

The desired output after filtering should be as below:

PartNumber
33511001W
1120-60222W

How can I do this ?
 
Hi,

Set the WHERE clause to:
Where PartNumber Like "*W"

will also output partNumber such as below which I do not want.


223WASTE-50
1233WSS
ESC-WHeater55

How would I be able to obtain only PartNumbers ending with "W" ?

thanks in advance.
 
Dear William:

You are mistaken about this, I'm sure. If you filter to "*W*" then
you would get the rows where the part number "contains W" but if you
filter to "*W" you will get only those part number that "end with W"

Tom Ellison
Microsoft Access MVP
Ellison Enterprises - Your One Stop IT Experts
 
Hi Tom,

I can't tell you how much I wanted to thank you.
You save me a considerable amount of time at work.

Thanks.
 
Dear William:

It's nice to hear that. It was my intention to do so!

Tom Ellison
Microsoft Access MVP
Ellison Enterprises - Your One Stop IT Experts
 
Back
Top