Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi Everyone,
Anybody knows how to load data from stored procedure?
I need to load data from sql server Stored Precedure in Qlikview. But each time no data or table loaded without error message.
Connect to sql server OK. The script work fine in sql server client.
I wrote the script like this:
Below is the ending snapshot after finished reloading.
Hi Duo,
Can you check that NOCOUNT is set to ON.
Here is my stored procedure :
USE [testdb]
GO
/****** Object: StoredProcedure [dbo].[get_test_data] Script Date: 07/31/2015 10:55:19 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
-- =============================================
-- Author: <Author,,Name>
-- Create date: <Create Date,,>
-- Description: <Description,,>
-- =============================================
ALTER PROCEDURE [dbo].[get_test_data]
AS
BEGIN
-- SET NOCOUNT ON added to prevent extra result sets from
-- interfering with SELECT statements.
SET NOCOUNT ON;
-- Insert statements for procedure here
SELECT branch from dim_branch
where branch is not null
END
Thanks
Mark
techstuffybooks.com
Hi Duo,
Table:
SQL
EXEC dbo.Store_procedure_Name '120','A';
If doesn't work look this link:
https://community.qlik.com/message/693191#693191
Regards
on SQL Server you need additionally "execute" rights. normally users only get read permissions.
check that please!
Hi Duo,
Silly question.
Does the stored procedure return data when you run it from the management studio ?
Mark
techstuffybooks.com
Yes, there are number of rows.
Thank you.
You mean i need additional rights if i have to execute in qlikview even if i can execute it from sql server management studio already?
Actually, I can execute the script from sql server management studio without any warning or error.
Hi,
Look at link in my post the comment of Normelio Junior.
Regards
no when you can execute it from SQL Server you got the permissions and it should work as well from qlikview
I donot remember what we did when we tried to use a stored procedure (in our case we got no Advantage) but you may define in Settings "open database in read and write mode"
Hi Duo,
Are there any errors\warnings in the sql server error log ?
Thanks
Mark
techstuffybooks.com
Yes i have check "open database in read and write mode" . Thank you.