Showing posts with label click. Show all posts
Showing posts with label click. Show all posts

Friday, March 30, 2012

Problem scheduling a package

Hi,
I have a package saved in the msdb database. When I right click on it and execute, it works fine through the dts utility program.

When I schedule it, it always errors out with the message "The command line parameters are invalid".

The package is password protected. The command line in the dts utility reads: /DTS "\MSDB\<package name>" /SERVER aawork2/DECRYPT /MAXCONCURRENT " -1 " /CHECKPOINTING OFF /REPORTING V
I have to enter my password to view this.

In the job step, if I click the command line, it reads: /DTS "/MSDB/<package name>" /SERVER aawork2/DECRYPT <password> /MAXCONCURRENT " -1 " /CHECKPOINTING OFF

I suspect its something to do with the password protection and the fact the job runs it under the service account.

Thanks in advance for any help.

Asim.
No, the problem (most likely) is that the package path has forward slashes instead of backward slashes. Try changing them to back slashses. Also put a space between the server name and the /DECRYPT option. These were bugs that should be fixed by RTM.

Thanks,
Matt|||Matt, it works. Thanks! This was very helpful.

Asim.

Wednesday, March 21, 2012

Problem opening MSDB folder under Stored Packages

I am able to connect to Integration Services in MSSMS. However, when I try to expand and click on MSDB under Stored Packages, I get a Login Timeout expired error. I get this error both locally, and remotely. Error message suggested "does not allow remote connections", but I checked Surface Area Configuration, and remote connection is already enabled. Moreover, I get the same error even when connecting locally.

any ideas?
Do you have a default instance of SQL Server installed in that machine?|||No, it's a clustersql

Monday, March 12, 2012

problem modifying sqldatasource for dropdownlist control

i use asp.net 2.0 and c#

initially the dropdownlist control is bound to the queryA ("select * from tableA".) for sqldatasource1

now in a button click event, i want to change the query to queryB ("select * from tableA where id = @.id".)

in the code below, i can change the SELECT query of sqldatasource1 from queryA to queryB, but how can i give value to the parameter? please help

protected

void Button1_Click(object sender,EventArgs e)

{

sqldatasource1.SelectCommand = queryB

}

You almost had it, you just needed to add a parameter to the SelectParameters collection like so:

ASPX

<asp:dropdownlist id="ddlProducts" runat="server" datasourceid="sdsProducts" datatextfield="ProductName"datavaluefield="ProductID" /><asp:sqldatasource id="sdsProducts" runat="server" connectionstring="<%$ ConnectionStrings:NorthwindConnectionString%>"selectcommand="SELECT Products.* FROM Products" /><br /><br /><asp:button id="btnSubmit" runat="server" onclick="btnSubmit_Click" text="Load DropDownList with Seafood products only" />

CODE-BEHIND

protected void btnSubmit_Click(object sender, EventArgs e){sdsProducts.SelectCommand ="SELECT * FROM Products WHERE CategoryID = @.CategoryID";sdsProducts.SelectParameters.Add("CategoryID","8");}

|||hi ecbruk, there is an error saying parameter already exist, please chose a different name ;(|||Are you already setting forth your parameter declaratively within you SqlDataSource?

Monday, February 20, 2012

Problem inserting date

Hello

The date format in SQL Server 2000 is dd-MM-yyyy. I am writing the following code in the buttons click event. I am using a textbox and button.

Dim conn as SqlConnection=new SqlConnection(connection string)

Dim ins as string="insert into Sample(dval) values(' " & TextBox1.Text & " ')"

Dim cmd as SQlCommand=new SqlCommand(sel,conn)

conn.open()

cmd.ExecuteNonQuerry()

conn.close()

When i am inserting the date 05-03-2007 in the textbox and clicking the button it is inserting date

03-05-2007 rather than 05-03-2007. What changes should i make in the code?

Rathish

Hi,

before insert, convert the date to yyyymmdd, with this no matter the config of your SQL

|||Hello How to convert date to yyyy-mm-dd.Rathish