Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
group pivot table from external source
Hi everyone, I have an excel pivot-table whose source is an external SQ server. I have pulled across all the rows I want, however I want to create new field that groups the "names" variable. Is there a way to create a lookup or something in VBA that will grou the names automatically everytime the data is refreshed? Thanks for your help. Scott -- scottwilson ----------------------------------------------------------------------- scottwilsonx's Profile: http://www.excelforum.com/member.php...fo&userid=1112 View this thread: http://www.excelforum.com/showthread.php?threadid=27152 |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
group pivot table from external source
scottwilsonx wrote ...
Hi everyone, I have an excel pivot-table whose source is an external SQL server. I have pulled across all the rows I want, however I want to create a new field that groups the "names" variable. I'm assuming you have a column named "names" (consider renaming because NAMES is vague and a reserved word for future use in SQL Server). If you have control over the sql, you could simply make [names] the first column in your ORDER BY clause e.g. SELECT MyKeyCol, MyTextCol, Names FROM MyTable ORDER BY Names, MyTextCol ; If you do not have control over the sql (e.g. you only have permissions to run a stored procedure) you could use an ADO recordset and sort by [names] on the client side. Post some more details e.g. sql code, example data, required groupings, etc. Jamie. -- |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Can a pivot table be redirected to an external source? | Excel Worksheet Functions | |||
How do I refresh Pivot Table from an external source ? | Excel Worksheet Functions | |||
Selected Columns to be Used in External Data Source in Pivot Table | Excel Discussion (Misc queries) | |||
Pivot Table Data Source external excel file | Excel Discussion (Misc queries) | |||
Determine the location of an external source of pivot table? | Excel Worksheet Functions |