Showing posts with label schedule. Show all posts
Showing posts with label schedule. Show all posts

Friday, March 30, 2012

running application

I need to run an application that sends out automatic emails based on
specific conditions. I need to schedule this to run every evening, could it
be scheduled as one of the SQL server agent jobs, using sql2000 or is there
another way to schedule it? Thanks.
Paul G
Software engineer.
That sounds like a strainghtforward job for SQLAgent.
Linchi
"Paul" wrote:

> I need to run an application that sends out automatic emails based on
> specific conditions. I need to schedule this to run every evening, could it
> be scheduled as one of the SQL server agent jobs, using sql2000 or is there
> another way to schedule it? Thanks.
> --
> Paul G
> Software engineer.
|||thanks for the response. I can not use windows scheduler because of computer
restrictions but for example what command in SQL would I use to run the
executable called test.exe located at C:\?
Doesn't it have to be transact SQL to run out SQlAgent?
Paul.
Paul G
Software engineer.
"Linchi Shea" wrote:
[vbcol=seagreen]
> That sounds like a strainghtforward job for SQLAgent.
> Linchi
> "Paul" wrote:
|||Thanks for the response. I am using SQL 2000 but under the step types I only
see the following listed;
Replication Transaction-Log Reader
Replication Queue Reader
Replication Snapshot
Replication Merge
Tansact-SQL script
did not see a cmdExec type.
Paul G
Software engineer.
"Tibor Karaszi" wrote:

> A job has one or more jobsteps. There are different type of jobsteps. TSQL is for executing SQL
> commands, while CmdExec is for executing EXE files etc.
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://sqlblog.com/blogs/tibor_karaszi
>
> "Paul" <Paul@.discussions.microsoft.com> wrote in message
> news:4310F194-2BAB-4F52-BE75-4A6D019A3388@.microsoft.com...
>
|||Scroll up in the drop-down list, and you'll see it.
Linchi
"Paul" wrote:
[vbcol=seagreen]
> Thanks for the response. I am using SQL 2000 but under the step types I only
> see the following listed;
> Replication Transaction-Log Reader
> Replication Queue Reader
> Replication Snapshot
> Replication Merge
> Tansact-SQL script
> did not see a cmdExec type.
>
>
> --
> Paul G
> Software engineer.
>
> "Tibor Karaszi" wrote:
|||found it, thanks! so for the command I just use c:/test.exe to run the
executable called test.exe at location c:?
Paul G
Software engineer.
"Linchi Shea" wrote:
[vbcol=seagreen]
> Scroll up in the drop-down list, and you'll see it.
> Linchi
> "Paul" wrote:
|||Try it and see. Better yet, reference Books Online (for 2005 the link is
ms-help://MS.SQLCC.v9/MS.SQLSVR.v9.en/udb9/html/51352afc-a0a4-428b-8985-f9e58bb57c31.htm)
and see the explicit example there.
BOL are your friend!
Kevin G. Boles
Indicium Resources, Inc.
SQL Server MVP
kgboles a earthlink dt net
"Paul" <Paul@.discussions.microsoft.com> wrote in message
news:9FBC9A5D-3985-40F5-A268-45F2AEC68CBA@.microsoft.com...[vbcol=seagreen]
> found it, thanks! so for the command I just use c:/test.exe to run the
> executable called test.exe at location c:?
> --
> Paul G
> Software engineer.
>
> "Linchi Shea" wrote:
|||I currently have it has a windows app but I have the window closing at the
end of the program so no gui is left open.
Paul G
Software engineer.
"Tibor Karaszi" wrote:

> Yep. Just make sure that the program is a console program (no GUI element), since it is started by a
> service...
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://sqlblog.com/blogs/tibor_karaszi
>
> "Paul" <Paul@.discussions.microsoft.com> wrote in message
> news:9FBC9A5D-3985-40F5-A268-45F2AEC68CBA@.microsoft.com...
>
|||yep the books on line are quite helpful although sometimes I have difficulty
comming up with the correct search string. thanks.
Paul G
Software engineer.
"TheSQLGuru" wrote:

> Try it and see. Better yet, reference Books Online (for 2005 the link is
> ms-help://MS.SQLCC.v9/MS.SQLSVR.v9.en/udb9/html/51352afc-a0a4-428b-8985-f9e58bb57c31.htm)
> and see the explicit example there.
> BOL are your friend!
> --
> Kevin G. Boles
> Indicium Resources, Inc.
> SQL Server MVP
> kgboles a earthlink dt net
>
> "Paul" <Paul@.discussions.microsoft.com> wrote in message
> news:9FBC9A5D-3985-40F5-A268-45F2AEC68CBA@.microsoft.com...
>
>
|||ok thanks I will try it, just wondering if it will work, I can just as easily
create a new console application with vs.net as well.
Paul G
Software engineer.
"Tibor Karaszi" wrote:

> That will probably not work, since a service has no window context at all. I.e., the windows API
> calls will make the program fail. But you could give it a go and see what happens.
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://sqlblog.com/blogs/tibor_karaszi
>
> "Paul" <Paul@.discussions.microsoft.com> wrote in message
> news:F605C191-3233-42B2-BB7A-41D9A6D1D9E5@.microsoft.com...
>

running application

I need to run an application that sends out automatic emails based on
specific conditions. I need to schedule this to run every evening, could it
be scheduled as one of the SQL server agent jobs, using sql2000 or is there
another way to schedule it? Thanks.
--
Paul G
Software engineer.That sounds like a strainghtforward job for SQLAgent.
Linchi
"Paul" wrote:
> I need to run an application that sends out automatic emails based on
> specific conditions. I need to schedule this to run every evening, could it
> be scheduled as one of the SQL server agent jobs, using sql2000 or is there
> another way to schedule it? Thanks.
> --
> Paul G
> Software engineer.|||thanks for the response. I can not use windows scheduler because of computer
restrictions but for example what command in SQL would I use to run the
executable called test.exe located at C:\?
Doesn't it have to be transact SQL to run out SQlAgent?
Paul.
--
Paul G
Software engineer.
"Linchi Shea" wrote:
> That sounds like a strainghtforward job for SQLAgent.
> Linchi
> "Paul" wrote:
> > I need to run an application that sends out automatic emails based on
> > specific conditions. I need to schedule this to run every evening, could it
> > be scheduled as one of the SQL server agent jobs, using sql2000 or is there
> > another way to schedule it? Thanks.
> > --
> > Paul G
> > Software engineer.|||A job has one or more jobsteps. There are different type of jobsteps. TSQL is for executing SQL
commands, while CmdExec is for executing EXE files etc.
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://sqlblog.com/blogs/tibor_karaszi
"Paul" <Paul@.discussions.microsoft.com> wrote in message
news:4310F194-2BAB-4F52-BE75-4A6D019A3388@.microsoft.com...
> thanks for the response. I can not use windows scheduler because of computer
> restrictions but for example what command in SQL would I use to run the
> executable called test.exe located at C:\?
> Doesn't it have to be transact SQL to run out SQlAgent?
> Paul.
> --
> Paul G
> Software engineer.
>
> "Linchi Shea" wrote:
>> That sounds like a strainghtforward job for SQLAgent.
>> Linchi
>> "Paul" wrote:
>> > I need to run an application that sends out automatic emails based on
>> > specific conditions. I need to schedule this to run every evening, could it
>> > be scheduled as one of the SQL server agent jobs, using sql2000 or is there
>> > another way to schedule it? Thanks.
>> > --
>> > Paul G
>> > Software engineer.|||Thanks for the response. I am using SQL 2000 but under the step types I only
see the following listed;
Replication Transaction-Log Reader
Replication Queue Reader
Replication Snapshot
Replication Merge
Tansact-SQL script
did not see a cmdExec type.
Paul G
Software engineer.
"Tibor Karaszi" wrote:
> A job has one or more jobsteps. There are different type of jobsteps. TSQL is for executing SQL
> commands, while CmdExec is for executing EXE files etc.
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://sqlblog.com/blogs/tibor_karaszi
>
> "Paul" <Paul@.discussions.microsoft.com> wrote in message
> news:4310F194-2BAB-4F52-BE75-4A6D019A3388@.microsoft.com...
> > thanks for the response. I can not use windows scheduler because of computer
> > restrictions but for example what command in SQL would I use to run the
> > executable called test.exe located at C:\?
> > Doesn't it have to be transact SQL to run out SQlAgent?
> >
> > Paul.
> > --
> > Paul G
> > Software engineer.
> >
> >
> > "Linchi Shea" wrote:
> >
> >> That sounds like a strainghtforward job for SQLAgent.
> >>
> >> Linchi
> >>
> >> "Paul" wrote:
> >>
> >> > I need to run an application that sends out automatic emails based on
> >> > specific conditions. I need to schedule this to run every evening, could it
> >> > be scheduled as one of the SQL server agent jobs, using sql2000 or is there
> >> > another way to schedule it? Thanks.
> >> > --
> >> > Paul G
> >> > Software engineer.
>|||Scroll up in the drop-down list, and you'll see it.
Linchi
"Paul" wrote:
> Thanks for the response. I am using SQL 2000 but under the step types I only
> see the following listed;
> Replication Transaction-Log Reader
> Replication Queue Reader
> Replication Snapshot
> Replication Merge
> Tansact-SQL script
> did not see a cmdExec type.
>
>
> --
> Paul G
> Software engineer.
>
> "Tibor Karaszi" wrote:
> > A job has one or more jobsteps. There are different type of jobsteps. TSQL is for executing SQL
> > commands, while CmdExec is for executing EXE files etc.
> >
> > --
> > Tibor Karaszi, SQL Server MVP
> > http://www.karaszi.com/sqlserver/default.asp
> > http://sqlblog.com/blogs/tibor_karaszi
> >
> >
> > "Paul" <Paul@.discussions.microsoft.com> wrote in message
> > news:4310F194-2BAB-4F52-BE75-4A6D019A3388@.microsoft.com...
> > > thanks for the response. I can not use windows scheduler because of computer
> > > restrictions but for example what command in SQL would I use to run the
> > > executable called test.exe located at C:\?
> > > Doesn't it have to be transact SQL to run out SQlAgent?
> > >
> > > Paul.
> > > --
> > > Paul G
> > > Software engineer.
> > >
> > >
> > > "Linchi Shea" wrote:
> > >
> > >> That sounds like a strainghtforward job for SQLAgent.
> > >>
> > >> Linchi
> > >>
> > >> "Paul" wrote:
> > >>
> > >> > I need to run an application that sends out automatic emails based on
> > >> > specific conditions. I need to schedule this to run every evening, could it
> > >> > be scheduled as one of the SQL server agent jobs, using sql2000 or is there
> > >> > another way to schedule it? Thanks.
> > >> > --
> > >> > Paul G
> > >> > Software engineer.
> >|||found it, thanks! so for the command I just use c:/test.exe to run the
executable called test.exe at location c:?
--
Paul G
Software engineer.
"Linchi Shea" wrote:
> Scroll up in the drop-down list, and you'll see it.
> Linchi
> "Paul" wrote:
> > Thanks for the response. I am using SQL 2000 but under the step types I only
> > see the following listed;
> > Replication Transaction-Log Reader
> > Replication Queue Reader
> > Replication Snapshot
> > Replication Merge
> > Tansact-SQL script
> > did not see a cmdExec type.
> >
> >
> >
> >
> >
> > --
> > Paul G
> > Software engineer.
> >
> >
> > "Tibor Karaszi" wrote:
> >
> > > A job has one or more jobsteps. There are different type of jobsteps. TSQL is for executing SQL
> > > commands, while CmdExec is for executing EXE files etc.
> > >
> > > --
> > > Tibor Karaszi, SQL Server MVP
> > > http://www.karaszi.com/sqlserver/default.asp
> > > http://sqlblog.com/blogs/tibor_karaszi
> > >
> > >
> > > "Paul" <Paul@.discussions.microsoft.com> wrote in message
> > > news:4310F194-2BAB-4F52-BE75-4A6D019A3388@.microsoft.com...
> > > > thanks for the response. I can not use windows scheduler because of computer
> > > > restrictions but for example what command in SQL would I use to run the
> > > > executable called test.exe located at C:\?
> > > > Doesn't it have to be transact SQL to run out SQlAgent?
> > > >
> > > > Paul.
> > > > --
> > > > Paul G
> > > > Software engineer.
> > > >
> > > >
> > > > "Linchi Shea" wrote:
> > > >
> > > >> That sounds like a strainghtforward job for SQLAgent.
> > > >>
> > > >> Linchi
> > > >>
> > > >> "Paul" wrote:
> > > >>
> > > >> > I need to run an application that sends out automatic emails based on
> > > >> > specific conditions. I need to schedule this to run every evening, could it
> > > >> > be scheduled as one of the SQL server agent jobs, using sql2000 or is there
> > > >> > another way to schedule it? Thanks.
> > > >> > --
> > > >> > Paul G
> > > >> > Software engineer.
> > >|||Yep. Just make sure that the program is a console program (no GUI element), since it is started by a
service...
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://sqlblog.com/blogs/tibor_karaszi
"Paul" <Paul@.discussions.microsoft.com> wrote in message
news:9FBC9A5D-3985-40F5-A268-45F2AEC68CBA@.microsoft.com...
> found it, thanks! so for the command I just use c:/test.exe to run the
> executable called test.exe at location c:?
> --
> Paul G
> Software engineer.
>
> "Linchi Shea" wrote:
>> Scroll up in the drop-down list, and you'll see it.
>> Linchi
>> "Paul" wrote:
>> > Thanks for the response. I am using SQL 2000 but under the step types I only
>> > see the following listed;
>> > Replication Transaction-Log Reader
>> > Replication Queue Reader
>> > Replication Snapshot
>> > Replication Merge
>> > Tansact-SQL script
>> > did not see a cmdExec type.
>> >
>> >
>> >
>> >
>> >
>> > --
>> > Paul G
>> > Software engineer.
>> >
>> >
>> > "Tibor Karaszi" wrote:
>> >
>> > > A job has one or more jobsteps. There are different type of jobsteps. TSQL is for executing
>> > > SQL
>> > > commands, while CmdExec is for executing EXE files etc.
>> > >
>> > > --
>> > > Tibor Karaszi, SQL Server MVP
>> > > http://www.karaszi.com/sqlserver/default.asp
>> > > http://sqlblog.com/blogs/tibor_karaszi
>> > >
>> > >
>> > > "Paul" <Paul@.discussions.microsoft.com> wrote in message
>> > > news:4310F194-2BAB-4F52-BE75-4A6D019A3388@.microsoft.com...
>> > > > thanks for the response. I can not use windows scheduler because of computer
>> > > > restrictions but for example what command in SQL would I use to run the
>> > > > executable called test.exe located at C:\?
>> > > > Doesn't it have to be transact SQL to run out SQlAgent?
>> > > >
>> > > > Paul.
>> > > > --
>> > > > Paul G
>> > > > Software engineer.
>> > > >
>> > > >
>> > > > "Linchi Shea" wrote:
>> > > >
>> > > >> That sounds like a strainghtforward job for SQLAgent.
>> > > >>
>> > > >> Linchi
>> > > >>
>> > > >> "Paul" wrote:
>> > > >>
>> > > >> > I need to run an application that sends out automatic emails based on
>> > > >> > specific conditions. I need to schedule this to run every evening, could it
>> > > >> > be scheduled as one of the SQL server agent jobs, using sql2000 or is there
>> > > >> > another way to schedule it? Thanks.
>> > > >> > --
>> > > >> > Paul G
>> > > >> > Software engineer.
>> > >|||Try it and see. Better yet, reference Books Online (for 2005 the link is
ms-help://MS.SQLCC.v9/MS.SQLSVR.v9.en/udb9/html/51352afc-a0a4-428b-8985-f9e58bb57c31.htm)
and see the explicit example there.
BOL are your friend!
--
Kevin G. Boles
Indicium Resources, Inc.
SQL Server MVP
kgboles a earthlink dt net
"Paul" <Paul@.discussions.microsoft.com> wrote in message
news:9FBC9A5D-3985-40F5-A268-45F2AEC68CBA@.microsoft.com...
> found it, thanks! so for the command I just use c:/test.exe to run the
> executable called test.exe at location c:?
> --
> Paul G
> Software engineer.
>
> "Linchi Shea" wrote:
>> Scroll up in the drop-down list, and you'll see it.
>> Linchi
>> "Paul" wrote:
>> > Thanks for the response. I am using SQL 2000 but under the step types
>> > I only
>> > see the following listed;
>> > Replication Transaction-Log Reader
>> > Replication Queue Reader
>> > Replication Snapshot
>> > Replication Merge
>> > Tansact-SQL script
>> > did not see a cmdExec type.
>> >
>> >
>> >
>> >
>> >
>> > --
>> > Paul G
>> > Software engineer.
>> >
>> >
>> > "Tibor Karaszi" wrote:
>> >
>> > > A job has one or more jobsteps. There are different type of jobsteps.
>> > > TSQL is for executing SQL
>> > > commands, while CmdExec is for executing EXE files etc.
>> > >
>> > > --
>> > > Tibor Karaszi, SQL Server MVP
>> > > http://www.karaszi.com/sqlserver/default.asp
>> > > http://sqlblog.com/blogs/tibor_karaszi
>> > >
>> > >
>> > > "Paul" <Paul@.discussions.microsoft.com> wrote in message
>> > > news:4310F194-2BAB-4F52-BE75-4A6D019A3388@.microsoft.com...
>> > > > thanks for the response. I can not use windows scheduler because
>> > > > of computer
>> > > > restrictions but for example what command in SQL would I use to run
>> > > > the
>> > > > executable called test.exe located at C:\?
>> > > > Doesn't it have to be transact SQL to run out SQlAgent?
>> > > >
>> > > > Paul.
>> > > > --
>> > > > Paul G
>> > > > Software engineer.
>> > > >
>> > > >
>> > > > "Linchi Shea" wrote:
>> > > >
>> > > >> That sounds like a strainghtforward job for SQLAgent.
>> > > >>
>> > > >> Linchi
>> > > >>
>> > > >> "Paul" wrote:
>> > > >>
>> > > >> > I need to run an application that sends out automatic emails
>> > > >> > based on
>> > > >> > specific conditions. I need to schedule this to run every
>> > > >> > evening, could it
>> > > >> > be scheduled as one of the SQL server agent jobs, using sql2000
>> > > >> > or is there
>> > > >> > another way to schedule it? Thanks.
>> > > >> > --
>> > > >> > Paul G
>> > > >> > Software engineer.
>> > >|||I currently have it has a windows app but I have the window closing at the
end of the program so no gui is left open.
--
Paul G
Software engineer.
"Tibor Karaszi" wrote:
> Yep. Just make sure that the program is a console program (no GUI element), since it is started by a
> service...
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://sqlblog.com/blogs/tibor_karaszi
>
> "Paul" <Paul@.discussions.microsoft.com> wrote in message
> news:9FBC9A5D-3985-40F5-A268-45F2AEC68CBA@.microsoft.com...
> > found it, thanks! so for the command I just use c:/test.exe to run the
> > executable called test.exe at location c:?
> > --
> > Paul G
> > Software engineer.
> >
> >
> > "Linchi Shea" wrote:
> >
> >> Scroll up in the drop-down list, and you'll see it.
> >>
> >> Linchi
> >>
> >> "Paul" wrote:
> >>
> >> > Thanks for the response. I am using SQL 2000 but under the step types I only
> >> > see the following listed;
> >> > Replication Transaction-Log Reader
> >> > Replication Queue Reader
> >> > Replication Snapshot
> >> > Replication Merge
> >> > Tansact-SQL script
> >> > did not see a cmdExec type.
> >> >
> >> >
> >> >
> >> >
> >> >
> >> > --
> >> > Paul G
> >> > Software engineer.
> >> >
> >> >
> >> > "Tibor Karaszi" wrote:
> >> >
> >> > > A job has one or more jobsteps. There are different type of jobsteps. TSQL is for executing
> >> > > SQL
> >> > > commands, while CmdExec is for executing EXE files etc.
> >> > >
> >> > > --
> >> > > Tibor Karaszi, SQL Server MVP
> >> > > http://www.karaszi.com/sqlserver/default.asp
> >> > > http://sqlblog.com/blogs/tibor_karaszi
> >> > >
> >> > >
> >> > > "Paul" <Paul@.discussions.microsoft.com> wrote in message
> >> > > news:4310F194-2BAB-4F52-BE75-4A6D019A3388@.microsoft.com...
> >> > > > thanks for the response. I can not use windows scheduler because of computer
> >> > > > restrictions but for example what command in SQL would I use to run the
> >> > > > executable called test.exe located at C:\?
> >> > > > Doesn't it have to be transact SQL to run out SQlAgent?
> >> > > >
> >> > > > Paul.
> >> > > > --
> >> > > > Paul G
> >> > > > Software engineer.
> >> > > >
> >> > > >
> >> > > > "Linchi Shea" wrote:
> >> > > >
> >> > > >> That sounds like a strainghtforward job for SQLAgent.
> >> > > >>
> >> > > >> Linchi
> >> > > >>
> >> > > >> "Paul" wrote:
> >> > > >>
> >> > > >> > I need to run an application that sends out automatic emails based on
> >> > > >> > specific conditions. I need to schedule this to run every evening, could it
> >> > > >> > be scheduled as one of the SQL server agent jobs, using sql2000 or is there
> >> > > >> > another way to schedule it? Thanks.
> >> > > >> > --
> >> > > >> > Paul G
> >> > > >> > Software engineer.
> >> > >
>|||yep the books on line are quite helpful although sometimes I have difficulty
comming up with the correct search string. thanks.
--
Paul G
Software engineer.
"TheSQLGuru" wrote:
> Try it and see. Better yet, reference Books Online (for 2005 the link is
> ms-help://MS.SQLCC.v9/MS.SQLSVR.v9.en/udb9/html/51352afc-a0a4-428b-8985-f9e58bb57c31.htm)
> and see the explicit example there.
> BOL are your friend!
> --
> Kevin G. Boles
> Indicium Resources, Inc.
> SQL Server MVP
> kgboles a earthlink dt net
>
> "Paul" <Paul@.discussions.microsoft.com> wrote in message
> news:9FBC9A5D-3985-40F5-A268-45F2AEC68CBA@.microsoft.com...
> > found it, thanks! so for the command I just use c:/test.exe to run the
> > executable called test.exe at location c:?
> > --
> > Paul G
> > Software engineer.
> >
> >
> > "Linchi Shea" wrote:
> >
> >> Scroll up in the drop-down list, and you'll see it.
> >>
> >> Linchi
> >>
> >> "Paul" wrote:
> >>
> >> > Thanks for the response. I am using SQL 2000 but under the step types
> >> > I only
> >> > see the following listed;
> >> > Replication Transaction-Log Reader
> >> > Replication Queue Reader
> >> > Replication Snapshot
> >> > Replication Merge
> >> > Tansact-SQL script
> >> > did not see a cmdExec type.
> >> >
> >> >
> >> >
> >> >
> >> >
> >> > --
> >> > Paul G
> >> > Software engineer.
> >> >
> >> >
> >> > "Tibor Karaszi" wrote:
> >> >
> >> > > A job has one or more jobsteps. There are different type of jobsteps.
> >> > > TSQL is for executing SQL
> >> > > commands, while CmdExec is for executing EXE files etc.
> >> > >
> >> > > --
> >> > > Tibor Karaszi, SQL Server MVP
> >> > > http://www.karaszi.com/sqlserver/default.asp
> >> > > http://sqlblog.com/blogs/tibor_karaszi
> >> > >
> >> > >
> >> > > "Paul" <Paul@.discussions.microsoft.com> wrote in message
> >> > > news:4310F194-2BAB-4F52-BE75-4A6D019A3388@.microsoft.com...
> >> > > > thanks for the response. I can not use windows scheduler because
> >> > > > of computer
> >> > > > restrictions but for example what command in SQL would I use to run
> >> > > > the
> >> > > > executable called test.exe located at C:\?
> >> > > > Doesn't it have to be transact SQL to run out SQlAgent?
> >> > > >
> >> > > > Paul.
> >> > > > --
> >> > > > Paul G
> >> > > > Software engineer.
> >> > > >
> >> > > >
> >> > > > "Linchi Shea" wrote:
> >> > > >
> >> > > >> That sounds like a strainghtforward job for SQLAgent.
> >> > > >>
> >> > > >> Linchi
> >> > > >>
> >> > > >> "Paul" wrote:
> >> > > >>
> >> > > >> > I need to run an application that sends out automatic emails
> >> > > >> > based on
> >> > > >> > specific conditions. I need to schedule this to run every
> >> > > >> > evening, could it
> >> > > >> > be scheduled as one of the SQL server agent jobs, using sql2000
> >> > > >> > or is there
> >> > > >> > another way to schedule it? Thanks.
> >> > > >> > --
> >> > > >> > Paul G
> >> > > >> > Software engineer.
> >> > >
>
>|||That will probably not work, since a service has no window context at all. I.e., the windows API
calls will make the program fail. But you could give it a go and see what happens.
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://sqlblog.com/blogs/tibor_karaszi
"Paul" <Paul@.discussions.microsoft.com> wrote in message
news:F605C191-3233-42B2-BB7A-41D9A6D1D9E5@.microsoft.com...
>I currently have it has a windows app but I have the window closing at the
> end of the program so no gui is left open.
> --
> Paul G
> Software engineer.
>
> "Tibor Karaszi" wrote:
>> Yep. Just make sure that the program is a console program (no GUI element), since it is started
>> by a
>> service...
>> --
>> Tibor Karaszi, SQL Server MVP
>> http://www.karaszi.com/sqlserver/default.asp
>> http://sqlblog.com/blogs/tibor_karaszi
>>
>> "Paul" <Paul@.discussions.microsoft.com> wrote in message
>> news:9FBC9A5D-3985-40F5-A268-45F2AEC68CBA@.microsoft.com...
>> > found it, thanks! so for the command I just use c:/test.exe to run the
>> > executable called test.exe at location c:?
>> > --
>> > Paul G
>> > Software engineer.
>> >
>> >
>> > "Linchi Shea" wrote:
>> >
>> >> Scroll up in the drop-down list, and you'll see it.
>> >>
>> >> Linchi
>> >>
>> >> "Paul" wrote:
>> >>
>> >> > Thanks for the response. I am using SQL 2000 but under the step types I only
>> >> > see the following listed;
>> >> > Replication Transaction-Log Reader
>> >> > Replication Queue Reader
>> >> > Replication Snapshot
>> >> > Replication Merge
>> >> > Tansact-SQL script
>> >> > did not see a cmdExec type.
>> >> >
>> >> >
>> >> >
>> >> >
>> >> >
>> >> > --
>> >> > Paul G
>> >> > Software engineer.
>> >> >
>> >> >
>> >> > "Tibor Karaszi" wrote:
>> >> >
>> >> > > A job has one or more jobsteps. There are different type of jobsteps. TSQL is for
>> >> > > executing
>> >> > > SQL
>> >> > > commands, while CmdExec is for executing EXE files etc.
>> >> > >
>> >> > > --
>> >> > > Tibor Karaszi, SQL Server MVP
>> >> > > http://www.karaszi.com/sqlserver/default.asp
>> >> > > http://sqlblog.com/blogs/tibor_karaszi
>> >> > >
>> >> > >
>> >> > > "Paul" <Paul@.discussions.microsoft.com> wrote in message
>> >> > > news:4310F194-2BAB-4F52-BE75-4A6D019A3388@.microsoft.com...
>> >> > > > thanks for the response. I can not use windows scheduler because of computer
>> >> > > > restrictions but for example what command in SQL would I use to run the
>> >> > > > executable called test.exe located at C:\?
>> >> > > > Doesn't it have to be transact SQL to run out SQlAgent?
>> >> > > >
>> >> > > > Paul.
>> >> > > > --
>> >> > > > Paul G
>> >> > > > Software engineer.
>> >> > > >
>> >> > > >
>> >> > > > "Linchi Shea" wrote:
>> >> > > >
>> >> > > >> That sounds like a strainghtforward job for SQLAgent.
>> >> > > >>
>> >> > > >> Linchi
>> >> > > >>
>> >> > > >> "Paul" wrote:
>> >> > > >>
>> >> > > >> > I need to run an application that sends out automatic emails based on
>> >> > > >> > specific conditions. I need to schedule this to run every evening, could it
>> >> > > >> > be scheduled as one of the SQL server agent jobs, using sql2000 or is there
>> >> > > >> > another way to schedule it? Thanks.
>> >> > > >> > --
>> >> > > >> > Paul G
>> >> > > >> > Software engineer.
>> >> > >|||ok thanks I will try it, just wondering if it will work, I can just as easily
create a new console application with vs.net as well.
--
Paul G
Software engineer.
"Tibor Karaszi" wrote:
> That will probably not work, since a service has no window context at all. I.e., the windows API
> calls will make the program fail. But you could give it a go and see what happens.
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://sqlblog.com/blogs/tibor_karaszi
>
> "Paul" <Paul@.discussions.microsoft.com> wrote in message
> news:F605C191-3233-42B2-BB7A-41D9A6D1D9E5@.microsoft.com...
> >I currently have it has a windows app but I have the window closing at the
> > end of the program so no gui is left open.
> > --
> > Paul G
> > Software engineer.
> >
> >
> > "Tibor Karaszi" wrote:
> >
> >> Yep. Just make sure that the program is a console program (no GUI element), since it is started
> >> by a
> >> service...
> >>
> >> --
> >> Tibor Karaszi, SQL Server MVP
> >> http://www.karaszi.com/sqlserver/default.asp
> >> http://sqlblog.com/blogs/tibor_karaszi
> >>
> >>
> >> "Paul" <Paul@.discussions.microsoft.com> wrote in message
> >> news:9FBC9A5D-3985-40F5-A268-45F2AEC68CBA@.microsoft.com...
> >> > found it, thanks! so for the command I just use c:/test.exe to run the
> >> > executable called test.exe at location c:?
> >> > --
> >> > Paul G
> >> > Software engineer.
> >> >
> >> >
> >> > "Linchi Shea" wrote:
> >> >
> >> >> Scroll up in the drop-down list, and you'll see it.
> >> >>
> >> >> Linchi
> >> >>
> >> >> "Paul" wrote:
> >> >>
> >> >> > Thanks for the response. I am using SQL 2000 but under the step types I only
> >> >> > see the following listed;
> >> >> > Replication Transaction-Log Reader
> >> >> > Replication Queue Reader
> >> >> > Replication Snapshot
> >> >> > Replication Merge
> >> >> > Tansact-SQL script
> >> >> > did not see a cmdExec type.
> >> >> >
> >> >> >
> >> >> >
> >> >> >
> >> >> >
> >> >> > --
> >> >> > Paul G
> >> >> > Software engineer.
> >> >> >
> >> >> >
> >> >> > "Tibor Karaszi" wrote:
> >> >> >
> >> >> > > A job has one or more jobsteps. There are different type of jobsteps. TSQL is for
> >> >> > > executing
> >> >> > > SQL
> >> >> > > commands, while CmdExec is for executing EXE files etc.
> >> >> > >
> >> >> > > --
> >> >> > > Tibor Karaszi, SQL Server MVP
> >> >> > > http://www.karaszi.com/sqlserver/default.asp
> >> >> > > http://sqlblog.com/blogs/tibor_karaszi
> >> >> > >
> >> >> > >
> >> >> > > "Paul" <Paul@.discussions.microsoft.com> wrote in message
> >> >> > > news:4310F194-2BAB-4F52-BE75-4A6D019A3388@.microsoft.com...
> >> >> > > > thanks for the response. I can not use windows scheduler because of computer
> >> >> > > > restrictions but for example what command in SQL would I use to run the
> >> >> > > > executable called test.exe located at C:\?
> >> >> > > > Doesn't it have to be transact SQL to run out SQlAgent?
> >> >> > > >
> >> >> > > > Paul.
> >> >> > > > --
> >> >> > > > Paul G
> >> >> > > > Software engineer.
> >> >> > > >
> >> >> > > >
> >> >> > > > "Linchi Shea" wrote:
> >> >> > > >
> >> >> > > >> That sounds like a strainghtforward job for SQLAgent.
> >> >> > > >>
> >> >> > > >> Linchi
> >> >> > > >>
> >> >> > > >> "Paul" wrote:
> >> >> > > >>
> >> >> > > >> > I need to run an application that sends out automatic emails based on
> >> >> > > >> > specific conditions. I need to schedule this to run every evening, could it
> >> >> > > >> > be scheduled as one of the SQL server agent jobs, using sql2000 or is there
> >> >> > > >> > another way to schedule it? Thanks.
> >> >> > > >> > --
> >> >> > > >> > Paul G
> >> >> > > >> > Software engineer.
> >> >> > >
> >>
>|||I can't say 1005 it won't work, but I do know that we often see problems with the mere fact that a
program does GUI interaction. There might be some dependencies on OS version and/or SQL Server
version as well. So, I'd watch it carefully and since you do have an option to make it console app,
don't hesitate to do so in case it starts behaving fishy.
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://sqlblog.com/blogs/tibor_karaszi
"Paul" <Paul@.discussions.microsoft.com> wrote in message
news:2DAD30AB-1FFF-4751-A060-7C6A357F47E5@.microsoft.com...
> ok thanks I will try it, just wondering if it will work, I can just as easily
> create a new console application with vs.net as well.
> --
> Paul G
> Software engineer.
>
> "Tibor Karaszi" wrote:
>> That will probably not work, since a service has no window context at all. I.e., the windows API
>> calls will make the program fail. But you could give it a go and see what happens.
>> --
>> Tibor Karaszi, SQL Server MVP
>> http://www.karaszi.com/sqlserver/default.asp
>> http://sqlblog.com/blogs/tibor_karaszi
>>
>> "Paul" <Paul@.discussions.microsoft.com> wrote in message
>> news:F605C191-3233-42B2-BB7A-41D9A6D1D9E5@.microsoft.com...
>> >I currently have it has a windows app but I have the window closing at the
>> > end of the program so no gui is left open.
>> > --
>> > Paul G
>> > Software engineer.
>> >
>> >
>> > "Tibor Karaszi" wrote:
>> >
>> >> Yep. Just make sure that the program is a console program (no GUI element), since it is
>> >> started
>> >> by a
>> >> service...
>> >>
>> >> --
>> >> Tibor Karaszi, SQL Server MVP
>> >> http://www.karaszi.com/sqlserver/default.asp
>> >> http://sqlblog.com/blogs/tibor_karaszi
>> >>
>> >>
>> >> "Paul" <Paul@.discussions.microsoft.com> wrote in message
>> >> news:9FBC9A5D-3985-40F5-A268-45F2AEC68CBA@.microsoft.com...
>> >> > found it, thanks! so for the command I just use c:/test.exe to run the
>> >> > executable called test.exe at location c:?
>> >> > --
>> >> > Paul G
>> >> > Software engineer.
>> >> >
>> >> >
>> >> > "Linchi Shea" wrote:
>> >> >
>> >> >> Scroll up in the drop-down list, and you'll see it.
>> >> >>
>> >> >> Linchi
>> >> >>
>> >> >> "Paul" wrote:
>> >> >>
>> >> >> > Thanks for the response. I am using SQL 2000 but under the step types I only
>> >> >> > see the following listed;
>> >> >> > Replication Transaction-Log Reader
>> >> >> > Replication Queue Reader
>> >> >> > Replication Snapshot
>> >> >> > Replication Merge
>> >> >> > Tansact-SQL script
>> >> >> > did not see a cmdExec type.
>> >> >> >
>> >> >> >
>> >> >> >
>> >> >> >
>> >> >> >
>> >> >> > --
>> >> >> > Paul G
>> >> >> > Software engineer.
>> >> >> >
>> >> >> >
>> >> >> > "Tibor Karaszi" wrote:
>> >> >> >
>> >> >> > > A job has one or more jobsteps. There are different type of jobsteps. TSQL is for
>> >> >> > > executing
>> >> >> > > SQL
>> >> >> > > commands, while CmdExec is for executing EXE files etc.
>> >> >> > >
>> >> >> > > --
>> >> >> > > Tibor Karaszi, SQL Server MVP
>> >> >> > > http://www.karaszi.com/sqlserver/default.asp
>> >> >> > > http://sqlblog.com/blogs/tibor_karaszi
>> >> >> > >
>> >> >> > >
>> >> >> > > "Paul" <Paul@.discussions.microsoft.com> wrote in message
>> >> >> > > news:4310F194-2BAB-4F52-BE75-4A6D019A3388@.microsoft.com...
>> >> >> > > > thanks for the response. I can not use windows scheduler because of computer
>> >> >> > > > restrictions but for example what command in SQL would I use to run the
>> >> >> > > > executable called test.exe located at C:\?
>> >> >> > > > Doesn't it have to be transact SQL to run out SQlAgent?
>> >> >> > > >
>> >> >> > > > Paul.
>> >> >> > > > --
>> >> >> > > > Paul G
>> >> >> > > > Software engineer.
>> >> >> > > >
>> >> >> > > >
>> >> >> > > > "Linchi Shea" wrote:
>> >> >> > > >
>> >> >> > > >> That sounds like a strainghtforward job for SQLAgent.
>> >> >> > > >>
>> >> >> > > >> Linchi
>> >> >> > > >>
>> >> >> > > >> "Paul" wrote:
>> >> >> > > >>
>> >> >> > > >> > I need to run an application that sends out automatic emails based on
>> >> >> > > >> > specific conditions. I need to schedule this to run every evening, could it
>> >> >> > > >> > be scheduled as one of the SQL server agent jobs, using sql2000 or is there
>> >> >> > > >> > another way to schedule it? Thanks.
>> >> >> > > >> > --
>> >> >> > > >> > Paul G
>> >> >> > > >> > Software engineer.
>> >> >> > >
>> >>|||It looks like it worked, this was just for test so when I build the real
application I will make it into a console app.
--
Paul G
Software engineer.
"Tibor Karaszi" wrote:
> I can't say 1005 it won't work, but I do know that we often see problems with the mere fact that a
> program does GUI interaction. There might be some dependencies on OS version and/or SQL Server
> version as well. So, I'd watch it carefully and since you do have an option to make it console app,
> don't hesitate to do so in case it starts behaving fishy.
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://sqlblog.com/blogs/tibor_karaszi
>
> "Paul" <Paul@.discussions.microsoft.com> wrote in message
> news:2DAD30AB-1FFF-4751-A060-7C6A357F47E5@.microsoft.com...
> > ok thanks I will try it, just wondering if it will work, I can just as easily
> > create a new console application with vs.net as well.
> > --
> > Paul G
> > Software engineer.
> >
> >
> > "Tibor Karaszi" wrote:
> >
> >> That will probably not work, since a service has no window context at all. I.e., the windows API
> >> calls will make the program fail. But you could give it a go and see what happens.
> >>
> >> --
> >> Tibor Karaszi, SQL Server MVP
> >> http://www.karaszi.com/sqlserver/default.asp
> >> http://sqlblog.com/blogs/tibor_karaszi
> >>
> >>
> >> "Paul" <Paul@.discussions.microsoft.com> wrote in message
> >> news:F605C191-3233-42B2-BB7A-41D9A6D1D9E5@.microsoft.com...
> >> >I currently have it has a windows app but I have the window closing at the
> >> > end of the program so no gui is left open.
> >> > --
> >> > Paul G
> >> > Software engineer.
> >> >
> >> >
> >> > "Tibor Karaszi" wrote:
> >> >
> >> >> Yep. Just make sure that the program is a console program (no GUI element), since it is
> >> >> started
> >> >> by a
> >> >> service...
> >> >>
> >> >> --
> >> >> Tibor Karaszi, SQL Server MVP
> >> >> http://www.karaszi.com/sqlserver/default.asp
> >> >> http://sqlblog.com/blogs/tibor_karaszi
> >> >>
> >> >>
> >> >> "Paul" <Paul@.discussions.microsoft.com> wrote in message
> >> >> news:9FBC9A5D-3985-40F5-A268-45F2AEC68CBA@.microsoft.com...
> >> >> > found it, thanks! so for the command I just use c:/test.exe to run the
> >> >> > executable called test.exe at location c:?
> >> >> > --
> >> >> > Paul G
> >> >> > Software engineer.
> >> >> >
> >> >> >
> >> >> > "Linchi Shea" wrote:
> >> >> >
> >> >> >> Scroll up in the drop-down list, and you'll see it.
> >> >> >>
> >> >> >> Linchi
> >> >> >>
> >> >> >> "Paul" wrote:
> >> >> >>
> >> >> >> > Thanks for the response. I am using SQL 2000 but under the step types I only
> >> >> >> > see the following listed;
> >> >> >> > Replication Transaction-Log Reader
> >> >> >> > Replication Queue Reader
> >> >> >> > Replication Snapshot
> >> >> >> > Replication Merge
> >> >> >> > Tansact-SQL script
> >> >> >> > did not see a cmdExec type.
> >> >> >> >
> >> >> >> >
> >> >> >> >
> >> >> >> >
> >> >> >> >
> >> >> >> > --
> >> >> >> > Paul G
> >> >> >> > Software engineer.
> >> >> >> >
> >> >> >> >
> >> >> >> > "Tibor Karaszi" wrote:
> >> >> >> >
> >> >> >> > > A job has one or more jobsteps. There are different type of jobsteps. TSQL is for
> >> >> >> > > executing
> >> >> >> > > SQL
> >> >> >> > > commands, while CmdExec is for executing EXE files etc.
> >> >> >> > >
> >> >> >> > > --
> >> >> >> > > Tibor Karaszi, SQL Server MVP
> >> >> >> > > http://www.karaszi.com/sqlserver/default.asp
> >> >> >> > > http://sqlblog.com/blogs/tibor_karaszi
> >> >> >> > >
> >> >> >> > >
> >> >> >> > > "Paul" <Paul@.discussions.microsoft.com> wrote in message
> >> >> >> > > news:4310F194-2BAB-4F52-BE75-4A6D019A3388@.microsoft.com...
> >> >> >> > > > thanks for the response. I can not use windows scheduler because of computer
> >> >> >> > > > restrictions but for example what command in SQL would I use to run the
> >> >> >> > > > executable called test.exe located at C:\?
> >> >> >> > > > Doesn't it have to be transact SQL to run out SQlAgent?
> >> >> >> > > >
> >> >> >> > > > Paul.
> >> >> >> > > > --
> >> >> >> > > > Paul G
> >> >> >> > > > Software engineer.
> >> >> >> > > >
> >> >> >> > > >
> >> >> >> > > > "Linchi Shea" wrote:
> >> >> >> > > >
> >> >> >> > > >> That sounds like a strainghtforward job for SQLAgent.
> >> >> >> > > >>
> >> >> >> > > >> Linchi
> >> >> >> > > >>
> >> >> >> > > >> "Paul" wrote:
> >> >> >> > > >>
> >> >> >> > > >> > I need to run an application that sends out automatic emails based on
> >> >> >> > > >> > specific conditions. I need to schedule this to run every evening, could it
> >> >> >> > > >> > be scheduled as one of the SQL server agent jobs, using sql2000 or is there
> >> >> >> > > >> > another way to schedule it? Thanks.
> >> >> >> > > >> > --
> >> >> >> > > >> > Paul G
> >> >> >> > > >> > Software engineer.
> >> >> >> > >
> >> >>
> >>
>

Running a vb.net exe from a dts

I'm trying to run a VB.NET exe from a dts.
This works when I run the DTS manually but just hangs when I schedule the DTS.
Has anyone seen this before ?Many times when you can run a DTS package manually, but not thru a scheduled job, it boills down to one of two things. Either you are running it from your machine instead of the server, or you have permissions that SQL Agent does not.

Physically logon to the SQL Server (not just open Enterprise Manager) and try to run your package ... if it fails, you were referencing files on your local box and not the server.

If it succeeds, then you need to look at the permissions of the service logon running SQL Agent verses your permissions.|||Thanks for the reply.
The DBA stated that the following error was found on the db server:

"Unable to Locate DLL - The Dynamic Link Library mscoree.dll could not be found in the specified path"

He is currently installing the .net framework on the sequel server.

Do you think this will do the job ?|||After installing the .net framework on the sequel server, I re run the dts and got the following message from the event viewer:

Event Type: Error
Event Source: .NET Runtime
Event Category: None
Event ID: 0
Date: 22/05/2007
Time: 14:54:35
User: N/A
Computer: SQLXXXXX
Description:
The description for Event ID ( 0 ) in Source ( .NET Runtime ) cannot be found. The local computer may not have the necessary registry information or message DLL files to display messages from a remote computer. You may be able to use the /AUXSOURCE= flag to retrieve this description; see Help and Support for details. The following information is part of the event: .NET Runtime version 1.1.4322.573- FraudDailyImport.exe - Common Language Runtime Debugging Services: Application has generated an exception that could not be handled.

Process id=0x1224 (4644), Thread id=0xe64 (3684).

Click OK to terminate the application.
Click CANCEL to debug the application..[/B]

Anybody got any ideas ?

Thanks in advance.sql

running a vb.net dll from sql server

We have a new application were building which includes a module to preform
overnight processing.
Originally the idea was to schedule a job on the server to run for each
database that needs the processing completed.
Whats the best way to do this?
we are using vs 2003, ms slq server 2000
1) All the code to execute is in a vb.net dll
2) needs to be run against one or more databases
suggestions?There are a number of ways to accomplish this. One method is to wrap your
DLL in a command-line EXE that takes arguments for server, database, etc.
and then schedule a SQL Agent job with a CmdExec step for each database.
Hope this helps.
Dan Guzman
SQL Server MVP
"Claude Hebert" <chebert@.rvmags.com> wrote in message
news:ug8QC2$JGHA.2392@.TK2MSFTNGP09.phx.gbl...
> We have a new application were building which includes a module to preform
> overnight processing.
> Originally the idea was to schedule a job on the server to run for each
> database that needs the processing completed.
> Whats the best way to do this?
> we are using vs 2003, ms slq server 2000
> 1) All the code to execute is in a vb.net dll
> 2) needs to be run against one or more databases
> suggestions?
>|||....my first thought is that the VB.Net app logs in and does its thing.
In the old days, I'd write my dll in VB6 and use an ActiveX DTS or TSQL
sp_OACreate.
HTH
JeffP...
"Dan Guzman" <guzmanda@.nospam-online.sbcglobal.net> wrote in message
news:uHSQD$$JGHA.3276@.TK2MSFTNGP09.phx.gbl...
> There are a number of ways to accomplish this. One method is to wrap your
> DLL in a command-line EXE that takes arguments for server, database, etc.
> and then schedule a SQL Agent job with a CmdExec step for each database.
> --
> Hope this helps.
> Dan Guzman
> SQL Server MVP
> "Claude Hebert" <chebert@.rvmags.com> wrote in message
> news:ug8QC2$JGHA.2392@.TK2MSFTNGP09.phx.gbl...
>|||What about using rundll32.exe?
--
Andrey Odegov
avodeGOV@.yandex.ru
(remove GOV to respond)|||the best method is to do with
SP_OACreate procedure
steps are :
1. if u r using vb.net dll then make sure the value of Register for COM
Interop value TRUE in Project properties ->Configuration Properties
->Build.
2. add strongname with ur project by sn -k utility.
3. publish ur dll in GAC
4. put ur dll and tlb in system32
5. register ur tlb using regtlibv12 tools
6. in sql server stored procedure create a object of tha dll by using
sp_OACreate.
7.use sp_OAMethod to access methods of that Dll.
8. use sp_OAGetProperty,sp_OASetProperty for getting or setting values.
9. use sp_OADestroy to destroy the object at last.
this is really simple.
if u need example for this then mail me personally at
kissvineet@.yahoo.com

