Wednesday, March 28, 2012
renamed server
o this server?
You need to update the originating_server column in sysjobs to reflect the
new server name, You can use this proc to do that
http://sqldev.net/download/sqlagent/...ent_rename.sql
HTH
Jasper Smith (SQL Server MVP)
I support PASS - the definitive, global
community for SQL Server professionals -
http://www.sqlpass.org
"rich" <anonymous@.discussions.microsoft.com> wrote in message
news:437DE682-C216-4327-B318-85F47F64CD56@.microsoft.com...
> does anyone have a suggestion for this problem: somewhere along the line,
my database server changed names and now I have jobs I cannot delete out of
the Agent. Can I go to the table the jobs are in (msdb.sysjobs) and just
delete the ones not belonging to this server?
sql
renamed server
new server name, You can use this proc to do that
http://sqldev.net/download/sqlagent/sp_sqlagent_rename.sql
--
HTH
Jasper Smith (SQL Server MVP)
I support PASS - the definitive, global
community for SQL Server professionals -
http://www.sqlpass.org
"rich" <anonymous@.discussions.microsoft.com> wrote in message
news:437DE682-C216-4327-B318-85F47F64CD56@.microsoft.com...
> does anyone have a suggestion for this problem: somewhere along the line,
my database server changed names and now I have jobs I cannot delete out of
the Agent. Can I go to the table the jobs are in (msdb.sysjobs) and just
delete the ones not belonging to this server?
renamed server
database server changed names and now I have jobs I cannot delete out of th
e Agent. Can I go to the table the jobs are in (msdb.sysjobs) and just dele
te the ones not belonging t
o this server?You need to update the originating_server column in sysjobs to reflect the
new server name, You can use this proc to do that
http://sqldev.net/download/sqlagent...gent_rename.sql
HTH
Jasper Smith (SQL Server MVP)
I support PASS - the definitive, global
community for SQL Server professionals -
http://www.sqlpass.org
"rich" <anonymous@.discussions.microsoft.com> wrote in message
news:437DE682-C216-4327-B318-85F47F64CD56@.microsoft.com...
> does anyone have a suggestion for this problem: somewhere along the line,
my database server changed names and now I have jobs I cannot delete out of
the Agent. Can I go to the table the jobs are in (msdb.sysjobs) and just
delete the ones not belonging to this server?
Friday, March 9, 2012
Removing null values from a result set
Hi,
I have following query which is returing null values along with other values. Could you please tell me how I can restrict to not to return null values
SELECT [Measures].[Total Hours] ON 0,
[Employee].[Hierarchy].[Employee Key]ON 1
FROM[Labor Metrics]
Thanks,
Prudhvi
Prud,
I'm assuming that you want to filter out TotalHours
SELECT [Measures].[Total Hours] ON 0,
[Employee].[Hierarchy].[Employee Key]ON 1
FROM[Labor Metrics]
Where [Measures].[Total Hours] is not null
Ham
|||Thanks Ham. I did tried this earlier but got the following error message
Executing the query ...
Query (5, 1) The IS function expects a member expression for the 2 argument. A string or numeric expression was used.
Execution complete
Prud,
Are you using SQL 2000 or SQL 2005? The "is not null" is a valid for SQL in the Where clause.
Ham
|||SSAS 2005 introduces a HAVING clause:
SELECT [Measures].[Total Hours] ON 0,
[Employee].[Hierarchy].[Employee Key]
HAVING [Measures].[Total Hours] <> 0 ON 1
FROM[Labor Metrics]
Or, you can use Filter().
|||Thanks Teo, it worked.