Click here to Skip to main content
15,910,773 members
Home / Discussions / ASP.NET
   

ASP.NET

 
QuestionPHP or ASP.Net for developing Web based application with SAAS Pin
nilam24772-Jul-10 1:37
nilam24772-Jul-10 1:37 
AnswerRe: PHP or ASP.Net for developing Web based application with SAAS Pin
ahmedel2-Jul-10 7:10
ahmedel2-Jul-10 7:10 
QuestionDotnetNuke Pin
kalit.sikka@gmail.com1-Jul-10 22:27
kalit.sikka@gmail.com1-Jul-10 22:27 
AnswerRe: DotnetNuke Pin
Ankur\m/2-Jul-10 2:35
professionalAnkur\m/2-Jul-10 2:35 
AnswerRe: DotnetNuke Pin
Abhijit Jana2-Jul-10 5:12
professionalAbhijit Jana2-Jul-10 5:12 
QuestionASP.NET C# MCPD Exam (70-562) Pin
Gindi Bar Yahav1-Jul-10 10:18
Gindi Bar Yahav1-Jul-10 10:18 
AnswerRe: ASP.NET C# MCPD Exam (70-562) Pin
dittu74-Jul-10 20:02
dittu74-Jul-10 20:02 
Questioncalling sql ssis package through asp.net Pin
janetb991-Jul-10 7:03
janetb991-Jul-10 7:03 
I've successfully created an xls import (using the wizard) via SSMS and saved it in sql under msdb on the sql server. I'm able to see it and run it via the sql integration services under stored packages/msdb successfully. The import package locates and retrieves the xls file automatically (no variables - it's always saved and named the same)

I'm trying (unsuccessfully) to run the package through asp.net via an sql stored procedure. I've been futzing with it a bit trying different things... nothing working yet, I keep getting at -1. Can anyone help me out? I've read the articles, but I'm a bit lost.

The .net is:
Dim cmd As New Data.SqlClient.SqlCommand("gme.dbo.sp_housingImport", cn)
cmd.Connection.Open()
myReturn = (cmd.ExecuteNonQuery)
Response.Write("myReturn=" & myReturn.ToString)


Stored procedure:
DECLARE @ServerName NVARCHAR(100)
DECLARE @cmd NVARCHAR(4000)
DECLARE @jid UNIQUEIDENTIFIER
DECLARE @jname NVARCHAR(128)
DECLARE @jobName NVARCHAR(128)
DECLARE @FileLocation as varchar(500)

-- Create a unique job name
SET @ServerName = CONVERT(sysname, SERVERPROPERTY(N'myServerName'))
SET @jname = CAST(NEWID() AS CHAR(36))
SET @jobName = @jname
SET @FileLocation = 'E:\\myfolder\excel.xls'

--set the name and location of the ssis package to run.

SET @cmd = '"F:\Program Files\Microsoft SQL Server\90\DTS\Binn\DTExec.exe" '
SET @cmd = @cmd + '/DTS "\MSDB\housingImport" '
SET @cmd = @cmd + '/SERVER ' + @ServerName + ' '
SET @cmd = @cmd + '/CHECKPOINTING OFF '

-- Specify ssis variable value in the package that represents the location of the input file to load
SET @cmd = @cmd + '/SET "\Package.Variables[User::varInputFile].Value";"' + @FileLocation + '" '
-- Create job
EXEC msdb.dbo.sp_add_job
@job_name = @jname,
@enabled = 1,
--@category_name = 'housingImport',
--deletes the job when it is done, regardless of whether or not it was successful
@delete_level = 3,
@job_id = @jid OUTPUT

--Add the job to the Sql Server instance
EXEC msdb.dbo.sp_add_jobserver
@job_id = @jid,
@server_name = '(local)'

--Add the step to the job that invokes the ssis package
EXEC msdb.dbo.sp_add_jobstep
@job_id = @jid,
@step_name = 'Execute DTS',
@subsystem = 'CMDEXEC',
@command = @cmd

-- Start job
EXEC msdb.dbo.sp_start_job @job_id = @jid
AnswerCommand Type Pin
David Mujica1-Jul-10 7:48
David Mujica1-Jul-10 7:48 
GeneralRe: Command Type Pin
janetb991-Jul-10 8:51
janetb991-Jul-10 8:51 
AnswerRe: calling sql ssis package through asp.net Pin
Vimalsoft(Pty) Ltd1-Jul-10 20:09
professionalVimalsoft(Pty) Ltd1-Jul-10 20:09 
GeneralRe: calling sql ssis package through asp.net Pin
janetb992-Jul-10 6:45
janetb992-Jul-10 6:45 
GeneralRe: calling sql ssis package through asp.net Pin
Vimalsoft(Pty) Ltd2-Jul-10 7:20
professionalVimalsoft(Pty) Ltd2-Jul-10 7:20 
Questionwsdl Pin
gerom771-Jul-10 5:21
gerom771-Jul-10 5:21 
AnswerRe: wsdl Pin
Not Active1-Jul-10 5:38
mentorNot Active1-Jul-10 5:38 
GeneralRe: wsdl Pin
gerom771-Jul-10 6:01
gerom771-Jul-10 6:01 
GeneralRe: wsdl Pin
Not Active1-Jul-10 6:44
mentorNot Active1-Jul-10 6:44 
GeneralRe: wsdl Pin
gerom771-Jul-10 7:43
gerom771-Jul-10 7:43 
GeneralRe: wsdl Pin
Not Active1-Jul-10 7:47
mentorNot Active1-Jul-10 7:47 
GeneralRe: wsdl Pin
gerom771-Jul-10 11:43
gerom771-Jul-10 11:43 
GeneralRe: wsdl Pin
Not Active1-Jul-10 12:39
mentorNot Active1-Jul-10 12:39 
Questiondisplay Analog clock Pin
Hemant Thaker1-Jul-10 3:59
Hemant Thaker1-Jul-10 3:59 
AnswerRe: display Analog clock Pin
David Mujica1-Jul-10 4:12
David Mujica1-Jul-10 4:12 
AnswerRe: display Analog clock Pin
Gaurav Dudeja India1-Jul-10 20:15
Gaurav Dudeja India1-Jul-10 20:15 
QuestionNeed help to decide whether to go for ASP.Net Website or PHP Pin
nilam24771-Jul-10 2:33
nilam24771-Jul-10 2:33 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.