Showing posts with label operations. Show all posts
Showing posts with label operations. Show all posts

Tuesday, March 20, 2012

Can this be done with a single query?

Colin,
Pivot operations is exactly what I needed. I applied the pivot type code aga
inst my real
SQL 2000 table and it is doing what I was looking for.
Thanks you very much.
Gaetan
On Sun, 26 Mar 2006 13:09:12 GMT, "Colin Dawson" <newsgroups@.cjdawson.com> w
rote:

>This is a simple pivot operation.
>In SQL 2000 it'll work like this.
>Select
>s.student
>From (
>Select
>student,
>max( case when subject = 'math' then grade end ) math,
>max( case when subject = 'physics' then grade end ) physics,
>max( case when subject = 'chemistry' then grade end ) chemistry
>From #student
>Group by student
> ) s
>where s.math >= 85
>and s.physics >= 85
>and s.chemistry >= 85
>
>and in SQL 2005 it works like this.
>Select
>student
>From #student s
>Pivot ( Max( s.grade ) For s.subject in ( [math], [physics], [chemistry] ) )
>as pvt
>where pvt.math >= 85
>and pvt.physics >= 85
>and pvt.chemistry >= 85
>
>The execution plan for the SQL2005 example is slightly more efficient, but
>only be removing one compute scaler from the plan. All in all, that's not
>an issue.
>
>Regards
>Colin Dawson
>www.cjdawson.com
>
>"Gaetan" <me@.somewhere.com> wrote in message
> news:m9sb221pmojvn8t9m368gnopdshmjti023@.
4ax.com...
>thx.
Colin.

Thursday, March 8, 2012

Can SQL Server 2005 using C# make a SOAP call do set operations?

We have two remote data sources that we will access via a SOAP call.
But then we need to operate on the two sets (remove dups, etc.) and,
ideally, return a SQL result set to the client app.
So questions:
* Can we make a SOAP call using C# from within SQL Server?
* Can SQL Server operate on the resulting data (an XML record)?
* Can SQL Server return the combined results as a standard results set?
Thank youHello shp.jc,

> * Can we make a SOAP call using C# from within SQL Server?
Yes.

> * Can SQL Server operate on the resulting data (an XML record)?
Yes, but you'll probably want to do that with CLR code.

> * Can SQL Server return the combined results as a standard results
> set?
Yes, but recommend loading the data from the SOAP into a temp table and then
doing that work with T-SQL. Note that you can just have the Spoc or Function
turn an XML instance and query over that with Xquery.
Thank you,
Kent Tegels
DevelopMentor
http://staff.develop.com/ktegels/

Sunday, February 19, 2012

can server logs catch who performs critical actions?

By critical actions, I mean some operations like dumping database, changing
data etc.
Can SQL server logs catch those actions or do I need to turn on some
switches to be able to do so?
Thanks in advance for any help.
Bing
bing
I have to set recovery mode to FULL or Bulk-Logged.
For more info please refer to the BOL
"bing" <bing@.discussions.microsoft.com> wrote in message
news:A326C754-600D-4F8F-9EEB-24E7738648A7@.microsoft.com...
> By critical actions, I mean some operations like dumping database,
changing
> data etc.
> Can SQL server logs catch those actions or do I need to turn on some
> switches to be able to do so?
> Thanks in advance for any help.
> Bing
|||Thanks, Uri. But I don't see how that full or bulk-logged model related to
my question. The database is using FULL model, by the way. What I was
looking for was who accessed which databases when and performed what
operations. I don't see much of that in SQL server logs. Maybe I have to
use some 3rd party tools, e.g. Log Explorer?
Bing
"Uri Dimant" wrote:

> bing
> I have to set recovery mode to FULL or Bulk-Logged.
> For more info please refer to the BOL
> "bing" <bing@.discussions.microsoft.com> wrote in message
> news:A326C754-600D-4F8F-9EEB-24E7738648A7@.microsoft.com...
> changing
>
>
|||Look at Profiler to see if it does what you want. If you need more, use some of the auditing tools.
(My suggestion...)
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"bing" <bing@.discussions.microsoft.com> wrote in message
news:3A0D1A1D-529B-427B-9B68-5B30CA56E0EF@.microsoft.com...[vbcol=seagreen]
> Thanks, Uri. But I don't see how that full or bulk-logged model related to
> my question. The database is using FULL model, by the way. What I was
> looking for was who accessed which databases when and performed what
> operations. I don't see much of that in SQL server logs. Maybe I have to
> use some 3rd party tools, e.g. Log Explorer?
> Bing
> "Uri Dimant" wrote:
|||Check out Log Explorer from Lumigent, there are probably other similar tools
but nothing that comes with SQL Server. You might be able to use Profiler to
determine some of what you want, but it will require some setup and will
only help if it's running when the events you're tracking happen.
Mike Kruchten
"bing" <bing@.discussions.microsoft.com> wrote in message
news:A326C754-600D-4F8F-9EEB-24E7738648A7@.microsoft.com...
> By critical actions, I mean some operations like dumping database,
> changing
> data etc.
> Can SQL server logs catch those actions or do I need to turn on some
> switches to be able to do so?
> Thanks in advance for any help.
> Bing
|||Depending on what you need to captuer, you could also create triggers that
are fired under certain circumstances - e.g. when data in a field are edited
or deleted.
Regards
Steen
bing wrote:[vbcol=seagreen]
> Thanks, Uri. But I don't see how that full or bulk-logged model
> related to my question. The database is using FULL model, by the
> way. What I was looking for was who accessed which databases when
> and performed what operations. I don't see much of that in SQL
> server logs. Maybe I have to use some 3rd party tools, e.g. Log
> Explorer?
> Bing
> "Uri Dimant" wrote:

can server logs catch who performs critical actions?

By critical actions, I mean some operations like dumping database, changing
data etc.
Can SQL server logs catch those actions or do I need to turn on some
switches to be able to do so?
Thanks in advance for any help.
Bingbing
I have to set recovery mode to FULL or Bulk-Logged.
For more info please refer to the BOL
"bing" <bing@.discussions.microsoft.com> wrote in message
news:A326C754-600D-4F8F-9EEB-24E7738648A7@.microsoft.com...
> By critical actions, I mean some operations like dumping database,
changing
> data etc.
> Can SQL server logs catch those actions or do I need to turn on some
> switches to be able to do so?
> Thanks in advance for any help.
> Bing|||Thanks, Uri. But I don't see how that full or bulk-logged model related to
my question. The database is using FULL model, by the way. What I was
looking for was who accessed which databases when and performed what
operations. I don't see much of that in SQL server logs. Maybe I have to
use some 3rd party tools, e.g. Log Explorer?
Bing
"Uri Dimant" wrote:
> bing
> I have to set recovery mode to FULL or Bulk-Logged.
> For more info please refer to the BOL
> "bing" <bing@.discussions.microsoft.com> wrote in message
> news:A326C754-600D-4F8F-9EEB-24E7738648A7@.microsoft.com...
> > By critical actions, I mean some operations like dumping database,
> changing
> > data etc.
> >
> > Can SQL server logs catch those actions or do I need to turn on some
> > switches to be able to do so?
> >
> > Thanks in advance for any help.
> >
> > Bing
>
>|||Look at Profiler to see if it does what you want. If you need more, use some of the auditing tools.
(My suggestion...)
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"bing" <bing@.discussions.microsoft.com> wrote in message
news:3A0D1A1D-529B-427B-9B68-5B30CA56E0EF@.microsoft.com...
> Thanks, Uri. But I don't see how that full or bulk-logged model related to
> my question. The database is using FULL model, by the way. What I was
> looking for was who accessed which databases when and performed what
> operations. I don't see much of that in SQL server logs. Maybe I have to
> use some 3rd party tools, e.g. Log Explorer?
> Bing
> "Uri Dimant" wrote:
>> bing
>> I have to set recovery mode to FULL or Bulk-Logged.
>> For more info please refer to the BOL
>> "bing" <bing@.discussions.microsoft.com> wrote in message
>> news:A326C754-600D-4F8F-9EEB-24E7738648A7@.microsoft.com...
>> > By critical actions, I mean some operations like dumping database,
>> changing
>> > data etc.
>> >
>> > Can SQL server logs catch those actions or do I need to turn on some
>> > switches to be able to do so?
>> >
>> > Thanks in advance for any help.
>> >
>> > Bing
>>|||Check out Log Explorer from Lumigent, there are probably other similar tools
but nothing that comes with SQL Server. You might be able to use Profiler to
determine some of what you want, but it will require some setup and will
only help if it's running when the events you're tracking happen.
Mike Kruchten
"bing" <bing@.discussions.microsoft.com> wrote in message
news:A326C754-600D-4F8F-9EEB-24E7738648A7@.microsoft.com...
> By critical actions, I mean some operations like dumping database,
> changing
> data etc.
> Can SQL server logs catch those actions or do I need to turn on some
> switches to be able to do so?
> Thanks in advance for any help.
> Bing|||Depending on what you need to captuer, you could also create triggers that
are fired under certain circumstances - e.g. when data in a field are edited
or deleted.
Regards
Steen
bing wrote:
> Thanks, Uri. But I don't see how that full or bulk-logged model
> related to my question. The database is using FULL model, by the
> way. What I was looking for was who accessed which databases when
> and performed what operations. I don't see much of that in SQL
> server logs. Maybe I have to use some 3rd party tools, e.g. Log
> Explorer?
> Bing
> "Uri Dimant" wrote:
>> bing
>> I have to set recovery mode to FULL or Bulk-Logged.
>> For more info please refer to the BOL
>> "bing" <bing@.discussions.microsoft.com> wrote in message
>> news:A326C754-600D-4F8F-9EEB-24E7738648A7@.microsoft.com...
>> By critical actions, I mean some operations like dumping database,
>> changing data etc.
>> Can SQL server logs catch those actions or do I need to turn on some
>> switches to be able to do so?
>> Thanks in advance for any help.
>> Bing