Wednesday, March 28, 2012

Running a Report Automatically

I want to be able to setup a report that runs everynight at a certain time. Anyone know how to schedule sql server reports?

Thanks

macca

On your report server:

For an existing or shared schedule

Site settings:

Monday, March 26, 2012

running a batch file

I have a Batch file to use ssh connection. So When I run the batch file
manually its works fine, but when I schedule it on job managment from SQL
2000 it doesnt work.
Help me pleaseProbably service account and permissions problems. Verify that Agent has the needed permissions.
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
Blog: http://solidqualitylearning.com/blogs/tibor/
"jdonaldo" <jdonaldo@.discussions.microsoft.com> wrote in message
news:0DF4CDB5-4C6A-49AA-A798-4B56DFCDA65D@.microsoft.com...
>I have a Batch file to use ssh connection. So When I run the batch file
> manually its works fine, but when I schedule it on job managment from SQL
> 2000 it doesnt work.
> Help me please|||ok thanks for yor answer but the user has permission to run the service, In
fact the user can run other batch files.
I debug the batch and this is the result:
Executing: program /usr/bin/ssh host 10.10.10.1, user dispo, command scp -v
-t WEBDSP.TXT
OpenSSH_3.8.1p1, OpenSSL 0.9.7d 17 Mar 2004
debug1: Reading configuration data /etc/ssh_config
debug1: Connecting to 10.10.10.1 [10.10.10.1] port 22.
debug1: Connection established.
debug1: identity file id_dsa type 2
debug1: Remote protocol version 1.99, remote software version OpenSSH_3.7.1p2
debug1: match: OpenSSH_3.7.1p2 pat OpenSSH*
debug1: Enabling compatibility mode for protocol 2.0
debug1: Local version string SSH-2.0-OpenSSH_3.8.1p1
debug1: SSH2_MSG_KEXINIT sent
debug1: SSH2_MSG_KEXINIT received
debug1: kex: server->client aes128-cbc hmac-md5 none
debug1: kex: client->server aes128-cbc hmac-md5 none
debug1: SSH2_MSG_KEX_DH_GEX_REQUEST(1024<1024<8192) sent
debug1: expecting SSH2_MSG_KEX_DH_GEX_GROUP
debug1: SSH2_MSG_KEX_DH_GEX_INIT sent
debug1: expecting SSH2_MSG_KEX_DH_GEX_REPLY
-- last line --
This results is when I run from SQL Server, but if a run it from command
console the result is this
Executing: program /usr/bin/ssh host 10.10.10.1, user dispo, command
-t WEBDSP.TXT
OpenSSH_3.8.1p1, OpenSSL 0.9.7d 17 Mar 2004
debug1: Reading configuration data /etc/ssh_config
debug1: Connecting to 10.10.10.1 [10.10.10.1] port 22.
debug1: Connection established.
debug1: identity file id_dsa type 2
debug1: Remote protocol version 1.99, remote software version OpenSSH_3.
debug1: match: OpenSSH_3.7.1p2 pat OpenSSH*
debug1: Enabling compatibility mode for protocol 2.0
debug1: Local version string SSH-2.0-OpenSSH_3.8.1p1
debug1: SSH2_MSG_KEXINIT sent
debug1: SSH2_MSG_KEXINIT received
debug1: kex: server->client aes128-cbc hmac-md5 none
debug1: kex: client->server aes128-cbc hmac-md5 none
debug1: SSH2_MSG_KEX_DH_GEX_REQUEST(1024<1024<8192) sent
debug1: expecting SSH2_MSG_KEX_DH_GEX_GROUP
debug1: SSH2_MSG_KEX_DH_GEX_INIT sent
debug1: expecting SSH2_MSG_KEX_DH_GEX_REPLY
debug1: Host '10.10.10.1' is known and matches the RSA host key.
debug1: Found key in /home/ottod/.ssh/known_hosts:1
debug1: ssh_rsa_verify: signature correct
debug1: SSH2_MSG_NEWKEYS sent
debug1: expecting SSH2_MSG_NEWKEYS
debug1: SSH2_MSG_NEWKEYS received
debug1: SSH2_MSG_SERVICE_REQUEST sent
debug1: SSH2_MSG_SERVICE_ACCEPT received
debug1: Authentications that can continue: publickey,password,keyboard-i
ve
debug1: Next authentication method: publickey
debug1: Offering public key: id_dsa
debug1: Server accepts key: pkalg ssh-dss blen 433
debug1: read PEM private key done: type DSA
debug1: Authentication succeeded (publickey).
debug1: channel 0: new [client-session]
debug1: Entering interactive session.
debug1: Sending command: scp -v -t WEBDSP.TXT
Sending file modes: C0777 3894 webdsp.txt
debug1: client_input_channel_req: channel 0 rtype exit-status reply 0
debug1: channel 0: free: client-session, nchannels 1
debug1: Transferred: stdin 0, stdout 0, stderr 0 bytes in 0.8 seconds
debug1: Bytes per second: stdin 0.0, stdout 0.0, stderr 0.0
debug1: Exit status 0
What do you think?
"Tibor Karaszi" wrote:
> Probably service account and permissions problems. Verify that Agent has the needed permissions.
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://www.solidqualitylearning.com/
> Blog: http://solidqualitylearning.com/blogs/tibor/
>
> "jdonaldo" <jdonaldo@.discussions.microsoft.com> wrote in message
> news:0DF4CDB5-4C6A-49AA-A798-4B56DFCDA65D@.microsoft.com...
> >I have a Batch file to use ssh connection. So When I run the batch file
> > manually its works fine, but when I schedule it on job managment from SQL
> > 2000 it doesnt work.
> >
> > Help me please
>|||> ok thanks for yor answer but the user has permission to run the service,
I don't understand what you mean by above. When agent executes something, it is executed in agents
service user context, not the user who owns the job.
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
Blog: http://solidqualitylearning.com/blogs/tibor/
"jdonaldo" <jdonaldo@.discussions.microsoft.com> wrote in message
news:F10E7461-4A0B-49A5-8087-432269318F23@.microsoft.com...
> ok thanks for yor answer but the user has permission to run the service, In
> fact the user can run other batch files.
> I debug the batch and this is the result:
> Executing: program /usr/bin/ssh host 10.10.10.1, user dispo, command scp -v
> -t WEBDSP.TXT
> OpenSSH_3.8.1p1, OpenSSL 0.9.7d 17 Mar 2004
> debug1: Reading configuration data /etc/ssh_config
> debug1: Connecting to 10.10.10.1 [10.10.10.1] port 22.
> debug1: Connection established.
> debug1: identity file id_dsa type 2
> debug1: Remote protocol version 1.99, remote software version OpenSSH_3.7.1p2
> debug1: match: OpenSSH_3.7.1p2 pat OpenSSH*
> debug1: Enabling compatibility mode for protocol 2.0
> debug1: Local version string SSH-2.0-OpenSSH_3.8.1p1
> debug1: SSH2_MSG_KEXINIT sent
> debug1: SSH2_MSG_KEXINIT received
> debug1: kex: server->client aes128-cbc hmac-md5 none
> debug1: kex: client->server aes128-cbc hmac-md5 none
> debug1: SSH2_MSG_KEX_DH_GEX_REQUEST(1024<1024<8192) sent
> debug1: expecting SSH2_MSG_KEX_DH_GEX_GROUP
> debug1: SSH2_MSG_KEX_DH_GEX_INIT sent
> debug1: expecting SSH2_MSG_KEX_DH_GEX_REPLY
> -- last line --
> This results is when I run from SQL Server, but if a run it from command
> console the result is this
> Executing: program /usr/bin/ssh host 10.10.10.1, user dispo, command
> -t WEBDSP.TXT
> OpenSSH_3.8.1p1, OpenSSL 0.9.7d 17 Mar 2004
> debug1: Reading configuration data /etc/ssh_config
> debug1: Connecting to 10.10.10.1 [10.10.10.1] port 22.
> debug1: Connection established.
> debug1: identity file id_dsa type 2
> debug1: Remote protocol version 1.99, remote software version OpenSSH_3.
> debug1: match: OpenSSH_3.7.1p2 pat OpenSSH*
> debug1: Enabling compatibility mode for protocol 2.0
> debug1: Local version string SSH-2.0-OpenSSH_3.8.1p1
> debug1: SSH2_MSG_KEXINIT sent
> debug1: SSH2_MSG_KEXINIT received
> debug1: kex: server->client aes128-cbc hmac-md5 none
> debug1: kex: client->server aes128-cbc hmac-md5 none
> debug1: SSH2_MSG_KEX_DH_GEX_REQUEST(1024<1024<8192) sent
> debug1: expecting SSH2_MSG_KEX_DH_GEX_GROUP
> debug1: SSH2_MSG_KEX_DH_GEX_INIT sent
> debug1: expecting SSH2_MSG_KEX_DH_GEX_REPLY
> debug1: Host '10.10.10.1' is known and matches the RSA host key.
> debug1: Found key in /home/ottod/.ssh/known_hosts:1
> debug1: ssh_rsa_verify: signature correct
> debug1: SSH2_MSG_NEWKEYS sent
> debug1: expecting SSH2_MSG_NEWKEYS
> debug1: SSH2_MSG_NEWKEYS received
> debug1: SSH2_MSG_SERVICE_REQUEST sent
> debug1: SSH2_MSG_SERVICE_ACCEPT received
> debug1: Authentications that can continue: publickey,password,keyboard-i
> ve
> debug1: Next authentication method: publickey
> debug1: Offering public key: id_dsa
> debug1: Server accepts key: pkalg ssh-dss blen 433
> debug1: read PEM private key done: type DSA
> debug1: Authentication succeeded (publickey).
> debug1: channel 0: new [client-session]
> debug1: Entering interactive session.
> debug1: Sending command: scp -v -t WEBDSP.TXT
> Sending file modes: C0777 3894 webdsp.txt
> debug1: client_input_channel_req: channel 0 rtype exit-status reply 0
> debug1: channel 0: free: client-session, nchannels 1
> debug1: Transferred: stdin 0, stdout 0, stderr 0 bytes in 0.8 seconds
> debug1: Bytes per second: stdin 0.0, stdout 0.0, stderr 0.0
> debug1: Exit status 0
>
> What do you think?
> "Tibor Karaszi" wrote:
>> Probably service account and permissions problems. Verify that Agent has the needed permissions.
>> --
>> Tibor Karaszi, SQL Server MVP
>> http://www.karaszi.com/sqlserver/default.asp
>> http://www.solidqualitylearning.com/
>> Blog: http://solidqualitylearning.com/blogs/tibor/
>>
>> "jdonaldo" <jdonaldo@.discussions.microsoft.com> wrote in message
>> news:0DF4CDB5-4C6A-49AA-A798-4B56DFCDA65D@.microsoft.com...
>> >I have a Batch file to use ssh connection. So When I run the batch file
>> > manually its works fine, but when I schedule it on job managment from SQL
>> > 2000 it doesnt work.
>> >
>> > Help me please
>>|||the user can run the agent, because I created others job and run fine
"jdonaldo" wrote:
> I have a Batch file to use ssh connection. So When I run the batch file
> manually its works fine, but when I schedule it on job managment from SQL
> 2000 it doesnt work.
> Help me pleasesql

