I have some DTS Shedules on SQL 7.0 SP1 . All shcedule was running properly . When I made some changes in an SQL Task and saved it the shedule starts to fail. It gives me an error "DTS RUN LOAding Error- 2147024809(80070057)Ptovider Error (0) Error String : The parameter is incorrect etc)
But All my DTS is running smoothly without error Only the schedule fails.
Please help me.
I'm having a problem with my SQL 7.0 (SP2) server running on NT4 (SP6a). When I use Enterprise Manager on my NT4 workstation (SP6) and I try to double click a local DTS package to go into the design view I get the following error message:
Error Source: Microsoft Data Transformation Services (DTS) Package Error Description: The parameter is incorrect
If I log on to the actual server and run Enteprise Manager everything is o.k It is not a permissioning problem as I'm logging in with domain Admin in both cases. Any ideas ?
I'm running SqlServer 2000 and am trying to write a DTS. For some reason I keep getting that error for my Dynamic Property Task and not sure why. I've tried giving my Package a password like was mentioned in another thread on here, but that didn't work either.
I'm trying to dynamically set a Data Source for an Excel connected, using a query.
Query:
DECLARE @directory VARCHAR(1000) SET @directory = 'C:' EXEC [Legacy].[dbo].[spr_GetNewestExcel] @directory
The Store Procedure:
CREATE PROCEDURE spr_GetNewestExcel ( @directory VARCHAR(1000) ) AS BEGIN DECLARE @cmdParam VARCHAR(8000)
--Temp Table that saves the output of a DOS command. CREATE TABLE #output ( output VARCHAR(300) )
--Temp Table that saves the output of a "dir" DOS output, in parts. CREATE TABLE #files ( fileDate VARCHAR(20), fileSize VARCHAR(20), fileName VARCHAR(100) )
--Sets the command parameter SET @cmdParam = 'dir "' + @directory + '"'
--Inserts the output of the above DOS command into a table INSERT INTO #output EXEC master..xp_cmdshell @cmdParam
--Parses the #output table for the files with the correct extension and breaks it up into --Date, Size, and Name. INSERT INTO #files SELECT SUBSTRING(output, 0, 21) As fileDate, LTRIM(SUBSTRING(output, 21, 18)) As fileSize, SUBSTRING(output, 40, LEN(output)) FROM #output WHERE output LIKE '%.xls'
--Displays the values SELECT TOP 1 CASE WHEN SUBSTRING(@directory, LEN(@directory), 1) = '' THEN @directory + fileName ELSE @directory + '' + fileName END AS fileName FROM #files ORDER BY fileDate DESC
DROP TABLE #output DROP TABLE #files END
The Stored Procedure runs great on its own, it displays a list of filenames with the .xls extension in the desired directory, which is what I want. It should put the first in the list((if there is more than one)) as the datasource, but it doesn't.
When I go to the "Add/Edit Assignment" window for it, and push "Refresh" to preview it, it gives me a "The Parameter Is Incorrect".
Any help would be much appreciated, this has had me stumped for quite some time.
HELP! im running this sql and get the following error - If i manually start the dts package it is fine....also if i use DTSrun from my pc it also works ok..
Could someone please help me!!! I am using a multi-value parameter in SQL 2005 reports and am getting the following error message:
An error has occured during report processing. Qiery execution failed for dataset an expression of non-boolean type specified in a context where condition is expected, near ',' Incorrect syntax near keyword else.
The multi-value parameter works when it isn't run in the if, else clause i checked the where clause with a single paramter and it works OK. I don't understand what is causing this problem but I really need to fix it. Here is my query.
if @job_SubRep_ProjNo_param = '0'
Begin select Job_Job_No as job, Job_Job_Name as Job_title, cast(Job_Total_Fee as float) as fee, employee_first_name + ' ' + employee_surname as jl_name, cast(Job_Percent_Complete as float) as percentcomplete, cast(Job_Work_Done as float) as workdone, cast(Job_Invoicing as float) as job_Invoicing, job_WIP, Job_Expenditure as timecost, job_project_no, Job_Profit_Loss, cast(Job_Hours as float) as hours, job_expenses from job_tbl inner join project_tbl on job_project_no = project_no inner join employee_tbl on job_jl_empno = employee_no where project_pl_empno = @pl_employeeNo or job_jl_empno = @jl_subRep
end else select Job_Job_No as job, Job_Job_Name as Job_title, cast(Job_Total_Fee as float) as fee, employee_first_name + ' ' + employee_surname as jl_name, cast(Job_Percent_Complete as float) as percentcomplete, cast(Job_Work_Done as float) as workdone, cast(Job_Invoicing as float) as job_Invoicing, job_WIP, Job_Expenditure as timecost, job_project_no, Job_Profit_Loss, cast(Job_Hours as float) as hours, job_expenses from job_tbl inner join project_tbl on job_project_no = project_no inner join employee_tbl on job_jl_empno = employee_no where job_project_no in (@job_SubRep_ProjNo_param) or job_jl_empno = @jl_subRep
I am getting an error the parameter is incorrect when using a parameter within a case statement. Here is my SQL: SELECT J.Commitment, J.Vendor, A.Name, J.Category, J.Transaction_Type, J.Job, CASE WHEN J.Transaction_Type = 'AP cost' AND J.Accounting_Date < @MonthEndDate THEN J.Amount END AS InvoicedtoDate, C.Date, C.Delivery_Date FROM JCT_CURRENT__TRANSACTION AS J INNER JOIN JCM_MASTER__COMMITMENT AS C ON J.DBID = C.DBID AND J.Commitment = C.Commitment LEFT OUTER JOIN APM_MASTER__VENDOR AS A ON J.DBID = A.DBID AND J.Vendor = A.Vendor WHERE (J.Commitment <> ' ') AND (J.Job <> ' ') ORDER BY J.Job, J.Commitment If I replace @MonthEndDate with a date value it will run but as soon as I run the SQL with the parameter it gives me the error the parameter is incorrect. @MonthEndDate is data type datetime. Thanks for your help.
I'm working with Schedule Subcription with parameter @startdate in SQL 2005 Standard version. The @startdate is depend on user needs, I've tried to use DayAdd() function in the parameter but don't work. How can I set the parameter in subcription to do it? Thanks!
I have looked through the forum but not found the solution.
I have a OLE DB source connected to the SCD component. I have tried to change the Data Access mode from reading the table and also a 'select * from table' SQL command in the OLE DB source editor, but neither worked.
The SCD component fails with :-
An OLE DB record is available. Source: "Microsoft SQL Native Client" Hresult: 0x80070057 Description: "The parameter is incorrect.".
Error: 0xC0047022 at Extract revenue codes, DTS.Pipeline: The ProcessInput method on component "Slowly Changing Dimension" (12964) failed with error code 0xC0202009. The identified component returned an error from the ProcessInput method.
Hi Help with syntax, I get the error in the line: myDA.Fill(ds, "t1") Function GetProductsOnDepartmentPromotionPaging(ByVal departmentId As String) Dim myConnection As New _ SqlConnection(ConfigurationSettings.AppSettings("ConnectionString")) Dim myDA As New SqlClient.SqlDataAdapter _ ("MM_SP_GetProductsOnDepartmentPromotion", myConnection)
' Add an input parameter and supply a value for it myDA.SelectCommand.Parameters.Add("@DepartmentID", SqlDbType.Int, 4) myDA.SelectCommand.Parameters("@DepartmentID").Value = departmentId Dim ds As New DataSet Dim pageds As New PagedDataSource myDA.Fill(ds, "t1") pageds.DataSource = ds.Tables("t1").DefaultView pageds.AllowPaging = True pageds.PageSize = 4 Dim curpage As Integer If Not IsNothing(Request.QueryString("Page")) Then curpage = Convert.ToInt32(Request.QueryString("Page")) Else curpage = 1 End If pageds.CurrentPageIndex = curpage - 1 lblCurrpage.Text = "Page: " + curpage.ToString() If Not pageds.IsFirstPage Then lnkPrev.NavigateUrl = Request.CurrentExecutionFilePath + _ "?Page=" + CStr(curpage - 1) End If If Not pageds.IsLastPage Then lnkNext.NavigateUrl = Request.CurrentExecutionFilePath + _ "?Page=" + CStr(curpage + 1) End If list.DataSource = pageds list.DataBind() End Function
I created a report in Reporting Services 2005 where I added multi-value parameters. When I run my report, and try to select more than one parameter, I get an error: Incorrect syntax near ','
WHERE (Cono = @Company) AND (DATEPART(month, PaymentDate) = @Month) AND (DATEPART(year, PaymentDate) = @Year)
If I run the job in preview mode I enter the parameter data as requested and it runs correctly. When I go back to design mode and run the query using the ! (the parameter box pops up with the data I entered in preview mode) I get an error message - The Parameter is incorrect.
I've tried setting the parameters to every combination of string/interger I can think of.
We're currently trying to evaluate SQLJDBC 2005 1.1 June CTP's support for database mirroring automatic failover. Unfortunately we're getting unexpected exceptions for calls that work fine w/ jtds that our blocking our ability to perform these evaluations without us making substantial changes to our codebase.
The first issue is with the name used when calling a stored procedure -- SP names that start with "dbo." give us the following error:
com.microsoft.sqlserver.jdbc.SQLServerException: Incorrect syntax near '.'. src:{call dbo.xyz(?,?,?,?,?,?,?,?)}
The call will work if we change the SQL statement to {call xyz(...)}. I don't understand why we would need to do this, especially given that the documentation for the driver shows call statements with the "dbo." prefix.
We're also having problems using named parameters with stored procedures (for both in and out parametes). Our code has parameter names of the form "@param" as is standard with TSQL (and is required when using jtds). However, this won't work with SQLJDBC -- it only seems to accept parameter names w/o the leading "@". Why is this so?
Finally, we were able to cause a NullPointerException within the driver due to an incorrectly built Properties object that contained an Integer for loginTimeout instead of a String: java.lang.NullPointerException at java.util.Hashtable.put(Hashtable.java:396) at java.util.Properties.setProperty(Properties.java:128) at com.microsoft.sqlserver.jdbc.SQLServerDriver.fixupProperties(Unknown Source) at com.microsoft.sqlserver.jdbc.SQLServerDriver.mergeURLAndSuppliedProperties(Unknown Source) at com.microsoft.sqlserver.jdbc.SQLServerDriver.connect(Unknown Source) While this was due to a bug in our code I would think that such common errors would be better handled.
I have this SSIS Package that it works when I run it on development on Visual Studio. But when I imported it and schedule the job, it gives me the following error: Executed as user: MAINOFFICEASPNET. ... 9.00.3042.00 for 32-bit Copyright (C) Microsoft Corp 1984-2005. All rights reserved. Started: 2:38:39 PM Error: 2007-11-05 14:38:41.02 Code: 0xC0202009 Source: Export_WHSCANP Connection manager "10.5.1.10.DRDB400.aspnet1" Description: SSIS Error Code DTS_E_OLEDBERROR. An OLE DB error has occurred. Error code: 0x80004005. An OLE DB record is available. Source: "IBMDA400 Session" Hresult: 0x80004005 Description: "CWBSY0002 - Password for user ASPNET on server 10.5.1.10 is not correct ". End Error Error: 2007-11-05 14:38:41.04 Code: 0xC020801C Source: Data Flow Task OLE DB Destination [801] Description: SSIS Error Code DTS_E_CANNOTACQUIRECONNECTIONFROMCONNECTIONMANAGER. The AcquireConnection method call to the connection manager "10.5.1.10.DRDB400.aspnet1" failed with error code 0xC0202009. There may be error messages posted before this with more information on why the AcquireConnec... The package execution fa... The step failed.
This is trying to get a table from the SQL server and copy it to an IBM AS400 server. Any ideas? Thanks, Erick
I'm trying to schedule a DTS package (import some tables from Mysql database) but there is an error and I don't know how to resolve it.
The error is always the same... "The job failed. The Job was invoked by Schedule 24 (Import RT data). The last step to run was step 1 (Import RT data)."
I have tried changing the all the parameters in the job properties, but I always obtein the same message.
The DTS package works fine, I can execute and it works, the problem is the schedule...
. I get following message when the scheduled DTS job starts. ( it runs fine interactively)....
*** I've read other messages about SQLServiceAgent 'permissions' but how do you setup these permissions..
---------------------------------------------------------------------------- DTSRun: Loading... Error: -2147024809 (80070057); Provider Error: 0 (0) Error string: The parameter is incorrect. Error source: Microsoft Data Transformation Services (DTS) Package Help file: sqldts.hlp Help context: 713. Process Exit Code 1. The step failed. ----------------------------------------------------------------------------- . Any help would be appreciated - Thanks
I have a SSIS package that contains an Execute DTS 2000 process. This DTS 2000 is calling a legacy package, which resides on the same server. The legacy package is just to import a flat file into the database. When i right click and execute this package, it runs perfectly without any errors. However, if i try to schedule this package as a job, it keeps failing.
I checked the flat file source for the permission, it does have the account of the executor of the package. In the view history, i didn't see any more information about why it is failing. It keeps saying "The job failed. The Job was invoked by Schedule 10...."
I have automated my packages in sql server agent. When i run the same packages in Business intelligent studio they work perfectly fine But when they are running from sql server agent it comes up with the error...
"The job failed. The Job was invoked by User serverTestSQL. The last step to run was step 1 (Execute Provider Package)"
how should i figure out the cause of the problem Please let me know
Error when trying to schedule a local DTS package.
Package Error message is...
Microsoft SQL-DMO (ODBC SQLState 42000] [Microsoft][ODBC SQL Server Driver][SQL Server]Login failed for user '(null)'. Reason: Not associated with a trusted SQL Server connection.
I am trying to schedule a SISS package by creating a new job but it is giving me error when the job executes.the error i find when i checked the error log it was the following error
Unable to find index entry in index ID 1, of table 2073058421, in database 'msdb'. The indicated index is corrupt or there is a problem with the current update plan. Run DBCC CHECKDB or DBCC CHECKTABLE. If the problem persists, contact product support. [SQLSTATE HY000] (ConnExecuteCachableOp)
I need to run SISS for example every day at 5pm, I run SQL Agent and created new job for my SISS package which store in SISS Package Store on SQL Server, but when this job run I go error:
Log Job History (Test SISS) Step ID 1 Server ADMNBK-010S Job Name Test SISS Step Name Run SISS Mobius Duration 00:00:02 Sql Severity 0 Sql Message ID 0 Operator Emailed Operator Net sent Operator Paged Retries Attempted 0 Message Executed as user: ADMNBK-010SSYSTEM. The package execution failed. The step failed.
if I run SISS package from SISS Package Store "by hands" it works...
I want to schedule a daily backup of one of my database in SQL 2005 Enterprise edtion but the problem is, I can't save my job. Please help, here's the error.
=================================== Unable to cast object of type 'Microsoft.SqlServer.Management.Smo.SimpleObjectKey' to type 'Microsoft.SqlServer.Management.Smo.Agent.JobObjectKey'. (Microsoft.SqlServer.Smo) ------------------------------ Program Location: at Microsoft.SqlServer.Management.Smo.Agent.JobCollection.GetObjectByKey(ObjectKeyBase key) at Microsoft.SqlServer.Management.Smo.SimpleObjectCollectionBase.Contains(String name) at Microsoft.SqlServer.Management.SqlManagerUI.JobData.JobExists(String jobName) at Microsoft.SqlServer.Management.SqlManagerUI.JobData.ApplyChanges() at Microsoft.SqlServer.Management.SqlManagerUI.JobPropertySheet.DoPreProcessExecution(RunType runType, ExecutionMode& executionResult) at Microsoft.SqlServer.Management.SqlMgmt.SqlMgmtTreeViewControl.DoPreProcessExecutionAndRunViews(RunType runType) at Microsoft.SqlServer.Management.SqlMgmt.SqlMgmtTreeViewControl.ExecuteForSql(PreProcessExecutionInfo executionInfo, ExecutionMode& executionResult) at Microsoft.SqlServer.Management.SqlMgmt.SqlMgmtTreeViewControl.Microsoft.SqlServer.Management.SqlMgmt.IExecutionAwareSqlControlCollection.PreProcessExecution(PreProcessExecutionInfo executionInfo, ExecutionMode& executionResult) at Microsoft.SqlServer.Management.SqlMgmt.ViewSwitcherControlsManager.RunNow(RunType runType, Object sender)
Ok, I'm somewhat familiar with Exchange, but I'm totally new to SQL.
Here's my problem:
Each night I have a batch file shut down the SQL processes. I then copy the relevant files to another hard drive for back up purposes. I have 2 databases. The first database file and transaction log goes just fine and both files copy. The second database file goes just fine as well, but the transaction log returns "incorrect Parameter". It does this even if I simply try to right click & copy the file in windows with the SQL processes down so I've ruled out it being the syntax of my batch file.
The .LDF for this database is huge (to me at least), it weighs in at +50GB's and is growing 2-4 GB's a week. Is it safe to simply delete this transaction log and start a new one since I have a good backup of it's associated database? I'm not exactly sure what caused the incorrect parameter errors either. I inherited this problem so my background info is limited.
I am getting an error saying, "Incorrect syntax near keyword 'ON'" Could someone please help? Here is my code: str = "SELECT FAC_REQUEST.*, StateFAC.*, STATUS.sStatus, FAC_TYPE.Facility_Type FROM FAC_TYPE INNER JOIN ((FAC_REQUEST INNER JOIN STATUS ON FAC_REQUEST.iStatusID = STATUS.iStatusID) ON StateFAC.DVN = FAC_REQUEST.DVN) ON FAC_TYPE.Faciltiy_Type = FAC.FacilityType WHERE iRequestID=" & iRequestID Thanks
Hi, When i exceute my report i get the following .. An error occured during local report processing. Query exceuteion failed for dataset 'orders' Incorrect syntax near ')' If i give NULL i get the above error... But if give one or 2 values it works. but If I run the query in my Sql server mgt studio it works fine too and i run in the BIDS or VS2005 it works fine.. but something happens when i generate the reports... ALTER Procedure [dbo].[usp_GetOrdersByOrderDate] @ClientId nvarchar(max)= NULL, @StartDate datetime, @EndDate datetime AS Declare @SQLTEXT nvarchar(max) If @ClientId IS NULL Begin Select o.OrderId, o.OrderDate, o.CreatedByUserId, c.LoginId, o.Quantity, o.RequiredDeliveryDate, cp.PlanId, cp.ClientPlanId FROM [Order] o Inner Join ClientPlan cp on o.PlanId = cp.PlanId Inner Join ClientUser c on o.CreatedByUserId = c.UserId WHERE --cp.ClientId = @ClientId --AND o.OrderDate BETWEEN @StartDate AND @EndDate ORDER BY o.OrderId DESC END ELSE BEGIN SELECT @SQLTEXT = 'Select o.OrderId, o.OrderDate, o.CreatedByUserId, c.LoginId, o.Quantity, o.RequiredDeliveryDate, cp.PlanId, cp.ClientPlanId FROM [Order] o Inner Join ClientPlan cp on o.PlanId = cp.PlanId Inner Join ClientUser c on o.CreatedByUserId = c.UserId WHERE cp.ClientId in (' + @ClientId + ') AND o.OrderDate BETWEEN ' + Convert(varchar,@StartDate) + ' AND ' + convert(varchar, @EndDate) + ' ORDER BY o.OrderId DESC' execute (@SQLTEXT)
Hi! I need some help with this error which I'm unable to understand.
Any help will be highly appreciated.
<Error> Line 1: Incorrect syntax near 'Number'. Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.Data.SqlClient.SqlException: Line 1: Incorrect syntax near 'Number'.
Source Error:
Line 69: Dim da As SqlDataAdapter = New SqlDataAdapter(cmd) Line 70: Dim ds As DataSet = New DataSet Line 71: da.Fill(ds, "Equip") Line 72: Line 73: dgdSearch.DataSource = ds.Tables("Equip").DefaultView
Private Sub butSearch_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles butSearch.Click Dim objConnection As SqlConnection Dim objCommand As SqlCommand Dim objAdapter As SqlDataAdapter Dim objDataReader As SqlDataReader Dim objDataSet As DataSet Dim strSearch As String Dim StrSQLQuery As String 'Dim mySQL As String
'Get Search strSearch = txtSearch.Text
'If there's nothing to search for then don't search ' o/w build our SQL Query execute it. If Len(Trim(strSearch)) > 0 Then 'Set up our connection. Dim strConn As String = ("server=(local);Integrated Security=SSPI;database=Equipment Log")
'-- setup the select command Dim mySQL As String = "Select * From Equip Where " & ddlSearch.SelectedValue.ToString() & " Like '" & txtSearch.Text & " %' Order by DemoNum"
Dim MyConn As New SqlConnection(strConn) '--create the SqlCommand object (a connection would need to be set up too) Dim cmd As SqlCommand = New SqlCommand(mySQL, MyConn) MyConn.Open() '--execute the query and fill a dataset with the results Dim da As SqlDataAdapter = New SqlDataAdapter(cmd) Dim ds As DataSet = New DataSet da.Fill(ds, "Equip")
I am getting the following error when attempting to call a certain function: "Incorrect Syntax near spListPrograms, Line 1" Here is the sproc: ALTER PROCEDURE spListPrograms @parentID int = 0 AS SELECT pwbsID, pwbsTitle FROM ProgramWBS WHERE pwbsParent = @parentID It is being called from this function: Public Shared Function ListProgramChildNodes(Optional ByVal parentID As Integer = 0) As SqlDataReader Dim cmd As New SqlCommand("spListPrograms", strConn) cmd.Parameters.AddWithValue("@parentID", parentID) Try strConn.Open() Return cmd.ExecuteReader(CommandBehavior.CloseConnection)
Catch e As SqlException Dim errorMessages As String = "" Dim i As Integer
For i = 0 To e.Errors.Count - 1 errorMessages += "Index #" & i.ToString() & ControlChars.NewLine _ & "Message: " & e.Errors(i).Message & ControlChars.NewLine _ & "LineNumber: " & e.Errors(i).LineNumber & ControlChars.NewLine _ & "Source: " & e.Errors(i).Source & ControlChars.NewLine _ & "Procedure: " & e.Errors(i).Procedure & ControlChars.NewLine Next i
MsgBox(errorMessages) Finally strConn.Close() End Try End Function
The sproc works just fine when I execute it from the database directly in SQl Express. What could cause an incorrect syntax error? There's hardly any syntax there for an error to occur Thanks for any help you can give me.
hi. i am relatively new to sql. i am wondering how to resolve my "incorrect syntax error" on an IP Address string i am trying to add. the table has IPAddress as data type "text" and length 16 (which won't let me change the length). It seems that sql is looking for a data type with no more than one decimal (money, float, etc). How do i resolve this? thanks in advance. Peter
I have procedures scheduled to run it was fine and started giving the following error last couple of days. If I run the procedure from SQL analyser it works fine.
Msg 0, Sev 11: Associated statement is not prepared [SQLSTATE 42000]