can server logs catch who performs critical actions?

By critical actions, I mean some operations like dumping database, changing
data etc.
Can SQL server logs catch those actions or do I need to turn on some
switches to be able to do so?
Thanks in advance for any help.
Bingbing
I have to set recovery mode to FULL or Bulk-Logged.
For more info please refer to the BOL
"bing" <bing@.discussions.microsoft.com> wrote in message
news:A326C754-600D-4F8F-9EEB-24E7738648A7@.microsoft.com...
> By critical actions, I mean some operations like dumping database,
changing
> data etc.
> Can SQL server logs catch those actions or do I need to turn on some
> switches to be able to do so?
> Thanks in advance for any help.
> Bing|||Thanks, Uri. But I don't see how that full or bulk-logged model related to
my question. The database is using FULL model, by the way. What I was
looking for was who accessed which databases when and performed what
operations. I don't see much of that in SQL server logs. Maybe I have to
use some 3rd party tools, e.g. Log Explorer?
Bing
"Uri Dimant" wrote:

> bing
> I have to set recovery mode to FULL or Bulk-Logged.
> For more info please refer to the BOL
> "bing" <bing@.discussions.microsoft.com> wrote in message
> news:A326C754-600D-4F8F-9EEB-24E7738648A7@.microsoft.com...
> changing
>
>|||Look at Profiler to see if it does what you want. If you need more, use some
of the auditing tools.
(My suggestion...)
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"bing" <bing@.discussions.microsoft.com> wrote in message
news:3A0D1A1D-529B-427B-9B68-5B30CA56E0EF@.microsoft.com...[vbcol=seagreen]
> Thanks, Uri. But I don't see how that full or bulk-logged model related t
o
> my question. The database is using FULL model, by the way. What I was
> looking for was who accessed which databases when and performed what
> operations. I don't see much of that in SQL server logs. Maybe I have t
o
> use some 3rd party tools, e.g. Log Explorer?
> Bing
> "Uri Dimant" wrote:
>|||Check out Log Explorer from Lumigent, there are probably other similar tools
but nothing that comes with SQL Server. You might be able to use Profiler to
determine some of what you want, but it will require some setup and will
only help if it's running when the events you're tracking happen.
Mike Kruchten
"bing" <bing@.discussions.microsoft.com> wrote in message
news:A326C754-600D-4F8F-9EEB-24E7738648A7@.microsoft.com...
> By critical actions, I mean some operations like dumping database,
> changing
> data etc.
> Can SQL server logs catch those actions or do I need to turn on some
> switches to be able to do so?
> Thanks in advance for any help.
> Bing|||Depending on what you need to captuer, you could also create triggers that
are fired under certain circumstances - e.g. when data in a field are edited
or deleted.
Regards
Steen
bing wrote:[vbcol=seagreen]
> Thanks, Uri. But I don't see how that full or bulk-logged model
> related to my question. The database is using FULL model, by the
> way. What I was looking for was who accessed which databases when
> and performed what operations. I don't see much of that in SQL
> server logs. Maybe I have to use some 3rd party tools, e.g. Log
> Explorer?
> Bing
> "Uri Dimant" wrote:
>

