How Do I Watch Variable Values During Debugging ?

Jan 12, 2006

Is there a way i can see the value of the variables during debugging ?

View 10 Replies


ADVERTISEMENT

Can I Debug/watch On The Trigger's INSERTED And DELETED Records/values?

Jan 25, 2006

When i debug a trigger is it possible to add a WATCHon the INSERTED or DELETED?I think not, at least I couldn't figure out a way to do so.Does someone have a suggestion on how I can see the values?I did try to do something likeINSERT INTO TABLE1(NAME)SELECT NAME FROM INSERTEDbut this didn't work. When the trigger completed and Iwent to see the TABLE1, there were no records in it.Are there any documents, web links that describe waysof debugging the trigger's INSERTED and DELETED?Thank you

View 11 Replies View Related

Transact SQL :: Insert Values From Variable Into Table Variable

Nov 4, 2015

CREATE TABLE #T(branchnumber VARCHAR(4000))

insert into #t(branchnumber) values (005)
insert into #t(branchnumber) values (090)
insert into #t(branchnumber) values (115)
insert into #t(branchnumber) values (210)
insert into #t(branchnumber) values (216)

[code]....

I have a parameter which should take multiple values into it and pass that to the code that i use. For, this i created a parameter and temporarily for testing i am passing some values into it.Using a dynamic SQL i am converting multiple values into multiple records as rows into another variable (called @QUERY). My question is, how to insert the values from variable into a table (table variable or temp table or CTE).OR Is there any way to parse the multiple values into a table. like if we pass multiple values into a parameter. those should go into a table as rows.

View 6 Replies View Related

When Debugging, Do You Have To Shut Down And Restart BIDS Every Time You Rebuild The Custom Component That You're Debugging?

Jul 9, 2006

Hi,

I have found that when I'm debugging a custom component in BIDS that I've created in another instance of Visual Studio, every time I rebuild the component I have to shutdown and restart BIDS and then reattach to the BIDS process. Which is pretty time consuming... And if I find a small error in my custom component when debugging then I don't seem to be allowed to make any changes to the code unless I stop debugging and go through the process above.

Am I missing something here? Or do I really have to manually go through these steps every time I want to change code in the component I'm debugging?

Can I automate the process with MSBuild or NAnt? If so, is there an example of this anywhere?

Thanks in advance,

Lawrie.

View 1 Replies View Related

Variable Insert To SQL Server Insert Satement Setting Values For The @variable INSIDE Sql

Apr 29, 2007

