![]() |
#6
|
||||
|
||||
![]()
If you're using Excel, you shouldn't need the connection string, as the link I pointed you to shows. Assuming the field works when first created, I can't see why it wouldn't also update when refreshed after the Excel data changes. Also, what is the error message? It's a bit hard to diagnose without the error message. That said, based on the workbook attached to your first post, you should be able to use something like:
Code:
{DATABASE \d "W:\\XXXXX\\XXXXX\\Trial MM data RH.xlsx" \s "SELECT `Building`, `Floor`, `Room/Area` FROM `Sheet1$` WHERE `Extent of damage score` = 0 ORDER BY `Sample`" \l "23" \b "191" \h} Code:
{DATABASE \d "{FILENAME \p}/../Trial MM data RH.xlsx" \s "SELECT [Building], [Floor], [Room/Area] FROM [Sheet1$] WHERE [Extent of damage score] = 0 ORDER BY [Sample]" \l "23" \b "191" \h} Note that it doesn't really matter whether you delineate the fields with `` or [].
__________________
Cheers, Paul Edstein [Fmr MS MVP - Word] |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
![]() |
flackend | Mail Merge | 4 | 12-01-2023 02:49 PM |
Using Mail Merge to create summary report in ONE document | ChandaS | Mail Merge | 1 | 12-19-2014 10:16 PM |
![]() |
esherwood | Mail Merge | 1 | 07-21-2014 09:55 PM |
![]() |
elisa2013 | Mail Merge | 5 | 03-14-2014 02:35 AM |
![]() |
risnasmhd | Mail Merge | 1 | 09-29-2013 08:11 PM |