Friday, February 10, 2012

Can not install Service Pack 3a

When I try to install SQL SP3a, I get error from my
server: "A previous program installation created pending
file operations. You must restart youe computer." After I
restart my PC, I still get the same error when I try to
install SQL SP3a.
Are there any suggestion to help me to install SP 3a?
Thanks,
-Mike
Have a look here
http://www.tkdinesh.com/faq/ans/pendingfiles.html
HTH
Jasper Smith (SQL Server MVP)
I support PASS - the definitive, global
community for SQL Server professionals -
http://www.sqlpass.org
"Mike Torry" <anonymous@.discussions.microsoft.com> wrote in message
news:a40201c43522$7633c140$a001280a@.phx.gbl...
> When I try to install SQL SP3a, I get error from my
> server: "A previous program installation created pending
> file operations. You must restart youe computer." After I
> restart my PC, I still get the same error when I try to
> install SQL SP3a.
> Are there any suggestion to help me to install SP 3a?
> Thanks,
> -Mike

Can not install Service Pack 3a

When I try to install SQL SP3a, I get error from my
server: "A previous program installation created pending
file operations. You must restart youe computer." After I
restart my PC, I still get the same error when I try to
install SQL SP3a.
Are there any suggestion to help me to install SP 3a?
Thanks,
-MikeHave a look here
http://www.tkdinesh.com/faq/ans/pendingfiles.html
--
HTH
Jasper Smith (SQL Server MVP)
I support PASS - the definitive, global
community for SQL Server professionals -
http://www.sqlpass.org
"Mike Torry" <anonymous@.discussions.microsoft.com> wrote in message
news:a40201c43522$7633c140$a001280a@.phx.gbl...
> When I try to install SQL SP3a, I get error from my
> server: "A previous program installation created pending
> file operations. You must restart youe computer." After I
> restart my PC, I still get the same error when I try to
> install SQL SP3a.
> Are there any suggestion to help me to install SP 3a?
> Thanks,
> -Mike

Can not install Service Pack 3a

When I try to install SQL SP3a, I get error from my
server: "A previous program installation created pending
file operations. You must restart youe computer." After I
restart my PC, I still get the same error when I try to
install SQL SP3a.
Are there any suggestion to help me to install SP 3a?
Thanks,
-MikeHave a look here
http://www.tkdinesh.com/faq/ans/pendingfiles.html
HTH
Jasper Smith (SQL Server MVP)
I support PASS - the definitive, global
community for SQL Server professionals -
http://www.sqlpass.org
"Mike Torry" <anonymous@.discussions.microsoft.com> wrote in message
news:a40201c43522$7633c140$a001280a@.phx.gbl...
> When I try to install SQL SP3a, I get error from my
> server: "A previous program installation created pending
> file operations. You must restart youe computer." After I
> restart my PC, I still get the same error when I try to
> install SQL SP3a.
> Are there any suggestion to help me to install SP 3a?
> Thanks,
> -Mike