ok, I am on Day 2 of being brain dead.I have a database with a table with 2 varchar(25) columns I have a btton click event that gets the value of the userName,  and a text box.I NEED to insert a new row in a sql database, with the 2 variables.Ive used a sqldatasource object, and tried to midify the insert parameters, tried to set it at the button click event, and NOTHING is working. Anyone have a good source for sql 101/ASP.Net/Braindead where I can find this out, or better yet, give me an example.  this is what I got <%@ Page Language="C#" %><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><script runat="server">     protected void runit_Click(object sender, EventArgs e)    {       //SqlDataSource ID = "InsertExtraInfo".Insert();      //SqlDataSource1.Insert();    }      protected void Button1_Click1(object sender, EventArgs e)    {        SqlDataSource newsql;                newsql.InsertParameters.Add("@name", "Dan");        newsql.InsertParameters.Add("@color", "rose");        String t_c = "purple";        string tempname = Page.User.Identity.Name;        Label1.Text = tempname;        Label2.Text = t_c;        newsql.Insert();    }</script><html xmlns="http://www.w3.org/1999/xhtml" ><head runat="server">    <title>mini update</title></head><body>    <form id="form1" runat="server">        &nbsp;name<asp:TextBox ID="name" runat="server" OnTextChanged="TextBox2_TextChanged"></asp:TextBox><br />        color        <asp:TextBox ID="color" runat="server"></asp:TextBox><br />        <br />        <asp:Button ID="Button1" runat="server" OnClick="Button1_Click1" Text="Button" />        &nbsp;<br />        set lable =&gt;<asp:Label ID="Label1" runat="server" Text="Label" Width="135px" Visible="False"></asp:Label><br />        Lable 2 =&gt;        <asp:Label ID="Label2" runat="server" Text="Label"></asp:Label><br />        Usernmae=&gt;<asp:LoginName ID="LoginName1" runat="server" />        <br />        <br />        <br />        <br />        <asp:SqlDataSource ID="SqlDataSource1" runat="server" ConflictDetection="CompareAllValues"            ConnectionString="<%$ ConnectionStrings:newstring %>" DeleteCommand="DELETE FROM [favcolor] WHERE [name] = @original_name AND [color] = @original_color"            InsertCommand="INSERT INTO [favcolor] ([name], [color]) VALUES (@name, @color)"            OldValuesParameterFormatString="original_{0}" SelectCommand="SELECT [name], [color] FROM [favcolor]"            UpdateCommand="UPDATE [favcolor] SET [color] = @color WHERE [name] = @original_name AND [color] = @original_color">            <DeleteParameters>                <asp:Parameter Name="original_name" Type="String" />                <asp:Parameter Name="original_color" Type="String" />            </DeleteParameters>            <UpdateParameters>                <asp:Parameter Name="color" Type="String" />                <asp:Parameter Name="original_name" Type="String" />                <asp:Parameter Name="original_color" Type="String" />            </UpdateParameters>            <InsertParameters>        <asp:InsertParameter("@name", "Dan", Type="String" />        <asp:InsertParameter("@color", "rose") Type="String"/>                                       </InsertParameters>        </asp:SqlDataSource>        &nbsp;        <asp:GridView ID="GridView1" runat="server" AllowPaging="True" AllowSorting="True"            AutoGenerateColumns="False" DataKeyNames="name" DataSourceID="SqlDataSource1">            <Columns>                <asp:CommandField ShowDeleteButton="True" ShowEditButton="True" ShowSelectButton="True" />                                <asp:BoundField DataField="color" HeaderText="color" SortExpression="color" />                <asp:BoundField DataField="name" HeaderText="name" ReadOnly="True" SortExpression="name" />            </Columns>        </asp:GridView>           </form></body></html>  

View 1 Replies View Related

Help Reg Watch Window

Feb 27, 2007

hi frnds,

i want to view the runtime variable value in the watch window while the package is running,

how i will get that watch window. i searched all the menus but i didnt get it.

im using Microsoft Visual Studio 2005 for SSIS package.

View 1 Replies View Related

Where To See WATCH Window??

Mar 26, 2007

I honestly don't see where to view the watch window. Can someone please advise.

Thanks

View 5 Replies View Related

Need Help On Use The Watch Windows

Feb 15, 2006

All,

I cannot use the watch window while debugging. I want to use it to look at the runtime variable values. The watch window is blank when I click on it, could someone please tell me where and how to configure it?

Many thanks

View 1 Replies View Related

WQL Query To Watch For A File

Aug 17, 2006

I need an example of a WQL query to use in the WMI Event Watcher task to watch for the presence of a file. The task has to succeed for either:

1) The file already exists when the task is run

2) The file shows up while the task is running (waiting)

Also the query has to reference a UNC path and file name. The file I'm looking for is just a flag file telling me a table is refreshed in our Data Warehouse.

I also need pointers on how to set the WMI connection manager. For the server, do I use the \servername of the fileserver? Do I need to include the folder the files are in (eg. \servernameflags)?

Thanks!

Kory

View 4 Replies View Related

Watch File Drop In Ssis

Jan 30, 2008

I have a folder that gets 2 to 3 files dropped everyday. I want to create a package that loads only the new files into the database. The old files (Processed files) remain in the same folder and cannot be moved. How do i accomplish this in ssis?

I found something about the file watcher task with the for loop, but just can't put it all together.



Any help would be appreciated.



Thanks

View 6 Replies View Related

Does Watch Variables Work In Std Edition?

Mar 2, 2008

