Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
No Name
 
Posts: n/a
Default SQL "INSERT INTO" Does not Modify Definition of Target Range

I am using MS Excel 2002 to manage financial data.

To add new data to a named range in a spreadsheet, I have
written a query that uses the SQL "INSERT INTO" capability.

Works well, except for two problems. For this Post, the
problem I'm trying to solve is that the update query does
add records to the spreadsheet as expected, but it leaves
the definition of the named range unchanged. E.g.,
suppose that the named range originally covers A1:D35, and
the update query adds 7 records to the spreadsheet. I
would have expected the query to also modify the
definition of the named range to cover A1:D42.

If I perform the same function using the "Execute SQL"
function from inside Microsoft Query, it does modify the
definition of the named range to include the added
records. But I can't use this capability in a macro, or
at least I can't see how to do that.

Any thoughts on how to get my query to automatically
update the definition of the target range to include added
records?

Thanks,
David
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Conditional formatting problem - MS' definition of "between" Elardus Excel Discussion (Misc queries) 9 September 24th 09 08:56 AM
How to insert a "Target" line into basic bar chart keith666 Charts and Charting in Excel 1 October 5th 08 08:00 PM
Lost "File Menu" - now it's "Edit / View / Insert.." but no "F daves Excel Discussion (Misc queries) 3 April 24th 07 04:52 AM
Insert "-" in text "1234567890" to have a output like this"123-456-7890" Alwyn Excel Discussion (Misc queries) 3 October 25th 05 11:36 PM


All times are GMT +1. The time now is 01:30 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"