Friday, March 30, 2012
profiler
thought it would stop once I closed the profiler. WRONG!!!
How can I stop this?
You can use the following TSQL statement to identify the TraceID of any
Traces that are currently running:
SELECT DISTINCT traceid FROM :: fn_trace_getinfo(default)
You can then stop any running traces by setting the status of the TraceID to
stopped (0).
ie.
EXEC sp_trace_setstatus @.traceid = 1,
@.status = 0
HTH
- Peter Ward
WARDY IT Solutions
"Andre Gibson" wrote:
> I stsrted a trace on one of my bds and it is creating mulitple 5 mb files. I
> thought it would stop once I closed the profiler. WRONG!!!
> How can I stop this?
|||thanks so much Peter,
I will try that
"P. Ward" wrote:
[vbcol=seagreen]
> You can use the following TSQL statement to identify the TraceID of any
> Traces that are currently running:
> SELECT DISTINCT traceid FROM :: fn_trace_getinfo(default)
> You can then stop any running traces by setting the status of the TraceID to
> stopped (0).
> ie.
> EXEC sp_trace_setstatus @.traceid = 1,
> @.status = 0
> HTH
>
> - Peter Ward
> WARDY IT Solutions
>
> "Andre Gibson" wrote:
Wednesday, March 28, 2012
profiler
thought it would stop once I closed the profiler. WRONG!!!
How can I stop this?You can use the following TSQL statement to identify the TraceID of any
Traces that are currently running:
SELECT DISTINCT traceid FROM :: fn_trace_getinfo(default)
You can then stop any running traces by setting the status of the TraceID to
stopped (0).
ie.
EXEC sp_trace_setstatus @.traceid = 1,
@.status = 0
HTH
- Peter Ward
WARDY IT Solutions
"Andre Gibson" wrote:
> I stsrted a trace on one of my bds and it is creating mulitple 5 mb files. I
> thought it would stop once I closed the profiler. WRONG!!!
> How can I stop this?|||thanks so much Peter,
I will try that
"P. Ward" wrote:
> You can use the following TSQL statement to identify the TraceID of any
> Traces that are currently running:
> SELECT DISTINCT traceid FROM :: fn_trace_getinfo(default)
> You can then stop any running traces by setting the status of the TraceID to
> stopped (0).
> ie.
> EXEC sp_trace_setstatus @.traceid = 1,
> @.status = 0
> HTH
>
> - Peter Ward
> WARDY IT Solutions
>
> "Andre Gibson" wrote:
> > I stsrted a trace on one of my bds and it is creating mulitple 5 mb files. I
> > thought it would stop once I closed the profiler. WRONG!!!
> >
> > How can I stop this?
profiler
thought it would stop once I closed the profiler. WRONG!!!
How can I stop this?You can use the following TSQL statement to identify the TraceID of any
Traces that are currently running:
SELECT DISTINCT traceid FROM :: fn_trace_getinfo(default)
You can then stop any running traces by setting the status of the TraceID to
stopped (0).
ie.
EXEC sp_trace_setstatus @.traceid = 1,
@.status = 0
HTH
- Peter Ward
WARDY IT Solutions
"Andre Gibson" wrote:
> I stsrted a trace on one of my bds and it is creating mulitple 5 mb files.
I
> thought it would stop once I closed the profiler. WRONG!!!
> How can I stop this?|||thanks so much Peter,
I will try that
"P. Ward" wrote:
[vbcol=seagreen]
> You can use the following TSQL statement to identify the TraceID of any
> Traces that are currently running:
> SELECT DISTINCT traceid FROM :: fn_trace_getinfo(default)
> You can then stop any running traces by setting the status of the TraceID
to
> stopped (0).
> ie.
> EXEC sp_trace_setstatus @.traceid = 1,
> @.status = 0
> HTH
>
> - Peter Ward
> WARDY IT Solutions
>
> "Andre Gibson" wrote:
>
profiler
I
thought it would stop once I closed the profiler. WRONG!!!
How can I stop this?Is there some service I can restart that will end this without me having to
restart the server.
"Andre Gibson" wrote:
> I stsrted a trace on one of my db's and it is creating mulitple 5 mb files
. I
> thought it would stop once I closed the profiler. WRONG!!!
> How can I stop this?
>|||Did you select the "server side trace" checkbox? If so, you have a server si
de trace running, which
is disconnected from the Profiler GUI. It will stop if you restart the SQL S
erver. Or you can stop
it explicitly. First find out the ID of the trace using fn_trace_getinfo. Th
en stop and close the
trace using sp_trace_setstatus. You need to first stop (0) and then close (2
).
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
Blog: http://solidqualitylearning.com/blogs/tibor/
"Andre Gibson" <AndreGibson@.discussions.microsoft.com> wrote in message
news:19BEFA5A-5395-4611-BE1C-B9D81315A781@.microsoft.com...
>I stsrted a trace on one of my db's and it is creating mulitple 5 mb files.
I
> thought it would stop once I closed the profiler. WRONG!!!
> How can I stop this?
>|||thanks Tibor
"Tibor Karaszi" wrote:
> Did you select the "server side trace" checkbox? If so, you have a server
side trace running, which
> is disconnected from the Profiler GUI. It will stop if you restart the SQL
Server. Or you can stop
> it explicitly. First find out the ID of the trace using fn_trace_getinfo.
Then stop and close the
> trace using sp_trace_setstatus. You need to first stop (0) and then close
(2).
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://www.solidqualitylearning.com/
> Blog: http://solidqualitylearning.com/blogs/tibor/
>
> "Andre Gibson" <AndreGibson@.discussions.microsoft.com> wrote in message
> news:19BEFA5A-5395-4611-BE1C-B9D81315A781@.microsoft.com...
>
Monday, March 26, 2012
Producing Text File
My sql skills are pretty poor, so please bear with me!
I need to take info from two tables (in Access db) and produce two txt files.
The data in the first table is listed as follows: OrderID, OrderDate, CustomerID, Total
The data in the second table is listed as follows: OrderID, Quantity, Discount, UnitPrice
The user has to be able to specify a time frame (start date and end date).
The major problem I'm having is with setting up the txt files. The header has to have the OrderID listed as "!!OrderID" (this is the way the fake company has their db set up apparently) Also, in the actual data in the txt files the OrderDate has to start w/ "#" and the CustomerID has to start w/ "&".
here's what I mean:
!!OrderID OrderDate CustomerID Total
--- --- ---- --
123456 #456789 &abcdef 987654
If you can help me at all, I'd much appreciate it!!! Thank you!Well, in MS Access you can't use "!" in column name, so you'll have to handle this using VBA coding and replace column name when writing into the text file. You didn't describe tables relationship.
SELECT
[OrderID],
"#" + [OrderDate] AS [OrderDate],
"&" + [CustomerID] AS [CustomerID],
[Total]
from
your_table;
store the result into some VBA object (I don't remember which one to use, it's long time since I used Access for last time). Open text file and read row by row from VBA object and write it into the file. Replace column name OrderID with !!OrderID|||Thanks for the help. The tables are linked through OrderID. Also, I found out that I don't have to use Access to do the project. MySQL is allowed as well. If that makes a difference w/ the !! problem, let me know.
Thanks again!
Tuesday, March 20, 2012
Processing XML with defined namespaces
I'm trying use the SSIS XML Task to process some XML files that have namespaces and schemas defined . One of the things I am doing is trying to perform an XPATH query on the files. However, I'm unable to provide either a namespace manager or XsltContext to the XML Task and that causes the XML Task to not understand my XPATH queries.
For example, if my XML is:
<o:object id="12345" xmlns:o="urn:some-urn"/>
and my desired XPATH is "/o:object/@.id", I get the following error:
Error: 0xC002F304 at Query, XML Task: An error occurred with the following error message: "Namespace Manager or XsltContext needed. This query has a prefix, variable, or user-defined function.".
Of course, the XPATH "/object/@.id" returns nothing as expected.
Is there a way around this?
I'm having the same problem with .NET "System.Xml" have you found a solution to this?|||
I'm getting the same (Xml Task) error. I need my XPath to be /SOAP-ENV:Envelope/SOAP-ENV:Body.
The only way I could work around it was to write the XPath without using the namespace prefix like this:
/*[local-name() = 'Envelope']/*[local-name() = 'Body']
|||what exactly is the problem that you're experiencing with system.xml?A Barber wrote:
I'm having the same problem with .NET "System.Xml" have you found a solution to this?
Processing XML with defined namespaces
I'm trying use the SSIS XML Task to process some XML files that have namespaces and schemas defined . One of the things I am doing is trying to perform an XPATH query on the files. However, I'm unable to provide either a namespace manager or XsltContext to the XML Task and that causes the XML Task to not understand my XPATH queries.
For example, if my XML is:
<o:object id="12345" xmlns:o="urn:some-urn"/>
and my desired XPATH is "/o:object/@.id", I get the following error:
Error: 0xC002F304 at Query, XML Task: An error occurred with the following error message: "Namespace Manager or XsltContext needed. This query has a prefix, variable, or user-defined function.".
Of course, the XPATH "/object/@.id" returns nothing as expected.
Is there a way around this?
I'm having the same problem with .NET "System.Xml" have you found a solution to this?|||I'm getting the same (Xml Task) error. I need my XPath to be /SOAP-ENV:Envelope/SOAP-ENV:Body.
The only way I could work around it was to write the XPath without using the namespace prefix like this:
/*[local-name() = 'Envelope']/*[local-name() = 'Body']
|||what exactly is the problem that you're experiencing with system.xml?A Barber wrote:
I'm having the same problem with .NET "System.Xml" have you found a solution to this?
Processing XML with defined namespaces
I'm trying use the SSIS XML Task to process some XML files that have namespaces and schemas defined . One of the things I am doing is trying to perform an XPATH query on the files. However, I'm unable to provide either a namespace manager or XsltContext to the XML Task and that causes the XML Task to not understand my XPATH queries.
For example, if my XML is:
<o:object id="12345" xmlns:o="urn:some-urn"/>
and my desired XPATH is "/o:object/@.id", I get the following error:
Error: 0xC002F304 at Query, XML Task: An error occurred with the following error message: "Namespace Manager or XsltContext needed. This query has a prefix, variable, or user-defined function.".
Of course, the XPATH "/object/@.id" returns nothing as expected.
Is there a way around this?
I'm having the same problem with .NET "System.Xml" have you found a solution to this?|||I'm getting the same (Xml Task) error. I need my XPath to be /SOAP-ENV:Envelope/SOAP-ENV:Body.
The only way I could work around it was to write the XPath without using the namespace prefix like this:
/*[local-name() = 'Envelope']/*[local-name() = 'Body']
|||what exactly is the problem that you're experiencing with system.xml?A Barber wrote:
I'm having the same problem with .NET "System.Xml" have you found a solution to this?
Monday, March 12, 2012
processing files with timestamp
hi guys,
i have a unique problem here.i get four different type of flat files,which i need to pick up and process parallelly,this i am doing using four different foreach containers for the four load process as i can get multiple files ( i had other issues like rollback etc for using forecah containers).
my problem is,my input file names will have format like this
yyyymmdd_salesdataforproduct_yyyymmdd_hhmmss.txt
here the first date is bussiness date and the second one is the sysytem date..if i get multiple file i have to proceess considering the second date.but by default the foreach loop is considering the first date,what can i do to ensure that only second is used to process my files.
thanks in advance
srikanth
If you want to sort the files by the second date, take a look at this thread:
http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=1467831&SiteID=1
Monday, February 20, 2012
procedure to create log and error files
I have a procedure, containing 10 tables, whenever my procedure is executed, i what to know the start and end time of each table and this should be stored in a separate file known as log file and all the error info. should be stored in error file, and then i want to run this procedure through unix shell script(.ksh), can u plz.. help me out in this regard.
Thanks in advance.
mahe.For your loggin problem in oracle database you can use the log4plsql tools
see : http://log4plsql.sourceforge.net/
with this tools you can log in a lot off device.
G.