between my wrox book, google and looking everywhere in BIDS, I couldn't figure out how to watch the variables being set in an Exec SQL Task control flow item. My wrox book said something about right clicking the var in the script (I wasnt in a script), or using the debug menu or pressing ctrl-alt-q. None of this worked. Is it possible that at installation a certain choice wasnt made, or maybe watch windows only work in the context of something other than the control flow?

View 9 Replies View Related

Profiler Newbie Question - Which Metrics Should I Watch?

Aug 19, 2007

Hi Guys,

I've got an order generation query that will _sometimes_ run long. By that I mean every few days a query used to estimate the required stock quantities for an order will time-out because it has taken an extended time to run. This only occurs at one particular site. This site shares a common schema with others who do not experience this issue, although site is a particularly busy one.

This query (a stored proc call) needs to aggregate sales data from ~200k rows and usually takes 10-15 seconds. On the days when it 'runs long' it will hit the 5 minute time-out period and be failed by the application.

The problem I have with this process is that if I have the application dump out the query it's using to generate the order (this query will vary as the stored proc is passed the name of a temp table to use for this order) so I can run it in Query Analyzer to get an execution plan and maybe some clue as to why it takes so long; the issue will vanish. After I've tried to investigate in this way an order generated from either Query Analyzer or the application will work in the normal time. When the query is running long any processes which attempts to write to the sales data tables will get blocked until the order generation has finished.

The application is accessing the database via ADO 2.6. The database itself is running on SQL Server 2000 sp3 under Win2k.

I believe that the SQL Profiler is the tool best suited to investigate this but I'm hoping for some advice on which of the myriad of watchable metrics I should be checking here.

Any profiler advice or estimates as to what the issue may be here would be great!

-Karl.

View 1 Replies View Related

Adding Variables To The Watch Window / List ...

Feb 5, 2008

Not sure if this is a "user training" issue or a bug, I seem to have difficulty dragging and dropping variable(s) to the watch window. Is there a specific sequence I need to follow to enable this feature in BIDS? Appreciate any feedback.

View 5 Replies View Related

To Display The Full Resultset In The Watch Window

Mar 15, 2007

hi frnds,

i have one SSIS package with single SQL Execute task.

select empname from emp

This is the query i had mentioned in that SQL task.

i had created the varibale User:rs as object and i mapped that to the resutset and i selected fullresultset in general tab.

In the debugging mode im getting the com object as the result of that variable.

This is the o/p which i got in the debugging mode.

- User::rs {System.__ComObject} __ComObject
Type __ComObject
Value System.__ComObject


but i requires the empname to be displayed in that mode.

how to get that?

pls tell me .

View 4 Replies View Related

Variable Between Two Values

Apr 12, 2008



I need to valorate a variable like this:
If VAR1 is Between 1 and 10 entonces vari2= x
else

var2=Y

how can valora if var1 is "between two values"?

View 3 Replies View Related

Log Variable Values

Aug 28, 2007

Is it possible to save variable values to the log file? I have a for each loop that loops through customer orders and I would like to know the order number when the package fails.

View 1 Replies View Related

Display Of Variable Values

Sep 23, 2004

Hello Experts:

I want to access the values coming from the table but my code is just printing the varibale name.

e.g. It is printing right now

@lev0
@lev1
@lev2
@lev3
@lev4

but infact in variable @lev1, the actual value from table is [prodcut]. the value in varibale @lev1 is [category].

Can you pl. help me?

--- My code

Declare

@lev0 varchar(50),
@lev1 varchar(50),
@lev2 varchar(50),
@lev3 varchar(50),
@lev4 varchar(50),
@stmnt varchar(2000),
@counter int,
@st varchar(50)

Select @lev0=Dimnsion, @Lev1= Lev1, @Lev2= Lev2, @Lev3= Lev3, @lev4= lev4 from dbo.Lookup where dimnsion = '[Product]'
Set @counter = 0

while @counter < 5
begin
set @st = '@lev'+cast(@counter as varchar(50))
print @st
set @counter= @counter+1

