Web Development

Our forums are currently in maintenance mode and the ability to post is disabled. We will be back up and running as soon as possible. Thanks for your patience!

Question

Locked

SQL in MS Access

By kms_cryswater ·
I am looking for help on a specific SQL query in MS Access. I keep running into syntax errors.

Is there anyone out there that knows Access query?

I am used to straight SQL query via a back-end connection like TOAD, so the restrictions of MS Access have me at a road block.

My SQL code is below and below that is what I would like it to do:

SQL code I am using in query
This is the body of my original query. It works fine, except I would like to customize it with the parameters in the bottom of this reply:

SELECT [Paste SYNETICS PNs Here].SyneticsPN, dbo_resource.description, dbo_resource.user1 AS Extended_Description, dbo_manufacturer.name_of AS MFG_Name, dbo_source_manuf_items.source_manuf_catalog AS MFG_Number
FROM ([Paste SYNETICS PNs Here] LEFT JOIN (dbo_resource LEFT JOIN dbo_source_manuf_items ON dbo_resource.resource_no=dbo_source_manuf_items.resource_no) ON [Paste SYNETICS PNs Here].SyneticsPN=dbo_resource.resource_no) LEFT JOIN dbo_manufacturer ON dbo_source_manuf_items.source_manuf=dbo_manufacturer.id;

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

What I want is when [Paste SYNETICS PNs Here].SyneticsPN is LIKE "%__AB____%" AND dbo_manufacturer.name_of AND/OR dbo_source_manuf_items.source_manuf_catalog IS BLANK (meaning the table has no data to display), then the fields MFG_Name & MFG_Number, in the query [Get SYNETICS PNs Here] (IF EITHER ARE BLANK), need to display the text "ANY"

Thanks!

This conversation is currently closed to new comments.

Thread display: Collapse - | Expand +

All Answers

Share your knowledge

Related Discussions

Related Forums