running a batch file

I have a Batch file to use ssh connection. So When I run the batch file
manually its works fine, but when I schedule it on job managment from SQL
2000 it doesnt work.
Help me please
Probably service account and permissions problems. Verify that Agent has the needed permissions.
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
Blog: http://solidqualitylearning.com/blogs/tibor/
"jdonaldo" <jdonaldo@.discussions.microsoft.com> wrote in message
news:0DF4CDB5-4C6A-49AA-A798-4B56DFCDA65D@.microsoft.com...
>I have a Batch file to use ssh connection. So When I run the batch file
> manually its works fine, but when I schedule it on job managment from SQL
> 2000 it doesnt work.
> Help me please
|||ok thanks for yor answer but the user has permission to run the service, In
fact the user can run other batch files.
I debug the batch and this is the result:
Executing: program /usr/bin/ssh host 10.10.10.1, user dispo, command scp -v
-t WEBDSP.TXT
OpenSSH_3.8.1p1, OpenSSL 0.9.7d 17 Mar 2004
debug1: Reading configuration data /etc/ssh_config
debug1: Connecting to 10.10.10.1 [10.10.10.1] port 22.
debug1: Connection established.
debug1: identity file id_dsa type 2
debug1: Remote protocol version 1.99, remote software version OpenSSH_3.7.1p2
debug1: match: OpenSSH_3.7.1p2 pat OpenSSH*
debug1: Enabling compatibility mode for protocol 2.0
debug1: Local version string SSH-2.0-OpenSSH_3.8.1p1
debug1: SSH2_MSG_KEXINIT sent
debug1: SSH2_MSG_KEXINIT received
debug1: kex: server->client aes128-cbc hmac-md5 none
debug1: kex: client->server aes128-cbc hmac-md5 none
debug1: SSH2_MSG_KEX_DH_GEX_REQUEST(1024<1024<8192) sent
debug1: expecting SSH2_MSG_KEX_DH_GEX_GROUP
debug1: SSH2_MSG_KEX_DH_GEX_INIT sent
debug1: expecting SSH2_MSG_KEX_DH_GEX_REPLY
-- last line --
This results is when I run from SQL Server, but if a run it from command
console the result is this
Executing: program /usr/bin/ssh host 10.10.10.1, user dispo, command
-t WEBDSP.TXT
OpenSSH_3.8.1p1, OpenSSL 0.9.7d 17 Mar 2004
debug1: Reading configuration data /etc/ssh_config
debug1: Connecting to 10.10.10.1 [10.10.10.1] port 22.
debug1: Connection established.
debug1: identity file id_dsa type 2
debug1: Remote protocol version 1.99, remote software version OpenSSH_3.
debug1: match: OpenSSH_3.7.1p2 pat OpenSSH*
debug1: Enabling compatibility mode for protocol 2.0
debug1: Local version string SSH-2.0-OpenSSH_3.8.1p1
debug1: SSH2_MSG_KEXINIT sent
debug1: SSH2_MSG_KEXINIT received
debug1: kex: server->client aes128-cbc hmac-md5 none
debug1: kex: client->server aes128-cbc hmac-md5 none
debug1: SSH2_MSG_KEX_DH_GEX_REQUEST(1024<1024<8192) sent
debug1: expecting SSH2_MSG_KEX_DH_GEX_GROUP
debug1: SSH2_MSG_KEX_DH_GEX_INIT sent
debug1: expecting SSH2_MSG_KEX_DH_GEX_REPLY
debug1: Host '10.10.10.1' is known and matches the RSA host key.
debug1: Found key in /home/ottod/.ssh/known_hosts:1
debug1: ssh_rsa_verify: signature correct
debug1: SSH2_MSG_NEWKEYS sent
debug1: expecting SSH2_MSG_NEWKEYS
debug1: SSH2_MSG_NEWKEYS received
debug1: SSH2_MSG_SERVICE_REQUEST sent
debug1: SSH2_MSG_SERVICE_ACCEPT received
debug1: Authentications that can continue: publickey,password,keyboard-i
ve
debug1: Next authentication method: publickey
debug1: Offering public key: id_dsa
debug1: Server accepts key: pkalg ssh-dss blen 433
debug1: read PEM private key done: type DSA
debug1: Authentication succeeded (publickey).
debug1: channel 0: new [client-session]
debug1: Entering interactive session.
debug1: Sending command: scp -v -t WEBDSP.TXT
Sending file modes: C0777 3894 webdsp.txt
debug1: client_input_channel_req: channel 0 rtype exit-status reply 0
debug1: channel 0: free: client-session, nchannels 1
debug1: Transferred: stdin 0, stdout 0, stderr 0 bytes in 0.8 seconds
debug1: Bytes per second: stdin 0.0, stdout 0.0, stderr 0.0
debug1: Exit status 0
What do you think?
"Tibor Karaszi" wrote:

> Probably service account and permissions problems. Verify that Agent has the needed permissions.
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://www.solidqualitylearning.com/
> Blog: http://solidqualitylearning.com/blogs/tibor/
>
> "jdonaldo" <jdonaldo@.discussions.microsoft.com> wrote in message
> news:0DF4CDB5-4C6A-49AA-A798-4B56DFCDA65D@.microsoft.com...
>
|||> ok thanks for yor answer but the user has permission to run the service,
I don't understand what you mean by above. When agent executes something, it is executed in agents
service user context, not the user who owns the job.
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
Blog: http://solidqualitylearning.com/blogs/tibor/
"jdonaldo" <jdonaldo@.discussions.microsoft.com> wrote in message
news:F10E7461-4A0B-49A5-8087-432269318F23@.microsoft.com...[vbcol=seagreen]
> ok thanks for yor answer but the user has permission to run the service, In
> fact the user can run other batch files.
> I debug the batch and this is the result:
> Executing: program /usr/bin/ssh host 10.10.10.1, user dispo, command scp -v
> -t WEBDSP.TXT
> OpenSSH_3.8.1p1, OpenSSL 0.9.7d 17 Mar 2004
> debug1: Reading configuration data /etc/ssh_config
> debug1: Connecting to 10.10.10.1 [10.10.10.1] port 22.
> debug1: Connection established.
> debug1: identity file id_dsa type 2
> debug1: Remote protocol version 1.99, remote software version OpenSSH_3.7.1p2
> debug1: match: OpenSSH_3.7.1p2 pat OpenSSH*
> debug1: Enabling compatibility mode for protocol 2.0
> debug1: Local version string SSH-2.0-OpenSSH_3.8.1p1
> debug1: SSH2_MSG_KEXINIT sent
> debug1: SSH2_MSG_KEXINIT received
> debug1: kex: server->client aes128-cbc hmac-md5 none
> debug1: kex: client->server aes128-cbc hmac-md5 none
> debug1: SSH2_MSG_KEX_DH_GEX_REQUEST(1024<1024<8192) sent
> debug1: expecting SSH2_MSG_KEX_DH_GEX_GROUP
> debug1: SSH2_MSG_KEX_DH_GEX_INIT sent
> debug1: expecting SSH2_MSG_KEX_DH_GEX_REPLY
> -- last line --
> This results is when I run from SQL Server, but if a run it from command
> console the result is this
> Executing: program /usr/bin/ssh host 10.10.10.1, user dispo, command
> -t WEBDSP.TXT
> OpenSSH_3.8.1p1, OpenSSL 0.9.7d 17 Mar 2004
> debug1: Reading configuration data /etc/ssh_config
> debug1: Connecting to 10.10.10.1 [10.10.10.1] port 22.
> debug1: Connection established.
> debug1: identity file id_dsa type 2
> debug1: Remote protocol version 1.99, remote software version OpenSSH_3.
> debug1: match: OpenSSH_3.7.1p2 pat OpenSSH*
> debug1: Enabling compatibility mode for protocol 2.0
> debug1: Local version string SSH-2.0-OpenSSH_3.8.1p1
> debug1: SSH2_MSG_KEXINIT sent
> debug1: SSH2_MSG_KEXINIT received
> debug1: kex: server->client aes128-cbc hmac-md5 none
> debug1: kex: client->server aes128-cbc hmac-md5 none
> debug1: SSH2_MSG_KEX_DH_GEX_REQUEST(1024<1024<8192) sent
> debug1: expecting SSH2_MSG_KEX_DH_GEX_GROUP
> debug1: SSH2_MSG_KEX_DH_GEX_INIT sent
> debug1: expecting SSH2_MSG_KEX_DH_GEX_REPLY
> debug1: Host '10.10.10.1' is known and matches the RSA host key.
> debug1: Found key in /home/ottod/.ssh/known_hosts:1
> debug1: ssh_rsa_verify: signature correct
> debug1: SSH2_MSG_NEWKEYS sent
> debug1: expecting SSH2_MSG_NEWKEYS
> debug1: SSH2_MSG_NEWKEYS received
> debug1: SSH2_MSG_SERVICE_REQUEST sent
> debug1: SSH2_MSG_SERVICE_ACCEPT received
> debug1: Authentications that can continue: publickey,password,keyboard-i
> ve
> debug1: Next authentication method: publickey
> debug1: Offering public key: id_dsa
> debug1: Server accepts key: pkalg ssh-dss blen 433
> debug1: read PEM private key done: type DSA
> debug1: Authentication succeeded (publickey).
> debug1: channel 0: new [client-session]
> debug1: Entering interactive session.
> debug1: Sending command: scp -v -t WEBDSP.TXT
> Sending file modes: C0777 3894 webdsp.txt
> debug1: client_input_channel_req: channel 0 rtype exit-status reply 0
> debug1: channel 0: free: client-session, nchannels 1
> debug1: Transferred: stdin 0, stdout 0, stderr 0 bytes in 0.8 seconds
> debug1: Bytes per second: stdin 0.0, stdout 0.0, stderr 0.0
> debug1: Exit status 0
>
> What do you think?
> "Tibor Karaszi" wrote:
|||the user can run the agent, because I created others job and run fine
"jdonaldo" wrote:

> I have a Batch file to use ssh connection. So When I run the batch file
> manually its works fine, but when I schedule it on job managment from SQL
> 2000 it doesnt work.
> Help me please

running a batch file

I have a Batch file to use ssh connection. So When I run the batch file
manually its works fine, but when I schedule it on job managment from SQL
2000 it doesnt work.
Help me pleaseProbably service account and permissions problems. Verify that Agent has the
needed permissions.
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
Blog: http://solidqualitylearning.com/blogs/tibor/
"jdonaldo" <jdonaldo@.discussions.microsoft.com> wrote in message
news:0DF4CDB5-4C6A-49AA-A798-4B56DFCDA65D@.microsoft.com...
>I have a Batch file to use ssh connection. So When I run the batch file
> manually its works fine, but when I schedule it on job managment from SQL
> 2000 it doesnt work.
> Help me please|||ok thanks for yor answer but the user has permission to run the service, In
fact the user can run other batch files.
I debug the batch and this is the result:
Executing: program /usr/bin/ssh host 10.10.10.1, user dispo, command scp -v
-t WEBDSP.TXT
OpenSSH_3.8.1p1, OpenSSL 0.9.7d 17 Mar 2004
debug1: Reading configuration data /etc/ssh_config
debug1: Connecting to 10.10.10.1 [10.10.10.1] port 22.
debug1: Connection established.
debug1: identity file id_dsa type 2
debug1: Remote protocol version 1.99, remote software version OpenSSH_3.7.1p
2
debug1: match: OpenSSH_3.7.1p2 pat OpenSSH*
debug1: Enabling compatibility mode for protocol 2.0
debug1: Local version string SSH-2.0-OpenSSH_3.8.1p1
debug1: SSH2_MSG_KEXINIT sent
debug1: SSH2_MSG_KEXINIT received
debug1: kex: server->client aes128-cbc hmac-md5 none
debug1: kex: client->server aes128-cbc hmac-md5 none
debug1: SSH2_MSG_KEX_DH_GEX_REQUEST(1024<1024<8192) sent
debug1: expecting SSH2_MSG_KEX_DH_GEX_GROUP
debug1: SSH2_MSG_KEX_DH_GEX_INIT sent
debug1: expecting SSH2_MSG_KEX_DH_GEX_REPLY
-- last line --
This results is when I run from SQL Server, but if a run it from command
console the result is this
Executing: program /usr/bin/ssh host 10.10.10.1, user dispo, command
-t WEBDSP.TXT
OpenSSH_3.8.1p1, OpenSSL 0.9.7d 17 Mar 2004
debug1: Reading configuration data /etc/ssh_config
debug1: Connecting to 10.10.10.1 [10.10.10.1] port 22.
debug1: Connection established.
debug1: identity file id_dsa type 2
debug1: Remote protocol version 1.99, remote software version OpenSSH_3.
debug1: match: OpenSSH_3.7.1p2 pat OpenSSH*
debug1: Enabling compatibility mode for protocol 2.0
debug1: Local version string SSH-2.0-OpenSSH_3.8.1p1
debug1: SSH2_MSG_KEXINIT sent
debug1: SSH2_MSG_KEXINIT received
debug1: kex: server->client aes128-cbc hmac-md5 none
debug1: kex: client->server aes128-cbc hmac-md5 none
debug1: SSH2_MSG_KEX_DH_GEX_REQUEST(1024<1024<8192) sent
debug1: expecting SSH2_MSG_KEX_DH_GEX_GROUP
debug1: SSH2_MSG_KEX_DH_GEX_INIT sent
debug1: expecting SSH2_MSG_KEX_DH_GEX_REPLY
debug1: Host '10.10.10.1' is known and matches the RSA host key.
debug1: Found key in /home/ottod/.ssh/known_hosts:1
debug1: ssh_rsa_verify: signature correct
debug1: SSH2_MSG_NEWKEYS sent
debug1: expecting SSH2_MSG_NEWKEYS
debug1: SSH2_MSG_NEWKEYS received
debug1: SSH2_MSG_SERVICE_REQUEST sent
debug1: SSH2_MSG_SERVICE_ACCEPT received
debug1: Authentications that can continue: publickey,password,keyboard-i
ve
debug1: Next authentication method: publickey
debug1: Offering public key: id_dsa
debug1: Server accepts key: pkalg ssh-dss blen 433
debug1: read PEM private key done: type DSA
debug1: Authentication succeeded (publickey).
debug1: channel 0: new [client-session]
debug1: Entering interactive session.
debug1: Sending command: scp -v -t WEBDSP.TXT
Sending file modes: C0777 3894 webdsp.txt
debug1: client_input_channel_req: channel 0 rtype exit-status reply 0
debug1: channel 0: free: client-session, nchannels 1
debug1: Transferred: stdin 0, stdout 0, stderr 0 bytes in 0.8 seconds
debug1: Bytes per second: stdin 0.0, stdout 0.0, stderr 0.0
debug1: Exit status 0
What do you think?
"Tibor Karaszi" wrote:

> Probably service account and permissions problems. Verify that Agent has t
he needed permissions.
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://www.solidqualitylearning.com/
> Blog: http://solidqualitylearning.com/blogs/tibor/
>
> "jdonaldo" <jdonaldo@.discussions.microsoft.com> wrote in message
> news:0DF4CDB5-4C6A-49AA-A798-4B56DFCDA65D@.microsoft.com...
>|||> ok thanks for yor answer but the user has permission to run the service,
I don't understand what you mean by above. When agent executes something, it
is executed in agents
service user context, not the user who owns the job.
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
Blog: http://solidqualitylearning.com/blogs/tibor/
"jdonaldo" <jdonaldo@.discussions.microsoft.com> wrote in message
news:F10E7461-4A0B-49A5-8087-432269318F23@.microsoft.com...[vbcol=seagreen]
> ok thanks for yor answer but the user has permission to run the service, I
n
> fact the user can run other batch files.
> I debug the batch and this is the result:
> Executing: program /usr/bin/ssh host 10.10.10.1, user dispo, command scp -
v
> -t WEBDSP.TXT
> OpenSSH_3.8.1p1, OpenSSL 0.9.7d 17 Mar 2004
> debug1: Reading configuration data /etc/ssh_config
> debug1: Connecting to 10.10.10.1 [10.10.10.1] port 22.
> debug1: Connection established.
> debug1: identity file id_dsa type 2
> debug1: Remote protocol version 1.99, remote software version OpenSSH_3.7.
1p2
> debug1: match: OpenSSH_3.7.1p2 pat OpenSSH*
> debug1: Enabling compatibility mode for protocol 2.0
> debug1: Local version string SSH-2.0-OpenSSH_3.8.1p1
> debug1: SSH2_MSG_KEXINIT sent
> debug1: SSH2_MSG_KEXINIT received
> debug1: kex: server->client aes128-cbc hmac-md5 none
> debug1: kex: client->server aes128-cbc hmac-md5 none
> debug1: SSH2_MSG_KEX_DH_GEX_REQUEST(1024<1024<8192) sent
> debug1: expecting SSH2_MSG_KEX_DH_GEX_GROUP
> debug1: SSH2_MSG_KEX_DH_GEX_INIT sent
> debug1: expecting SSH2_MSG_KEX_DH_GEX_REPLY
> -- last line --
> This results is when I run from SQL Server, but if a run it from command
> console the result is this
> Executing: program /usr/bin/ssh host 10.10.10.1, user dispo, command
> -t WEBDSP.TXT
> OpenSSH_3.8.1p1, OpenSSL 0.9.7d 17 Mar 2004
> debug1: Reading configuration data /etc/ssh_config
> debug1: Connecting to 10.10.10.1 [10.10.10.1] port 22.
> debug1: Connection established.
> debug1: identity file id_dsa type 2
> debug1: Remote protocol version 1.99, remote software version OpenSSH_3.
> debug1: match: OpenSSH_3.7.1p2 pat OpenSSH*
> debug1: Enabling compatibility mode for protocol 2.0
> debug1: Local version string SSH-2.0-OpenSSH_3.8.1p1
> debug1: SSH2_MSG_KEXINIT sent
> debug1: SSH2_MSG_KEXINIT received
> debug1: kex: server->client aes128-cbc hmac-md5 none
> debug1: kex: client->server aes128-cbc hmac-md5 none
> debug1: SSH2_MSG_KEX_DH_GEX_REQUEST(1024<1024<8192) sent
> debug1: expecting SSH2_MSG_KEX_DH_GEX_GROUP
> debug1: SSH2_MSG_KEX_DH_GEX_INIT sent
> debug1: expecting SSH2_MSG_KEX_DH_GEX_REPLY
> debug1: Host '10.10.10.1' is known and matches the RSA host key.
> debug1: Found key in /home/ottod/.ssh/known_hosts:1
> debug1: ssh_rsa_verify: signature correct
> debug1: SSH2_MSG_NEWKEYS sent
> debug1: expecting SSH2_MSG_NEWKEYS
> debug1: SSH2_MSG_NEWKEYS received
> debug1: SSH2_MSG_SERVICE_REQUEST sent
> debug1: SSH2_MSG_SERVICE_ACCEPT received
> debug1: Authentications that can continue: publickey,password,keyboard-i
> ve
> debug1: Next authentication method: publickey
> debug1: Offering public key: id_dsa
> debug1: Server accepts key: pkalg ssh-dss blen 433
> debug1: read PEM private key done: type DSA
> debug1: Authentication succeeded (publickey).
> debug1: channel 0: new [client-session]
> debug1: Entering interactive session.
> debug1: Sending command: scp -v -t WEBDSP.TXT
> Sending file modes: C0777 3894 webdsp.txt
> debug1: client_input_channel_req: channel 0 rtype exit-status reply 0
> debug1: channel 0: free: client-session, nchannels 1
> debug1: Transferred: stdin 0, stdout 0, stderr 0 bytes in 0.8 seconds
> debug1: Bytes per second: stdin 0.0, stdout 0.0, stderr 0.0
> debug1: Exit status 0
>
> What do you think?
> "Tibor Karaszi" wrote:
>|||the user can run the agent, because I created others job and run fine
"jdonaldo" wrote:

> I have a Batch file to use ssh connection. So When I run the batch file
> manually its works fine, but when I schedule it on job managment from SQL
> 2000 it doesnt work.
> Help me please

Wednesday, March 21, 2012

Run the job

I have question, in sql server i created a job to import data and schedule it on every night, But now i want to run again as the original data has been changed. I don't want to wait tonight, How can i do this? After i run one time, i still want this job to run on schedule.
Another question, after i create the job, can i see the content of the job as i want to modify.Yes you can,

You just right click on the job and choose start job.

and it will run that instance and it will run again according to the schedule you have set for it.

Lystra|||Thanks, i got it. I had a question, Can i see the content of the job as this job was created long time ago, i want to modified, How can i see the content? Thanks again!|||Double click on the job, click on the step tab and double click on the step you want to see.

Lystra|||Thank, i tried to use your way to run the job once, it didn't work, i found when i create a job, it also create local package, so i have go the DTS folder then click the local package, right click the package i want to run then execute the package, then it worked, why i right the job to start the job it didn't work?|||You said a job, But if it is a DTS package you can excute it directly from the package.

As for the 'job create a local package' it's the other way around, a local packages create a job if you add a schedule.

Thanks

Lystra|||Thank you very much!

Monday, March 12, 2012

Run Once Schedule

In SQL 2005 Reporting Services, on the page that you use to set a schedule
for a subscription, there is an option to run a report once. Is there a way
through the web service interface to invoke this specific schedule? Do you
use the NoRecurrence object?
(The options are: Hour, Day, Weekly, Monthly, Once)The quick answer is YES, everything that is done in the ReportManager
uses the web service interface. I would check the BOL for the specific
details.
"Steven Molen" <StevenMolen@.discussions.microsoft.com> wrote in message
news:7B87FBF2-5CE0-4298-8DD7-7FA9A586FD9D@.microsoft.com:
> In SQL 2005 Reporting Services, on the page that you use to set a schedule
> for a subscription, there is an option to run a report once. Is there a way
> through the web service interface to invoke this specific schedule? Do you
> use the NoRecurrence object?
> (The options are: Hour, Day, Weekly, Monthly, Once)
Bret Updegraff, MCAD,MCSD,MCDBA
Microsoft MVP - SQL Server
Crowe Chizek and Company LLC
President - Indianapolis Professional Association for SQL Server
Join our SQL Server Community http;//www.IndyPASS.org
317.208.2538 - FAX (317.706.2660) -BUpdegraff@.CroweChizek.com|||Excuse the ignorance. Whats the BOL? If you means sql books online then I
have already checked there and I couldn't find it...I wanted to look in the
source for the SubscriptionsProperties.aspx page but it is compiled and I
haven't bothered to run reflector against it.
"Bret Updegraff" wrote:
> The quick answer is YES, everything that is done in the ReportManager
> uses the web service interface. I would check the BOL for the specific
> details.
>
> "Steven Molen" <StevenMolen@.discussions.microsoft.com> wrote in message
> news:7B87FBF2-5CE0-4298-8DD7-7FA9A586FD9D@.microsoft.com:
> > In SQL 2005 Reporting Services, on the page that you use to set a schedule
> > for a subscription, there is an option to run a report once. Is there a way
> > through the web service interface to invoke this specific schedule? Do you
> > use the NoRecurrence object?
> >
> > (The options are: Hour, Day, Weekly, Monthly, Once)
>
> --
> Bret Updegraff, MCAD,MCSD,MCDBA
> Microsoft MVP - SQL Server
> Crowe Chizek and Company LLC
> President - Indianapolis Professional Association for SQL Server
> Join our SQL Server Community http;//www.IndyPASS.org
> 317.208.2538 - FAX (317.706.2660) -BUpdegraff@.CroweChizek.com
>|||OK. The answer wasn't in the BOL. Pfft. The SQL BOL is very light when it
comes to the web service and what it can and can't do.
I got "unlazy" and pulled out my reflector and deconstructed the
SubscriptionProperties page (All the report services pages are compiled
pages). Needless to say, my answer I was looking for wasn't on that page but
in a custom class that they were using to construct the schedule portion of
the subscription.
(Specifically Microsoft.ReportingServices.UI.ScheduleControl within the
ReportingServicesWebUserInterface.dll)
The method that most caught my interest was TaskToScheduleDefinition() since
I was using the scheduledefinition object inherently. The short answer is:
DO NOT set the Schedule.Item and to leave it null. Only set the
StartDateTime on the schedule object.
I tested this theory that I picked up from looking at the disassembled code
and my Subscriber object worked perfectly with the schedule object set as
described above.
Here is the code from the reporting services assembly if your interested.
This is from SQL 2005 of course and only has to do with setting the schedule
object and not the rest of the code needed to set up a full subscription:
internal static ScheduleDefinition TaskToScheduleDefinition(Task task)
{
ScheduleDefinition definition1 = new ScheduleDefinition();
definition1.StartDateTime = task.StartDateTime;
definition1.EndDate = task.EndDate;
definition1.EndDateSpecified = false;
if (task.EndDate != DateTime.MinValue)
{
definition1.EndDateSpecified = true;
}
switch (task.Trigger.RecurrenceType)
{
case RecurrenceType.Once:
{
return definition1;
}
case RecurrenceType.Minutes:
{
MinuteRecurrence recurrence1 = new MinuteRecurrence();
recurrence1.MinutesInterval = ((Minutes)
task.Trigger.TriggerData).MinutesInterval;
definition1.Item = recurrence1;
return definition1;
}
case RecurrenceType.Daily:
{
DailyRecurrence recurrence2 = new DailyRecurrence();
recurrence2.DaysInterval = (int) ((Daily)
task.Trigger.TriggerData).DaysInterval;
definition1.Item = recurrence2;
return definition1;
}
case RecurrenceType.Weekly:
{
WeeklyRecurrence recurrence3 = new WeeklyRecurrence();
Weekly weekly1 = (Weekly) task.Trigger.TriggerData;
recurrence3.DaysOfWeek =ScheduleControl.UintToDaysOfWeek(weekly1.DaysOfWeek);
recurrence3.WeeksInterval = (int) weekly1.WeeksInterval;
recurrence3.WeeksIntervalSpecified = true;
definition1.Item = recurrence3;
return definition1;
}
case RecurrenceType.MonthlyDate:
{
MonthlyRecurrence recurrence4 = new MonthlyRecurrence();
Monthly monthly1 = (Monthly) task.Trigger.TriggerData;
recurrence4.Days =Monthly.GetDayRange(monthly1.DaysOfMonth);
recurrence4.MonthsOfYear =ScheduleControl.UintToMonthsOfYear(monthly1.Months);
definition1.Item = recurrence4;
return definition1;
}
case RecurrenceType.MonthlyDOW:
{
MonthlyDOWRecurrence recurrence5 = new
MonthlyDOWRecurrence();
MonthlyDOW ydow1 = (MonthlyDOW) task.Trigger.TriggerData;
recurrence5.DaysOfWeek =ScheduleControl.UintToDaysOfWeek(ydow1.DaysOfWeek);
recurrence5.MonthsOfYear =ScheduleControl.UintToMonthsOfYear(ydow1.Months);
recurrence5.WhichWeek =ScheduleControl.UintToWhichWeek(ydow1.Week);
recurrence5.WhichWeekSpecified = true;
definition1.Item = recurrence5;
return definition1;
}
}
return definition1;
}
"Steven Molen" wrote:
> Excuse the ignorance. Whats the BOL? If you means sql books online then I
> have already checked there and I couldn't find it...I wanted to look in the
> source for the SubscriptionsProperties.aspx page but it is compiled and I
> haven't bothered to run reflector against it.
> "Bret Updegraff" wrote:
> > The quick answer is YES, everything that is done in the ReportManager
> > uses the web service interface. I would check the BOL for the specific
> > details.
> >
> >
> > "Steven Molen" <StevenMolen@.discussions.microsoft.com> wrote in message
> > news:7B87FBF2-5CE0-4298-8DD7-7FA9A586FD9D@.microsoft.com:
> >
> > > In SQL 2005 Reporting Services, on the page that you use to set a schedule
> > > for a subscription, there is an option to run a report once. Is there a way
> > > through the web service interface to invoke this specific schedule? Do you
> > > use the NoRecurrence object?
> > >
> > > (The options are: Hour, Day, Weekly, Monthly, Once)
> >
> >
> > --
> > Bret Updegraff, MCAD,MCSD,MCDBA
> > Microsoft MVP - SQL Server
> > Crowe Chizek and Company LLC
> > President - Indianapolis Professional Association for SQL Server
> > Join our SQL Server Community http;//www.IndyPASS.org
> > 317.208.2538 - FAX (317.706.2660) -BUpdegraff@.CroweChizek.com
> >
> >