end

-------

Thanks

View 1 Replies View Related

Variable Values Containing Dashes

Nov 8, 2006

Ok. Here is a weird problem.

I have a package which contains a variable with the value of a UNC sharename. The hostname in the share contains dashes.

I am trying to create a SQL Agent entry to execute said package. Because the package is now in production I want to pass in a new value for the sharename variable. I use the SQL @@SERVERNAME variable to build the package command. (Notice the BlotterUploadFolder variable at the end.)

SELECT @command = N'/FILE "\' + @@SERVERNAME + 'PackagesMiddleOfficeReconcilliationImportManualBlotter_AccountTransfers.dtsx" /MAXCONCURRENT " -1 " /CHECKPOINTING OFF /REPORTING EW /CONNECTION MiddleOfficeDb;"Data Source=' + @@SERVERNAME + ';Initial Catalog=MiddleOffice;Provider=SQLNCLI.1;Integrated Security=SSPI;Auto Translate=False;" /SET package.variables[BlotterUploadFolder].Value;\' + @@SERVERNAME + 'ManualBlottersUploads'

If I print the @command variable right after setting it, I get what I expect.

/FILE "\PRD-NY-DB-01PackagesMiddleOfficeReconcilliationImportManualBlotter_AccountTransfers.dtsx" /MAXCONCURRENT " -1 " /CHECKPOINTING OFF /REPORTING EW /CONNECTION MiddleOfficeDb;"Data Source=PRD-NY-DB-01;Initial Catalog=MiddleOffice;Provider=SQLNCLI.1;Integrated Security=SSPI;Auto Translate=False;" /SET package.variables[BlotterUploadFolder].Value;\PRD-NY-DB-01ManualBlottersUploads

If I cut-paste this into cmd window and execute it with DTExec.exe the package works fine. But when I run the schedule task it causes an error. When I go into the Job Properties dialog to look at the step, I see the value (in the "Set values" table) set to \PRD instead of \PRD-NY-DB-01.

If I modify the SELECT command above to put double-quotes around the value, the value is correct in the Job Properties dialog but causes an error when I exec it with DTExec.

/FILE "\PRD-NY-DB-01PackagesMiddleOfficeReconcilliationImportManualBlotter_AccountTransfers.dtsx" /MAXCONCURRENT " -1 " /CHECKPOINTING OFF /REPORTING EW /CONNECTION MiddleOfficeDb;"Data Source=PRD-NY-DB-01;Initial Catalog=MiddleOffice;Provider=SQLNCLI.1;Integrated Security=SSPI;Auto Translate=False;" /SET package.variables[BlotterUploadFolder].Value;"\PRD-NY-DB-01ManualBlottersUploads"

causes the error

Option "-NY" is not valid.

Hopefully somebody has an idea of what is going on.

Thanks.

- Jason

View 3 Replies View Related

Populate Variable Values

Nov 16, 2006

Hi

How can I populate values for package variables inside a data flow task? I could do this inside a script task in control tab, but how inside a data flow task?

Thanks

Ramani



View 1 Replies View Related

Saving Values Of A Variable

Dec 13, 2006

Hi all,

As there is no support of check points at data flow component level, we are trying to implement this on our own. In the process of implementing we have to save values of certain user defined variables in to an xml file. To do this, we added a data flow task in the event handler OnTaskFailure. Now we want to save values of the variables in to an xml file in the data flow. Can you please suggest me how can we save values of variables in an event handler?

Cheers,

Gopi

View 1 Replies View Related

OK So How Do You Start An SSIS Package With A ForEach And A WMI File Watch Task?

Mar 21, 2007

Can't an SSIS package run "in the background", so to speak, without having either the cmd.exe or dtexecui windows open while executing? I'd obviously rather not have to have a window open when the thing is running right?

View 2 Replies View Related

How Do You Pass Values From VB To A DTS Global Variable?

Jun 24, 2002

I am trying to pass a value from a VB Custom Task to
a DTS. The DTS doesn't get the value and I do not understand
why. Snipet follows:

oPKG.GlobalVariables.Item("gsAnyTypeData").Value = "Hello World"
oPKG.GlobalVariables.AddGlobalVariable ("gsAnyTypeData"), "Hello World"
oPKG.LoadFromSQLServer ".", , , 256, , , , DTSpackage_to_execute
oPKG.Execute

I've tried declaring the global variable in the called DTS and
I've tried without it. Neither contain the value when the DTS is
executed.

Thanks for your time and help,
Martin

View 3 Replies View Related

Collecting Values Into A Variable In A Loop

Mar 13, 2006

Dear All,

I’m trying to collect values from a query into a single variable within a loop, like so:

WHILE condition is true
BEGIN

SET @intLoop = @intLoop + 1

@myString = @myString + ‘, ‘ + (SELECT companyName FROM @tblTheseComp WHERE id = @intLoop

END

For some reason though the @myString does not collect up the values, but will equal NULL at the end of the loop.

If however I simple do

WHILE condition is true
BEGIN

SET @intLoop = @intLoop + 1

@myString = (SELECT companyName FROM @tblTheseComp WHERE id = @intLoop
END


Then I get the last value from the query as expected.

Can anyone explain why this might be?

Thanks in advance!

View 7 Replies View Related

Can Store A List Of Values In A Variable?

Apr 16, 2014

I'm looking for a way to store a list of values in a variable. The query user will need to input a list of file numbers, and my query will need to perform a couple operations on that same list of values, which is why it seems a variable would be most appropriate.

I can't obtain the list of values from the database as they will have to be entered by the user. I'm imagining storing these in a table variable.... User just copies/pastes the list of values somewhere into the query code and executes as usual.

View 7 Replies View Related

Insert Values Of All The Fields Into Variable?

Aug 7, 2014

I need to create a stored procedures, this procedure will receive two parameters:

@TableName

@KeyField

I need to storage into a variable the values of ALL THE FIELDS separeted by |

For example if my table is Customers

CustomerID CustomerName City

111 Adventure Boston

222 Pubs NY

And I execute EXEC mysp 'Customers',111

I need a return value like this

@ReturnValue = 111|Adventure|Boston

I create something like this

CREATE PROCEDURE my sp
@table varchar
@key numeric
AS
@field varchar(40),
@object int
Select @object = object_id from systables where name =@table

--The instructions to create a cursor

WHILE (@@FETCH_STATUS = 0 )
Select @object = name from sys.columns where object_id = @object

--The instructions to close and deallocate the cursor

I have alredy to save the value using the EXEC command but is not working; something like

@String = Select @object from @table where CustomerID = @keyValue

View 1 Replies View Related

Show Variable Values At Runtime

Nov 14, 2007

Is there a quick and easy way, other than scripting a MsgBox(), to show the value of a package variable while the package is running?

View 3 Replies View Related

Select Several Values Into A Single Variable

May 11, 2006

Can somebody please tell me whether the following syntax is supportedor whether it's a "feature" that will someday stop working. It works inboth SQL Server 2000 and 2005 at the moment.declare @var varchar(1000)set @var = ''select @var = @var + colx from some_table where col1 = some_valuecolx is a varchar or at least is cast to one as part of the selectstatement. If the where clause would normally return more than one row,all returned values for colx are concatenated into @var.I've not seen this syntax before but that doesn't make it wrong ;-)Malc.

View 8 Replies View Related

Displaying Variable Values After Execution

Mar 13, 2007

Hello,

I have just developed my first full package and it has been, ahem, an adventure- but I can see the power of SSIS.  I am splitting 1M rows in to up to 11 parts (therefore up to 11M rows) for several files and it takes a matter of seconds!

I have used some variables in the package and would like to see the results of these at the end of execution.  They are purely for interest at the moment.

I think I can output them to a flat file, but is it possible to output them to the Immediate window at the end of execution?

I can not figure out how to have a watch on them either- is this possible?  Ideally I would like a counter on screen next to my loop containers.

All of the web pages I have seen regarding debugging seem to assume that VB is being used to create the package.

Thanks,

Alan.

View 2 Replies View Related

Writing Variable Values In Console

Feb 21, 2008

is there a possibility to print the value of a variable in the debug console? it seems that Console.WriteLine in a script task doesn't work. or is there a better way in order to debug the value of a variable at a certain point?

View 7 Replies View Related

How To Assign Values To A Variable From A Xls Sheet?

Sep 28, 2006

I've got this query inside a Sql Task against a Excel connection and I'd like to insert that value into a user variable called "Proyecto". How do I such thing?

select Proyecto from [Carga$]

TIA,

View 1 Replies View Related

How To Pass Variable Values Between Tasks

Feb 16, 2007

Hi Everybody,

I have to generate a seq num and increment it by 1,i used execute sql task and wrote a proc using a variable(out) now this out variable has that value.Now i need to add a extra column to all the records coming in this current batch with the value in the variable.

I know that i can use derived column transformation ,but its not working,giving the following error.

the errors thrown are:

[OLE DB Destination [16]] Error: An OLE DB error has occurred. Error code: 0x80004005. An OLE DB record is available. Source: "Microsoft OLE DB Provider for Oracle" Hresult: 0x80004005 Description: "Unspecified error". An OLE DB record is available. Source: "Microsoft OLE DB Provider for Oracle" Hresult: 0x80004005 Description: "ORA-01779: cannot modify a column which maps to a non key-preserved table ".
[OLE DB Destination [16]] Error: The "input "OLE DB Destination Input" (29)" failed because error code 0xC020907B occurred, and the error row disposition on "input "OLE DB Destination Input" (29)" specifies failure on error. An error occurred on the specified object of the specified component.
[DTS.Pipeline] Error: The ProcessInput method on component "OLE DB Destination" (16) failed with error code 0xC0209029. The identified component returned an error from the ProcessInput method. The error is specific to the component, but the error is fatal and will cause the Data Flow task to stop running.
[DTS.Pipeline] Error: Thread "WorkThread0" has exited with error code 0xC0209029.
[OLE DB Source [1]] Error: The attempt to add a row to the Data Flow task buffer failed with error code 0xC0047020.
[DTS.Pipeline] Error: The PrimeOutput method on component "OLE DB Source" (1) returned error code 0xC02020C4. The component returned a failure code when the pipeline engine called PrimeOutput(). The meaning of the failure code is defined by the component, but the error is fatal and the pipeline stopped executing.
[DTS.Pipeline] Error: Thread "SourceThread0" has exited with error code 0xC0047038.

i have created a variable with scope as package,used that in execute sql task.then using precedence constrains added a data flow task to it.

In the data flow task between the source and destination i placed a derived column transformation.

the execute sql task is running fine,dataflow task is failing.In dataflow task also source and destination is failing but derived column transformation is working.

Am i doing correct.Pls advice.



Regards

Swan



View 3 Replies View Related

Updating/getting Values From Datagrid In C# With Variable Parameters

Oct 24, 2006

HiI am new to the world of aspx, .net and C#.In aspx .net 2.0. I am trying to work out how to get a datagrid to perform an update. Using Visual Developer I have successfully added the control and specifed a select statement to return data via my SQLData Source. This works fine. However having specifed the control as editable I would like to perform an update through the datagrid and SQLDatasource. I see in the properties for the SQLDatasource object I can specify my update statement.However I do not understand how to get that update statement to have variable values and how newly entered values from the grid can be placed into these variables when the update takes place. Can someone please point me in the right direction? I have not found the MS doc very illuminating thus far and have not found any examples.Many ThanksT

View 1 Replies View Related

How Do I Move Sql Variable Values To Local Variables

Nov 2, 2006

Can someone show how to do this?I have a  SqlDataSource1,  and i have a SELECT * FROM Table1How would i get@ProdName@ProdNumber                        Into the following local variablesString  ProductNameInt       ProductNumber              I’m using C# and ASP 2.0 VWDThanks for Help1 

View 2 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved