Showing posts with label update. Show all posts
Showing posts with label update. Show all posts

Sunday, March 25, 2012

Basic Example of Insert, Update Trigger

Hello, Can someone please show me a basic example of trigger that will
work with two tables in this manner:
1. On INSERT for Table1, copy a particular column's value to another
column in Table2
2. On UPDATE for Table1, copy this particular column's value to
another column in Table2.
The key field for both tables is Invoice# and will always exist in
both tables.
It seems like there are a couple ways to do this, one with just using
a join and the other using the 'Inserted' table. Could someone please
show me the best approach to this solution? I would really be grateful
and name my next born after you.
Thanks in advance,
Buster
On Jun 13, 6:51 am, Buster Coder <dice_respo...@.hotmail.com> wrote:
> Hello, Can someone please show me a basic example of trigger that will
> work with two tables in this manner:
> 1. On INSERT for Table1, copy a particular column's value to another
> column in Table2
> 2. On UPDATE for Table1, copy this particular column's value to
> another column in Table2.
> The key field for both tables is Invoice# and will always exist in
> both tables.
> It seems like there are a couple ways to do this, one with just using
> a join and the other using the 'Inserted' table. Could someone please
> show me the best approach to this solution? I would really be grateful
> and name my next born after you.
> Thanks in advance,
> Buster
I think you require update in table2 in both the cases
CREATE TRIGGER employee_insupd
ON table1
FOR INSERT, UPDATE
AS
UPDATE T2 SET
col2 = a.col1
FROM table2 T2 , inserted a
WHERE T2.invoiceno = a.invoiceno

Basic Example of Insert, Update Trigger

Hello, Can someone please show me a basic example of trigger that will
work with two tables in this manner:
1. On INSERT for Table1, copy a particular column's value to another
column in Table2
2. On UPDATE for Table1, copy this particular column's value to
another column in Table2.
The key field for both tables is Invoice# and will always exist in
both tables.
It seems like there are a couple ways to do this, one with just using
a join and the other using the 'Inserted' table. Could someone please
show me the best approach to this solution? I would really be grateful
and name my next born after you.
Thanks in advance,
BusterOn Jun 13, 6:51 am, Buster Coder <dice_respo...@.hotmail.com> wrote:
> Hello, Can someone please show me a basic example of trigger that will
> work with two tables in this manner:
> 1. On INSERT for Table1, copy a particular column's value to another
> column in Table2
> 2. On UPDATE for Table1, copy this particular column's value to
> another column in Table2.
> The key field for both tables is Invoice# and will always exist in
> both tables.
> It seems like there are a couple ways to do this, one with just using
> a join and the other using the 'Inserted' table. Could someone please
> show me the best approach to this solution? I would really be grateful
> and name my next born after you.
> Thanks in advance,
> Buster
I think you require update in table2 in both the cases
CREATE TRIGGER employee_insupd
ON table1
FOR INSERT, UPDATE
AS
UPDATE T2 SET
col2 = a.col1
FROM table2 T2 , inserted a
WHERE T2.invoiceno = a.invoicenosql

Basic Example of Insert, Update Trigger

Hello, Can someone please show me a basic example of trigger that will
work with two tables in this manner:
1. On INSERT for Table1, copy a particular column's value to another
column in Table2
2. On UPDATE for Table1, copy this particular column's value to
another column in Table2.
The key field for both tables is Invoice# and will always exist in
both tables.
It seems like there are a couple ways to do this, one with just using
a join and the other using the 'Inserted' table. Could someone please
show me the best approach to this solution? I would really be grateful
and name my next born after you.
Thanks in advance,
BusterOn Jun 13, 6:51 am, Buster Coder <dice_respo...@.hotmail.com> wrote:
> Hello, Can someone please show me a basic example of trigger that will
> work with two tables in this manner:
> 1. On INSERT for Table1, copy a particular column's value to another
> column in Table2
> 2. On UPDATE for Table1, copy this particular column's value to
> another column in Table2.
> The key field for both tables is Invoice# and will always exist in
> both tables.
> It seems like there are a couple ways to do this, one with just using
> a join and the other using the 'Inserted' table. Could someone please
> show me the best approach to this solution? I would really be grateful
> and name my next born after you.
> Thanks in advance,
> Buster
I think you require update in table2 in both the cases
CREATE TRIGGER employee_insupd
ON table1
FOR INSERT, UPDATE
AS
UPDATE T2 SET
col2 = a.col1
FROM table2 T2 , inserted a
WHERE T2.invoiceno = a.invoiceno

Tuesday, March 20, 2012

Bad Update Performance with very large recordsets

When updating a table with 80 million records we are experiencing very bad
times. We found using maxdop1 to keep the process in one thread helpful,
but something is still causing problems.
Updating one bigint field which is nullable to a bigint value from a table
inner joined with the current table is crawling.
Should we remove the nullability of the field and set it to a default of -1?
Would this ensure space is allocated for the field? What else can we look
for?
What about NO LOCK or Serializable? Could
What would be the *fastest* way to update records in a table assuming only 1
connection to the database? How do fields allowing NULLs affect this?
Thanks.Never try to update 80 million rows at once if you can avoid it. Wrap the
updates in smaller batches of say 10, 50 or 100K in size. If no one else
needs to use the table while this is happening you can use TABLOCK hint to
help.
--
Andrew J. Kelly
SQL Server MVP
"Kory Yingling" <kory@.removeme-mlsc.com> wrote in message
news:u$j1RcBbDHA.1744@.TK2MSFTNGP12.phx.gbl...
> When updating a table with 80 million records we are experiencing very bad
> times. We found using maxdop1 to keep the process in one thread helpful,
> but something is still causing problems.
> Updating one bigint field which is nullable to a bigint value from a table
> inner joined with the current table is crawling.
> Should we remove the nullability of the field and set it to a default
of -1?
> Would this ensure space is allocated for the field? What else can we look
> for?
> What about NO LOCK or Serializable? Could
> What would be the *fastest* way to update records in a table assuming only
1
> connection to the database? How do fields allowing NULLs affect this?
> Thanks.
>

Saturday, February 25, 2012

backups

I am unable to modify/delete a backup job for master database.
Error 14274: Cannot add, update or delete a job that originated from MSX
server.
??
Help!
Did you recently migrate the msdb database from another server? Are you the
DBA responsible for managing these?
You get that error for one of the two reasons above usually. The second one
happens when someone is using a single server to administer the jobs on
several servers.
If you look at the sysjobs table in the msdb database, you will see a column
called originating_server. That will be a different name then the instance
this msdb and master database reside on. If you update that column, you will
no longer get the error.
MeanOldDBA
derrickleggett@.hotmail.com
http://weblogs.sqlteam.com/derrickl
When life gives you a lemon, fire the DBA.
"docsql" wrote:

> I am unable to modify/delete a backup job for master database.
> Error 14274: Cannot add, update or delete a job that originated from MSX
> server.
> ??
> Help!
>
>
|||Hi,
You may also want to check if you encounter the following known issue:
281642 PRB: Error 14274 Occurs When You Update a SQL Agent Job After
Renaming
http://support.microsoft.com/?id=281642
Regards,
Peter Yang
MCSE2000/2003, MCSA, MCDBA
Microsoft Online Partner Support
When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
================================================== ===
================================================== ===
This posting is provided "AS IS" with no warranties, and confers no rights.
| Thread-Topic: backups
| thread-index: AcXK5VguhZxeuRlgTjiTogE3a78P6A==
| X-WBNR-Posting-Host: 65.69.68.118
| From: "=?Utf-8?B?TWVhbk9sZERCQQ==?="
<MeanOldDBA@.discussions.microsoft.com>
| References: <uPrUdQsyFHA.2072@.TK2MSFTNGP14.phx.gbl>
| Subject: RE: backups
| Date: Thu, 6 Oct 2005 19:18:02 -0700
| Lines: 33
| Message-ID: <7818BB22-C587-47F5-B487-3FC87D0513FD@.microsoft.com>
| MIME-Version: 1.0
| Content-Type: text/plain;
| charset="Utf-8"
| Content-Transfer-Encoding: 7bit
| X-Newsreader: Microsoft CDO for Windows 2000
| Content-Class: urn:content-classes:message
| Importance: normal
| Priority: normal
| X-MimeOLE: Produced By Microsoft MimeOLE V6.00.3790.0
| Newsgroups: microsoft.public.sqlserver.server
| NNTP-Posting-Host: TK2MSFTNGXA03.phx.gbl 10.40.2.250
| Path: TK2MSFTNGXA01.phx.gbl!TK2MSFTNGXA03.phx.gbl
| Xref: TK2MSFTNGXA01.phx.gbl microsoft.public.sqlserver.server:73344
| X-Tomcat-NG: microsoft.public.sqlserver.server
|
| Did you recently migrate the msdb database from another server? Are you
the
| DBA responsible for managing these?
|
| You get that error for one of the two reasons above usually. The second
one
| happens when someone is using a single server to administer the jobs on
| several servers.
|
| If you look at the sysjobs table in the msdb database, you will see a
column
| called originating_server. That will be a different name then the
instance
| this msdb and master database reside on. If you update that column, you
will
| no longer get the error.
|
| --
| MeanOldDBA
| derrickleggett@.hotmail.com
| http://weblogs.sqlteam.com/derrickl
|
| When life gives you a lemon, fire the DBA.
|
|
| "docsql" wrote:
|
| > I am unable to modify/delete a backup job for master database.
| >
| > Error 14274: Cannot add, update or delete a job that originated from
MSX
| > server.
| >
| > ??
| >
| > Help!
| >
| >
| >
|
|||... and this http://www.karaszi.com/SQLServer/inf...erver_name.asp
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"Peter Yang [MSFT]" <petery@.online.microsoft.com> wrote in message
news:pjczSIwyFHA.768@.TK2MSFTNGXA01.phx.gbl...
> Hi,
> You may also want to check if you encounter the following known issue:
> 281642 PRB: Error 14274 Occurs When You Update a SQL Agent Job After
> Renaming
> http://support.microsoft.com/?id=281642
> Regards,
> Peter Yang
> MCSE2000/2003, MCSA, MCDBA
> Microsoft Online Partner Support
> When responding to posts, please "Reply to Group" via your newsreader so
> that others may learn and benefit from your issue.
> ================================================== ===
> ================================================== ===
> This posting is provided "AS IS" with no warranties, and confers no rights.
> --
> | Thread-Topic: backups
> | thread-index: AcXK5VguhZxeuRlgTjiTogE3a78P6A==
> | X-WBNR-Posting-Host: 65.69.68.118
> | From: "=?Utf-8?B?TWVhbk9sZERCQQ==?="
> <MeanOldDBA@.discussions.microsoft.com>
> | References: <uPrUdQsyFHA.2072@.TK2MSFTNGP14.phx.gbl>
> | Subject: RE: backups
> | Date: Thu, 6 Oct 2005 19:18:02 -0700
> | Lines: 33
> | Message-ID: <7818BB22-C587-47F5-B487-3FC87D0513FD@.microsoft.com>
> | MIME-Version: 1.0
> | Content-Type: text/plain;
> | charset="Utf-8"
> | Content-Transfer-Encoding: 7bit
> | X-Newsreader: Microsoft CDO for Windows 2000
> | Content-Class: urn:content-classes:message
> | Importance: normal
> | Priority: normal
> | X-MimeOLE: Produced By Microsoft MimeOLE V6.00.3790.0
> | Newsgroups: microsoft.public.sqlserver.server
> | NNTP-Posting-Host: TK2MSFTNGXA03.phx.gbl 10.40.2.250
> | Path: TK2MSFTNGXA01.phx.gbl!TK2MSFTNGXA03.phx.gbl
> | Xref: TK2MSFTNGXA01.phx.gbl microsoft.public.sqlserver.server:73344
> | X-Tomcat-NG: microsoft.public.sqlserver.server
> |
> | Did you recently migrate the msdb database from another server? Are you
> the
> | DBA responsible for managing these?
> |
> | You get that error for one of the two reasons above usually. The second
> one
> | happens when someone is using a single server to administer the jobs on
> | several servers.
> |
> | If you look at the sysjobs table in the msdb database, you will see a
> column
> | called originating_server. That will be a different name then the
> instance
> | this msdb and master database reside on. If you update that column, you
> will
> | no longer get the error.
> |
> | --
> | MeanOldDBA
> | derrickleggett@.hotmail.com
> | http://weblogs.sqlteam.com/derrickl
> |
> | When life gives you a lemon, fire the DBA.
> |
> |
> | "docsql" wrote:
> |
> | > I am unable to modify/delete a backup job for master database.
> | >
> | > Error 14274: Cannot add, update or delete a job that originated from
> MSX
> | > server.
> | >
> | > ??
> | >
> | > Help!
> | >
> | >
> | >
> |
>
|||open sysjobs table
find the job that gives the error, the originating server field MUST be
different, change it to the current server name
finished
|||open msdb..sysjobs table
find the job that gives the error, the originating server field MUST be
different, change it to the current server name
finished
|||"docsql" <docsql@.noemail.nospam> wrote in message
news:uPrUdQsyFHA.2072@.TK2MSFTNGP14.phx.gbl...
>I am unable to modify/delete a backup job for master database.
> Error 14274: Cannot add, update or delete a job that originated from MSX
> server.
> ??
> Help!
>
|||http://www.karaszi.com/SQLServer/inf...erver_name.asp
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
Blog: http://solidqualitylearning.com/blogs/tibor/
"docsql" <docsql@.noemail.nospam> wrote in message news:eVx37BpzFHA.908@.tk2msftngp13.phx.gbl...
> "docsql" <docsql@.noemail.nospam> wrote in message
> news:uPrUdQsyFHA.2072@.TK2MSFTNGP14.phx.gbl...
>

Backups

I guess I'm not understander your responce. Do I need a
specific job to "Update statistics used by the query
optimizer"?
Are you asking a question or responding to the question already asked in this thread?
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"Lee" <anonymous@.discussions.microsoft.com> wrote in message
news:2479d01c45f79$e19f6de0$a501280a@.phx.gbl...
> I guess I'm not understander your responce. Do I need a
> specific job to "Update statistics used by the query
> optimizer"?

Backups

I guess I'm not understander your responce. Do I need a
specific job to "Update statistics used by the query
optimizer"?Are you asking a question or responding to the question already asked in thi
s thread?
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"Lee" <anonymous@.discussions.microsoft.com> wrote in message
news:2479d01c45f79$e19f6de0$a501280a@.phx
.gbl...
> I guess I'm not understander your responce. Do I need a
> specific job to "Update statistics used by the query
> optimizer"?

backups

I am unable to modify/delete a backup job for master database.
Error 14274: Cannot add, update or delete a job that originated from MSX
server.
'?
Help!Did you recently migrate the msdb database from another server? Are you the
DBA responsible for managing these?
You get that error for one of the two reasons above usually. The second one
happens when someone is using a single server to administer the jobs on
several servers.
If you look at the sysjobs table in the msdb database, you will see a column
called originating_server. That will be a different name then the instance
this msdb and master database reside on. If you update that column, you wil
l
no longer get the error.
MeanOldDBA
derrickleggett@.hotmail.com
http://weblogs.sqlteam.com/derrickl
When life gives you a lemon, fire the DBA.
"docsql" wrote:

> I am unable to modify/delete a backup job for master database.
> Error 14274: Cannot add, update or delete a job that originated from MSX
> server.
> '?
> Help!
>
>|||Hi,
You may also want to check if you encounter the following known issue:
281642 PRB: Error 14274 Occurs When You Update a SQL Agent Job After
Renaming
http://support.microsoft.com/?id=281642
Regards,
Peter Yang
MCSE2000/2003, MCSA, MCDBA
Microsoft Online Partner Support
When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
========================================
=============
========================================
=============
This posting is provided "AS IS" with no warranties, and confers no rights.
| Thread-Topic: backups
| thread-index: AcXK5VguhZxeuRlgTjiTogE3a78P6A==
| X-WBNR-Posting-Host: 65.69.68.118
| From: "examnotes"
<MeanOldDBA@.discussions.microsoft.com>
| References: <uPrUdQsyFHA.2072@.TK2MSFTNGP14.phx.gbl>
| Subject: RE: backups
| Date: Thu, 6 Oct 2005 19:18:02 -0700
| Lines: 33
| Message-ID: <7818BB22-C587-47F5-B487-3FC87D0513FD@.microsoft.com>
| MIME-Version: 1.0
| Content-Type: text/plain;
| charset="Utf-8"
| Content-Transfer-Encoding: 7bit
| X-Newsreader: Microsoft CDO for Windows 2000
| Content-Class: urn:content-classes:message
| Importance: normal
| Priority: normal
| X-MimeOLE: Produced By Microsoft MimeOLE V6.00.3790.0
| Newsgroups: microsoft.public.sqlserver.server
| NNTP-Posting-Host: TK2MSFTNGXA03.phx.gbl 10.40.2.250
| Path: TK2MSFTNGXA01.phx.gbl!TK2MSFTNGXA03.phx.gbl
| Xref: TK2MSFTNGXA01.phx.gbl microsoft.public.sqlserver.server:73344
| X-Tomcat-NG: microsoft.public.sqlserver.server
|
| Did you recently migrate the msdb database from another server? Are you
the
| DBA responsible for managing these?
|
| You get that error for one of the two reasons above usually. The second
one
| happens when someone is using a single server to administer the jobs on
| several servers.
|
| If you look at the sysjobs table in the msdb database, you will see a
column
| called originating_server. That will be a different name then the
instance
| this msdb and master database reside on. If you update that column, you
will
| no longer get the error.
|
| --
| MeanOldDBA
| derrickleggett@.hotmail.com
| http://weblogs.sqlteam.com/derrickl
|
| When life gives you a lemon, fire the DBA.
|
|
| "docsql" wrote:
|
| > I am unable to modify/delete a backup job for master database.
| >
| > Error 14274: Cannot add, update or delete a job that originated from
MSX
| > server.
| >
| > '?
| >
| > Help!
| >
| >
| >
||||... and this http://www.karaszi.com/SQLServer/in...server_name.asp
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"Peter Yang [MSFT]" <petery@.online.microsoft.com> wrote in message
news:pjczSIwyFHA.768@.TK2MSFTNGXA01.phx.gbl...
> Hi,
> You may also want to check if you encounter the following known issue:
> 281642 PRB: Error 14274 Occurs When You Update a SQL Agent Job After
> Renaming
> http://support.microsoft.com/?id=281642
> Regards,
> Peter Yang
> MCSE2000/2003, MCSA, MCDBA
> Microsoft Online Partner Support
> When responding to posts, please "Reply to Group" via your newsreader so
> that others may learn and benefit from your issue.
> ========================================
=============
> ========================================
=============
> This posting is provided "AS IS" with no warranties, and confers no rights
.
> --
> | Thread-Topic: backups
> | thread-index: AcXK5VguhZxeuRlgTjiTogE3a78P6A==
> | X-WBNR-Posting-Host: 65.69.68.118
> | From: "examnotes"
> <MeanOldDBA@.discussions.microsoft.com>
> | References: <uPrUdQsyFHA.2072@.TK2MSFTNGP14.phx.gbl>
> | Subject: RE: backups
> | Date: Thu, 6 Oct 2005 19:18:02 -0700
> | Lines: 33
> | Message-ID: <7818BB22-C587-47F5-B487-3FC87D0513FD@.microsoft.com>
> | MIME-Version: 1.0
> | Content-Type: text/plain;
> | charset="Utf-8"
> | Content-Transfer-Encoding: 7bit
> | X-Newsreader: Microsoft CDO for Windows 2000
> | Content-Class: urn:content-classes:message
> | Importance: normal
> | Priority: normal
> | X-MimeOLE: Produced By Microsoft MimeOLE V6.00.3790.0
> | Newsgroups: microsoft.public.sqlserver.server
> | NNTP-Posting-Host: TK2MSFTNGXA03.phx.gbl 10.40.2.250
> | Path: TK2MSFTNGXA01.phx.gbl!TK2MSFTNGXA03.phx.gbl
> | Xref: TK2MSFTNGXA01.phx.gbl microsoft.public.sqlserver.server:73344
> | X-Tomcat-NG: microsoft.public.sqlserver.server
> |
> | Did you recently migrate the msdb database from another server? Are you
> the
> | DBA responsible for managing these?
> |
> | You get that error for one of the two reasons above usually. The second
> one
> | happens when someone is using a single server to administer the jobs on
> | several servers.
> |
> | If you look at the sysjobs table in the msdb database, you will see a
> column
> | called originating_server. That will be a different name then the
> instance
> | this msdb and master database reside on. If you update that column, you
> will
> | no longer get the error.
> |
> | --
> | MeanOldDBA
> | derrickleggett@.hotmail.com
> | http://weblogs.sqlteam.com/derrickl
> |
> | When life gives you a lemon, fire the DBA.
> |
> |
> | "docsql" wrote:
> |
> | > I am unable to modify/delete a backup job for master database.
> | >
> | > Error 14274: Cannot add, update or delete a job that originated from
> MSX
> | > server.
> | >
> | > '?
> | >
> | > Help!
> | >
> | >
> | >
> |
>|||open sysjobs table
find the job that gives the error, the originating server field MUST be
different, change it to the current server name
finished|||open msdb..sysjobs table
find the job that gives the error, the originating server field MUST be
different, change it to the current server name
finished|||"docsql" <docsql@.noemail.nospam> wrote in message
news:uPrUdQsyFHA.2072@.TK2MSFTNGP14.phx.gbl...
>I am unable to modify/delete a backup job for master database.
> Error 14274: Cannot add, update or delete a job that originated from MSX
> server.
> '?
> Help!
>|||http://www.karaszi.com/SQLServer/in...server_name.asp
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
Blog: http://solidqualitylearning.com/blogs/tibor/
"docsql" <docsql@.noemail.nospam> wrote in message news:eVx37BpzFHA.908@.tk2msftngp13.phx.gbl.
.
> "docsql" <docsql@.noemail.nospam> wrote in message
> news:uPrUdQsyFHA.2072@.TK2MSFTNGP14.phx.gbl...
>

backups

I am unable to modify/delete a backup job for master database.
Error 14274: Cannot add, update or delete a job that originated from MSX
server.
'?
Help!Did you recently migrate the msdb database from another server? Are you the
DBA responsible for managing these?
You get that error for one of the two reasons above usually. The second one
happens when someone is using a single server to administer the jobs on
several servers.
If you look at the sysjobs table in the msdb database, you will see a column
called originating_server. That will be a different name then the instance
this msdb and master database reside on. If you update that column, you will
no longer get the error.
--
MeanOldDBA
derrickleggett@.hotmail.com
http://weblogs.sqlteam.com/derrickl
When life gives you a lemon, fire the DBA.
"docsql" wrote:
> I am unable to modify/delete a backup job for master database.
> Error 14274: Cannot add, update or delete a job that originated from MSX
> server.
> '?
> Help!
>
>|||Hi,
You may also want to check if you encounter the following known issue:
281642 PRB: Error 14274 Occurs When You Update a SQL Agent Job After
Renaming
http://support.microsoft.com/?id=281642
Regards,
Peter Yang
MCSE2000/2003, MCSA, MCDBA
Microsoft Online Partner Support
When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
=====================================================
=====================================================
This posting is provided "AS IS" with no warranties, and confers no rights.
--
| Thread-Topic: backups
| thread-index: AcXK5VguhZxeuRlgTjiTogE3a78P6A==| X-WBNR-Posting-Host: 65.69.68.118
| From: "=?Utf-8?B?TWVhbk9sZERCQQ==?="
<MeanOldDBA@.discussions.microsoft.com>
| References: <uPrUdQsyFHA.2072@.TK2MSFTNGP14.phx.gbl>
| Subject: RE: backups
| Date: Thu, 6 Oct 2005 19:18:02 -0700
| Lines: 33
| Message-ID: <7818BB22-C587-47F5-B487-3FC87D0513FD@.microsoft.com>
| MIME-Version: 1.0
| Content-Type: text/plain;
| charset="Utf-8"
| Content-Transfer-Encoding: 7bit
| X-Newsreader: Microsoft CDO for Windows 2000
| Content-Class: urn:content-classes:message
| Importance: normal
| Priority: normal
| X-MimeOLE: Produced By Microsoft MimeOLE V6.00.3790.0
| Newsgroups: microsoft.public.sqlserver.server
| NNTP-Posting-Host: TK2MSFTNGXA03.phx.gbl 10.40.2.250
| Path: TK2MSFTNGXA01.phx.gbl!TK2MSFTNGXA03.phx.gbl
| Xref: TK2MSFTNGXA01.phx.gbl microsoft.public.sqlserver.server:73344
| X-Tomcat-NG: microsoft.public.sqlserver.server
|
| Did you recently migrate the msdb database from another server? Are you
the
| DBA responsible for managing these?
|
| You get that error for one of the two reasons above usually. The second
one
| happens when someone is using a single server to administer the jobs on
| several servers.
|
| If you look at the sysjobs table in the msdb database, you will see a
column
| called originating_server. That will be a different name then the
instance
| this msdb and master database reside on. If you update that column, you
will
| no longer get the error.
|
| --
| MeanOldDBA
| derrickleggett@.hotmail.com
| http://weblogs.sqlteam.com/derrickl
|
| When life gives you a lemon, fire the DBA.
|
|
| "docsql" wrote:
|
| > I am unable to modify/delete a backup job for master database.
| >
| > Error 14274: Cannot add, update or delete a job that originated from
MSX
| > server.
| >
| > '?
| >
| > Help!
| >
| >
| >
||||... and this http://www.karaszi.com/SQLServer/info_change_server_name.asp
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"Peter Yang [MSFT]" <petery@.online.microsoft.com> wrote in message
news:pjczSIwyFHA.768@.TK2MSFTNGXA01.phx.gbl...
> Hi,
> You may also want to check if you encounter the following known issue:
> 281642 PRB: Error 14274 Occurs When You Update a SQL Agent Job After
> Renaming
> http://support.microsoft.com/?id=281642
> Regards,
> Peter Yang
> MCSE2000/2003, MCSA, MCDBA
> Microsoft Online Partner Support
> When responding to posts, please "Reply to Group" via your newsreader so
> that others may learn and benefit from your issue.
> =====================================================> =====================================================> This posting is provided "AS IS" with no warranties, and confers no rights.
> --
> | Thread-Topic: backups
> | thread-index: AcXK5VguhZxeuRlgTjiTogE3a78P6A==> | X-WBNR-Posting-Host: 65.69.68.118
> | From: "=?Utf-8?B?TWVhbk9sZERCQQ==?="
> <MeanOldDBA@.discussions.microsoft.com>
> | References: <uPrUdQsyFHA.2072@.TK2MSFTNGP14.phx.gbl>
> | Subject: RE: backups
> | Date: Thu, 6 Oct 2005 19:18:02 -0700
> | Lines: 33
> | Message-ID: <7818BB22-C587-47F5-B487-3FC87D0513FD@.microsoft.com>
> | MIME-Version: 1.0
> | Content-Type: text/plain;
> | charset="Utf-8"
> | Content-Transfer-Encoding: 7bit
> | X-Newsreader: Microsoft CDO for Windows 2000
> | Content-Class: urn:content-classes:message
> | Importance: normal
> | Priority: normal
> | X-MimeOLE: Produced By Microsoft MimeOLE V6.00.3790.0
> | Newsgroups: microsoft.public.sqlserver.server
> | NNTP-Posting-Host: TK2MSFTNGXA03.phx.gbl 10.40.2.250
> | Path: TK2MSFTNGXA01.phx.gbl!TK2MSFTNGXA03.phx.gbl
> | Xref: TK2MSFTNGXA01.phx.gbl microsoft.public.sqlserver.server:73344
> | X-Tomcat-NG: microsoft.public.sqlserver.server
> |
> | Did you recently migrate the msdb database from another server? Are you
> the
> | DBA responsible for managing these?
> |
> | You get that error for one of the two reasons above usually. The second
> one
> | happens when someone is using a single server to administer the jobs on
> | several servers.
> |
> | If you look at the sysjobs table in the msdb database, you will see a
> column
> | called originating_server. That will be a different name then the
> instance
> | this msdb and master database reside on. If you update that column, you
> will
> | no longer get the error.
> |
> | --
> | MeanOldDBA
> | derrickleggett@.hotmail.com
> | http://weblogs.sqlteam.com/derrickl
> |
> | When life gives you a lemon, fire the DBA.
> |
> |
> | "docsql" wrote:
> |
> | > I am unable to modify/delete a backup job for master database.
> | >
> | > Error 14274: Cannot add, update or delete a job that originated from
> MSX
> | > server.
> | >
> | > '?
> | >
> | > Help!
> | >
> | >
> | >
> |
>|||open sysjobs table
find the job that gives the error, the originating server field MUST be
different, change it to the current server name
finished|||open msdb..sysjobs table
find the job that gives the error, the originating server field MUST be
different, change it to the current server name
finished|||"docsql" <docsql@.noemail.nospam> wrote in message
news:uPrUdQsyFHA.2072@.TK2MSFTNGP14.phx.gbl...
>I am unable to modify/delete a backup job for master database.
> Error 14274: Cannot add, update or delete a job that originated from MSX
> server.
> '?
> Help!
>|||http://www.karaszi.com/SQLServer/info_change_server_name.asp
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
Blog: http://solidqualitylearning.com/blogs/tibor/
"docsql" <docsql@.noemail.nospam> wrote in message news:eVx37BpzFHA.908@.tk2msftngp13.phx.gbl...
> "docsql" <docsql@.noemail.nospam> wrote in message
> news:uPrUdQsyFHA.2072@.TK2MSFTNGP14.phx.gbl...
>>I am unable to modify/delete a backup job for master database.
>> Error 14274: Cannot add, update or delete a job that originated from MSX
>> server.
>> '?
>> Help!
>

Backups

I guess I'm not understander your responce. Do I need a
specific job to "Update statistics used by the query
optimizer"?Are you asking a question or responding to the question already asked in this thread?
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"Lee" <anonymous@.discussions.microsoft.com> wrote in message
news:2479d01c45f79$e19f6de0$a501280a@.phx.gbl...
> I guess I'm not understander your responce. Do I need a
> specific job to "Update statistics used by the query
> optimizer"?

Thursday, February 16, 2012

Backup, restore database online and offline

Hi all,
I have an application running on internet, it uses SQL server datatase.
I have an question want to as: can i backup database and update database online or offline?
Thanks.
TungNTSure you can but it depens on what exactly are you going to do.