Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 15
Default I want to have my spreadsheet connect to SQL Server with variables...?

I have this Stored Procdure but don't know how to incorporate variables into
it.
I've added the declare statements and what I think the variables should be
and where I think they should go.
I have an example of the code for Excel, if I can just get these variables
to work....

Any help would be appreciated

Kelvin
++++++++++++++++++++++++++++++++++++++++++++++
set ANSI_NULLS ON
set QUOTED_IDENTIFIER ON
GO

-- CREATE PROCEDURE [dbo].[CIT_SV_TechLaborByRo]
ALTER PROCEDURE [dbo].[CIT_SV_TechLaborByRo]

AS
BEGIN

DECLARE @RoNumber (this would be equal to the [SlsId])
DECLARE @TechID (this would equal [EmpIdLbr])

SELECT SVSLSITM.HrsActual
FROM SVSLSITM

WHERE [SVSLSITM].[SlsId]= @RoNumber
AND [SVSLSITM].[EmpIdLbr]= @TechID;

END
++++++++++++++++++++++++++++++++++++++++++++++


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 98
Default I want to have my spreadsheet connect to SQL Server withvariables...?


No one will be able to understand the code.

Paste the actual code.
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
Connect to SQL Server Johnslg Excel Programming 0 May 29th 08 01:56 PM
Connect to OPC / DDE server Critcho Excel Worksheet Functions 0 December 6th 07 02:18 AM
How can I use VBA to connect to a SQL server? Bed Guy Excel Programming 1 May 29th 07 10:25 PM
connect to an oracle server Bill Li Excel Programming 0 August 14th 03 04:31 AM


All times are GMT +1. The time now is 06:10 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"