Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.charting
|
|||
|
|||
![]()
i am writing a program in vb.net that uses pivotchart with backend sql
server........i.e.the data is fed into the pivot chart through a query from the sql server........now i want to use my stored porcedure to populate my pivot chart........is there anyways that i will be able to use stored procedure to populate that pivot chart...........is there anyone who can guide me in this regard.. Best Regards Omar_aa |
#2
![]()
Posted to microsoft.public.excel.charting
|
|||
|
|||
![]()
Hi Omar_aa,
i am writing a program in vb.net that uses pivotchart with backend sql server........i.e.the data is fed into the pivot chart through a query from the sql server........now i want to use my stored porcedure to populate my pivot chart........is there anyways that i will be able to use stored procedure to populate that pivot chart...........is there anyone who can guide me in this regard.. Best Regards Omar_aa I don't know how to update an Excel Pivot Chart using a stored procedure. I doubt that there is a SQL command to get Excel to update a Pivot Chart . Of course you can use vb.net to open the Excel workbook and update the pivot chart. Just use the RefreshTable of the PivotTable object in Excel. However, what I normally do is set the Pivot Chart options in Excel to update data on file open. Then you just need to open the workbook and the data will update automatically. Ed Ferrero www.edferrero.com |
#3
![]()
Posted to microsoft.public.excel.charting
|
|||
|
|||
![]()
actually i have allready tried to bind pivot chart with the sql.......and it
is suucessful as long as i use "select * from tablename" but whenever i use the where clause......it returns nothing....secondly i want to make my pivot chart operations fast ......so inorder to do so...... i have to use tp use the stored procedure which i am unable to use bcaz i dun't know how to use it.........so plz help me in this regard........... BR Omar_aa "Ed Ferrero" wrote: Hi Omar_aa, i am writing a program in vb.net that uses pivotchart with backend sql server........i.e.the data is fed into the pivot chart through a query from the sql server........now i want to use my stored porcedure to populate my pivot chart........is there anyways that i will be able to use stored procedure to populate that pivot chart...........is there anyone who can guide me in this regard.. Best Regards Omar_aa I don't know how to update an Excel Pivot Chart using a stored procedure. I doubt that there is a SQL command to get Excel to update a Pivot Chart . Of course you can use vb.net to open the Excel workbook and update the pivot chart. Just use the RefreshTable of the PivotTable object in Excel. However, what I normally do is set the Pivot Chart options in Excel to update data on file open. Then you just need to open the workbook and the data will update automatically. Ed Ferrero www.edferrero.com |
#4
![]()
Posted to microsoft.public.excel.charting
|
|||
|
|||
![]()
Hi Omar,
You should be able to use a WHERE clause with no problems. 1) Are you building the pivot chart from a view in SQL Server? If so, you should be able to write a view with standard SQL. Using Northwind as an example, this selects all cities starting with S from the Orders table; SELECT * FROM dbo.Orders WHERE ShipCity LIKE N'S%' 2) Or, are you using MS query to build a SQL expression that gets data from SQL server? If so, you need to be aware that SQL syntax in MS query is slightly different to T-SQL. SELECT * FROM Northwind.dbo.Orders Orders WHERE ShipCity Like 'S%' As far as using a stored procedure, I repeat that I do not think you can. I know that stored procedures will run a little bit faster than views on SQL Server. But the speed difference should not be very noticeable, unless you are doing something very complex. Speed is far more likely to be influenced by the correct use of indexing. Perhaps you should post a sample of the SQL you are using. Ed Ferrero www.edferrero.com omar_aa wrote; actually i have allready tried to bind pivot chart with the sql.......and it is suucessful as long as i use "select * from tablename" but whenever i use the where clause......it returns nothing....secondly i want to make my pivot chart operations fast ......so inorder to do so...... i have to use tp use the stored procedure which i am unable to use bcaz i dun't know how to use it.........so plz help me in this regard........... BR Omar_aa "Ed Ferrero" wrote: Hi Omar_aa, i am writing a program in vb.net that uses pivotchart with backend sql server........i.e.the data is fed into the pivot chart through a query from the sql server........now i want to use my stored porcedure to populate my pivot chart........is there anyways that i will be able to use stored procedure to populate that pivot chart...........is there anyone who can guide me in this regard.. Best Regards Omar_aa I don't know how to update an Excel Pivot Chart using a stored procedure. I doubt that there is a SQL command to get Excel to update a Pivot Chart . Of course you can use vb.net to open the Excel workbook and update the pivot chart. Just use the RefreshTable of the PivotTable object in Excel. However, what I normally do is set the Pivot Chart options in Excel to update data on file open. Then you just need to open the workbook and the data will update automatically. Ed Ferrero www.edferrero.com |
#5
![]()
Posted to microsoft.public.excel.charting
|
|||
|
|||
![]()
i am not using views........infact i am using simple queries like the one
given below: select * from rc where bid='bid123' i am using the above query to use it........... now plz tell me that how can i use the views in the pivot chart?? "Ed Ferrero" wrote: Hi Omar, You should be able to use a WHERE clause with no problems. 1) Are you building the pivot chart from a view in SQL Server? If so, you should be able to write a view with standard SQL. Using Northwind as an example, this selects all cities starting with S from the Orders table; SELECT * FROM dbo.Orders WHERE ShipCity LIKE N'S%' 2) Or, are you using MS query to build a SQL expression that gets data from SQL server? If so, you need to be aware that SQL syntax in MS query is slightly different to T-SQL. SELECT * FROM Northwind.dbo.Orders Orders WHERE ShipCity Like 'S%' As far as using a stored procedure, I repeat that I do not think you can. I know that stored procedures will run a little bit faster than views on SQL Server. But the speed difference should not be very noticeable, unless you are doing something very complex. Speed is far more likely to be influenced by the correct use of indexing. Perhaps you should post a sample of the SQL you are using. Ed Ferrero www.edferrero.com omar_aa wrote; actually i have allready tried to bind pivot chart with the sql.......and it is suucessful as long as i use "select * from tablename" but whenever i use the where clause......it returns nothing....secondly i want to make my pivot chart operations fast ......so inorder to do so...... i have to use tp use the stored procedure which i am unable to use bcaz i dun't know how to use it.........so plz help me in this regard........... BR Omar_aa "Ed Ferrero" wrote: Hi Omar_aa, i am writing a program in vb.net that uses pivotchart with backend sql server........i.e.the data is fed into the pivot chart through a query from the sql server........now i want to use my stored porcedure to populate my pivot chart........is there anyways that i will be able to use stored procedure to populate that pivot chart...........is there anyone who can guide me in this regard.. Best Regards Omar_aa I don't know how to update an Excel Pivot Chart using a stored procedure. I doubt that there is a SQL command to get Excel to update a Pivot Chart . Of course you can use vb.net to open the Excel workbook and update the pivot chart. Just use the RefreshTable of the PivotTable object in Excel. However, what I normally do is set the Pivot Chart options in Excel to update data on file open. Then you just need to open the workbook and the data will update automatically. Ed Ferrero www.edferrero.com |
#6
![]()
Posted to microsoft.public.excel.charting
|
|||
|
|||
![]()
Hi Omar,
There is nothing wrong with your query. Are you sure that it returns some rows? It should work fine with a pivot chart. Ed Ferrero www.edferrero.com omar_aa wrote; i am not using views........infact i am using simple queries like the one given below: select * from rc where bid='bid123' i am using the above query to use it........... now plz tell me that how can i use the views in the pivot chart?? |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Can I import SQL Stored Procedures into Excel? | Excel Discussion (Misc queries) | |||
How to connect Excel to stored procedures in SQL database? | Excel Discussion (Misc queries) | |||
How to connect Excel to stored procedures in SQL database? | Excel Discussion (Misc queries) | |||
Can't see stored procedures in select data source windows | Excel Discussion (Misc queries) | |||
Running sql stored procedures from Excel | Excel Discussion (Misc queries) |