Showing posts with label application. Show all posts
Showing posts with label application. Show all posts

Friday, March 30, 2012

Launching a Report From an Application

We are trying to launch a report from an application. All that happens is
that the applciation gives the user a link that it dynamically builds,
populating all of the parameters for the user.
Currently the link launches the report, but we wanted two things to happen.
We did not want to show the parameters to the user from within the report and
we also wanted to kkep the tool bar, the green spirally thing when loadign
and the drop downs for exporting.
But it seems like you can either have all that studd on the toolbar and be
able to see the parameters or don't see the parameters and don't see the
toolb bar of green spirally thing.
Any suggestions here? I want to see the toolbar, but I do not want to see
the parameters.Have you tried using
&rc:Toolbar=true&rc:Parameters=false
Wayne Snyder, MCDBA, SQL Server MVP
Mariner, Charlotte, NC
www.mariner-usa.com
(Please respond only to the newsgroups.)
I support the Professional Association of SQL Server (PASS) and it's
community of SQL Server professionals.
www.sqlpass.org
"Cooper" <Cooper@.discussions.microsoft.com> wrote in message
news:393DA10F-2182-4CA0-B5FD-C617C870384E@.microsoft.com...
> We are trying to launch a report from an application. All that happens is
> that the applciation gives the user a link that it dynamically builds,
> populating all of the parameters for the user.
> Currently the link launches the report, but we wanted two things to
> happen.
> We did not want to show the parameters to the user from within the report
> and
> we also wanted to kkep the tool bar, the green spirally thing when loadign
> and the drop downs for exporting.
> But it seems like you can either have all that studd on the toolbar and be
> able to see the parameters or don't see the parameters and don't see the
> toolb bar of green spirally thing.
> Any suggestions here? I want to see the toolbar, but I do not want to see
> the parameters.

Launch DTS with OLAP from .net application

Hi,

with reference to the following thread:

http://forums.microsoft.com/msdn/ShowPost.aspx?postid=740855&isthread=false&siteid=1&authhash=775a583435c503730bf96695fe78ffc77f04a290&ticks=632942355374528292

Which in summary is that I am trying to execute DTS packages containing OLAP tasks to process cubes from an application. It hangs and fails after an hour and some minutes.

the code :

Package2Class package = new Package2Class();

object pVarPersistStgOfHost = null;

package.LoadFromSQLServer(serverName,null,null,DTSSQLServerStorageFlags.DTSSQLStgFlag_UseTrustedConnection,null,null,null,packageName,ref VarPersistStgOfHost);

package.Execute();

I have launched the DTS on command prompt using DTSRUN on the computer I am trying to execute my code, and it executes marvellously.

DTSRUN can also execute a DTS on another physical server Alpha for instance which process a cube of AS2000 found on another physical server Beta for instance.

Since I need to check that each steps have been executed properly and that running DTSRUN from the application is not a possibility to do so, I need a way to be able to launch the DTS and get to know which steps is failing. the above code is supposingly a way but its failing on LoadFromSQLServer() method.

I am using SQL Server 2000 and AS2000 and .net 1.1 (modifying a legacy system to enable the above facility).

Any views please?

Thanks

Is there any error message?

If so, can you paste here its full text (replacing any confidential information like server names, IP addresses, user names, passwords etc.)?

|||There is no error page. The steps in the package are with status "failed". Thats it.|||

I am moving this to the "SQL Server Integration Services" forum (successor to DTS), which may be able to help troubleshooting.

|||

Failing on the LoadFromSQLServer method should be quick, and I would expect an exception.

The Execute on the other hand will not raise an exception. Use package logging and/or implement the events interface to get more detail of tasks that fail in the package.

If the LoadFromSqlServer fails, perhaps try another storage location just to see if you can isolate the problem for now.

|||

HTH.

Dim EventsSSIS As Eventos

EventsSSIS = New Eventos()

sResultDts = pkg.Execute(Nothing, Nothing, EventsSSIS, Nothing, Nothing)

..

..

..

Public Class Eventos

Implements IDTSEvents

Sub OnExecutionStatusChanged(ByVal exec As Executable, ByVal newStatus As DTSExecStatus, ByRef fireAgain As Boolean) Implements IDTSEvents.OnExecutionStatusChanged

End Sub

Sub OnBreakpointHit(ByVal breakpointSite As IDTSBreakpointSite, ByVal breakpointTarget As BreakpointTarget) Implements IDTSEvents.OnBreakpointHit

End Sub

|||

I am using .net 1.1 and SQL server 2000. I do not have SSIS.

The solution is to use Stored procedure to launch it, this relieving this responsibility from the .net application.

there is a call from the stored proc called the LoadFromSQLServer that can be used for this purpose.

Thanks

Launch condition to detect SQL CE?

I have written a .NET application that uses SQL Server Compact Edition. It's deployed by a MSI file (setup project in VS - not ClickOnce).

How do I add a SQL CE launch condition to my setup project?

Never mind. I'm now using the bootstrapper and added the SQL CE requirement there.sql

Launch condition to detect SQL CE?

I have written a .NET application that uses SQL Server Compact Edition. It's deployed by a MSI file (setup project in VS - not ClickOnce).

How do I add a SQL CE launch condition to my setup project?

Never mind. I'm now using the bootstrapper and added the SQL CE requirement there.

launch an appl from a trigger ?

Is there a way to launch an application(c:\hello.exe)
from a trigger when a new record is inserted into the
table or
a record is updated in the table?
If so, what is the correct syntax ?
THANKS!Understand that launching an application that requires the input from a =user can extremely critical ... This is because this app is invoked in =the same process of SQL Server and the credential of the user to =interact with desktop maynot be there ... Hence such operation can stop =the SQL Server service ... Hence avoid such operations ...
On the contrary you like to send a popup using the network messenger =service then use the xp_cmdshell command ... But it is not recommended =in production code ...
-- HTH,
Vinod Kumar
MCSE, DBA, MCAD
http://www.extremeexperts.com/
"amy" <achen@.comverge.com> wrote in message =news:0d7f01c3576d$ed56db10$a401280a@.phx.gbl...
> Is there a way to launch an application(c:\hello.exe)
> from a trigger when a new record is inserted into the > table or > a record is updated in the table?
> > If so, what is the correct syntax ?
> > THANKS!|||Amy,
You can use the xp_cmdshell extended procedure to start an application from
the command prompt. For exact syntax, do please refer to Books OnLine.
--
Dejan Sarka, SQL Server MVP
FAQ from Neil & others at: http://www.sqlserverfaq.com
Please reply only to the newsgroups.
PASS - the definitive, global community
for SQL Server professionals - http://www.sqlpass.org
"amy" <achen@.comverge.com> wrote in message
news:0d7f01c3576d$ed56db10$a401280a@.phx.gbl...
> Is there a way to launch an application(c:\hello.exe)
> from a trigger when a new record is inserted into the
> table or
> a record is updated in the table?
> If so, what is the correct syntax ?
> THANKS!|||I would investigate having the .exe be part of a "job"
under DTS Local Packages and having the trigger start
that job - not really sure if this is possible. If it
did work, it would get around the issues raised here
about having the .exe hang things up, etc.
>--Original Message--
>Amy,
>What are you trying to do ? Ofcourse you can launch an
application by using
>master..xp_cmdshell, as in
>exec master..xp_cmdshell "dtsrun /?"
>But for every insert and update? well , no..I wont do
that.Also, if this
>hello.exe has any GUI as in exec
master..xp_cmdshell "notepad" ,
>master..xp_cmdshell would hang leading to timeout
problems.
>--
>Dinesh.
>SQL Server FAQ at
>http://www.tkdinesh.com
>"amy" <achen@.comverge.com> wrote in message
>news:0d7f01c3576d$ed56db10$a401280a@.phx.gbl...
>> Is there a way to launch an application(c:\hello.exe)
>> from a trigger when a new record is inserted into the
>> table or
>> a record is updated in the table?
>> If so, what is the correct syntax ?
>> THANKS!
>
>.
>|||Steve,
Since you replied to my post...
It may work or may be we can find a workaround but I still wont do that.In a
heavy OLTP system, triggers are always a overhead for the DML and a trigger
which calls a exe, gui or no gui , would be a recipe for disaster.
--
Dinesh.
SQL Server FAQ at
http://www.tkdinesh.com
"Steve Z" <szlamany@.antarescomputing.com> wrote in message
news:0c5801c35772$9a1f0bc0$a601280a@.phx.gbl...
> I would investigate having the .exe be part of a "job"
> under DTS Local Packages and having the trigger start
> that job - not really sure if this is possible. If it
> did work, it would get around the issues raised here
> about having the .exe hang things up, etc.
> >--Original Message--
> >Amy,
> >
> >What are you trying to do ? Ofcourse you can launch an
> application by using
> >master..xp_cmdshell, as in
> >
> >exec master..xp_cmdshell "dtsrun /?"
> >
> >But for every insert and update? well , no..I wont do
> that.Also, if this
> >hello.exe has any GUI as in exec
> master..xp_cmdshell "notepad" ,
> >master..xp_cmdshell would hang leading to timeout
> problems.
> >
> >--
> >Dinesh.
> >SQL Server FAQ at
> >http://www.tkdinesh.com
> >
> >"amy" <achen@.comverge.com> wrote in message
> >news:0d7f01c3576d$ed56db10$a401280a@.phx.gbl...
> >> Is there a way to launch an application(c:\hello.exe)
> >> from a trigger when a new record is inserted into the
> >> table or
> >> a record is updated in the table?
> >>
> >> If so, what is the correct syntax ?
> >>
> >> THANKS!
> >
> >
> >.
> >|||I agree that other paths might serve the same purpose,
but I'm not sure what the need really is. It would make
more sense to me to have a "scheduled" job run regularly
(every x minutes) and sweep up handling all the "rows"
inserted since the last sweep. Or code the .exe in C and
make it an extended stored procedure - run right from
inside the trigger. Or simply code the need in T-Sql and
get rid of the .exe requirement...
>--Original Message--
>Steve,
>Since you replied to my post...
>It may work or may be we can find a workaround but I
still wont do that.In a
>heavy OLTP system, triggers are always a overhead for
the DML and a trigger
>which calls a exe, gui or no gui , would be a recipe for
disaster.
>--
>Dinesh.
>SQL Server FAQ at
>http://www.tkdinesh.com
>"Steve Z" <szlamany@.antarescomputing.com> wrote in
message
>news:0c5801c35772$9a1f0bc0$a601280a@.phx.gbl...
>> I would investigate having the .exe be part of a "job"
>> under DTS Local Packages and having the trigger start
>> that job - not really sure if this is possible. If it
>> did work, it would get around the issues raised here
>> about having the .exe hang things up, etc.
>> >--Original Message--
>> >Amy,
>> >
>> >What are you trying to do ? Ofcourse you can launch an
>> application by using
>> >master..xp_cmdshell, as in
>> >
>> >exec master..xp_cmdshell "dtsrun /?"
>> >
>> >But for every insert and update? well , no..I wont do
>> that.Also, if this
>> >hello.exe has any GUI as in exec
>> master..xp_cmdshell "notepad" ,
>> >master..xp_cmdshell would hang leading to timeout
>> problems.
>> >
>> >--
>> >Dinesh.
>> >SQL Server FAQ at
>> >http://www.tkdinesh.com
>> >
>> >"amy" <achen@.comverge.com> wrote in message
>> >news:0d7f01c3576d$ed56db10$a401280a@.phx.gbl...
>> >> Is there a way to launch an application
(c:\hello.exe)
>> >> from a trigger when a new record is inserted into
the
>> >> table or
>> >> a record is updated in the table?
>> >>
>> >> If so, what is the correct syntax ?
>> >>
>> >> THANKS!
>> >
>> >
>> >.
>> >
>
>.
>|||Steve,
Well if you are asking which of the requirement to take then, my =suggestion would be to use the T-SQL method and a jobs framework ... It =is simply because you are closer to the data and getting out of process =of SQL and then get the job done is something not advisable ...
Now trigger can prove costlier as this will fire with every insert =operation ... But would make it more live data ...
-- HTH,
Vinod Kumar
MCSE, DBA, MCAD
http://www.extremeexperts.com/
"Steve Z" <szlamany@.antarescomputing.com> wrote in message =news:0eb201c35779$6045c3b0$a401280a@.phx.gbl...
> I agree that other paths might serve the same purpose, > but I'm not sure what the need really is. It would make > more sense to me to have a "scheduled" job run regularly > (every x minutes) and sweep up handling all the "rows" > inserted since the last sweep. Or code the .exe in C and > make it an extended stored procedure - run right from > inside the trigger. Or simply code the need in T-Sql and > get rid of the .exe requirement...
> >--Original Message--
> >Steve,
> >
> >Since you replied to my post...
> >
> >It may work or may be we can find a workaround but I > still wont do that.In a
> >heavy OLTP system, triggers are always a overhead for > the DML and a trigger
> >which calls a exe, gui or no gui , would be a recipe for > disaster.
> >
> >-- > >Dinesh.
> >SQL Server FAQ at
> >http://www.tkdinesh.com
> >
> >"Steve Z" <szlamany@.antarescomputing.com> wrote in > message
> >news:0c5801c35772$9a1f0bc0$a601280a@.phx.gbl...
> >> I would investigate having the .exe be part of a "job"
> >> under DTS Local Packages and having the trigger start
> >> that job - not really sure if this is possible. If it
> >> did work, it would get around the issues raised here
> >> about having the .exe hang things up, etc.
> >>
> >> >--Original Message--
> >> >Amy,
> >> >
> >> >What are you trying to do ? Ofcourse you can launch an
> >> application by using
> >> >master..xp_cmdshell, as in
> >> >
> >> >exec master..xp_cmdshell "dtsrun /?"
> >> >
> >> >But for every insert and update? well , no..I wont do
> >> that.Also, if this
> >> >hello.exe has any GUI as in exec
> >> master..xp_cmdshell "notepad" ,
> >> >master..xp_cmdshell would hang leading to timeout
> >> problems.
> >> >
> >> >-- > >> >Dinesh.
> >> >SQL Server FAQ at
> >> >http://www.tkdinesh.com
> >> >
> >> >"amy" <achen@.comverge.com> wrote in message
> >> >news:0d7f01c3576d$ed56db10$a401280a@.phx.gbl...
> >> >> Is there a way to launch an application
> (c:\hello.exe)
> >> >> from a trigger when a new record is inserted into > the
> >> >> table or
> >> >> a record is updated in the table?
> >> >>
> >> >> If so, what is the correct syntax ?
> >> >>
> >> >> THANKS!
> >> >
> >> >
> >> >.
> >> >
> >
> >
> >.
> >

Monday, March 26, 2012

Late Get error

While doing a demonstration of an alpha application written in VB.NET, I got
an error message complaining of a Late Get. I am presuming that this is a
SQL Server related error, rather than a VB.NET error, but not sure. Any
know what might generally be causing this error message?
I have never seen this error during extensive testing of that form prior to
the demonstration, and tried to recreate it after the demonstration, but to
no avail.
Any thoughts would be appreciated.
Dean SlindeeCan you post the exact error message, plus some demo code. Someone might
have some insight to the problem.
-oj
"Dean Slindee" <slindee@.charter.net> wrote in message
news:hU1Wd.29517$Ep.6413@.fe06.lga...
> While doing a demonstration of an alpha application written in VB.NET, I
> got
> an error message complaining of a Late Get. I am presuming that this is a
> SQL Server related error, rather than a VB.NET error, but not sure. Any
> know what might generally be causing this error message?
> I have never seen this error during extensive testing of that form prior
> to
> the demonstration, and tried to recreate it after the demonstration, but
> to
> no avail.
> Any thoughts would be appreciated.
> Dean Slindee
>

Friday, February 24, 2012

Large scale databases - common practice

Hi,
We are designing a large-scale database application. The current one will
receive information from many inputs constantly.
We expect it to grow in one year to 60GB (on average of 4-5GB/Mo).
The database then (after one year) will have a cleaning procedure that will
delete information and the size of the database will not increase
significantly.
Here are a few questions:
1. What are the guide lines to design and implement such a database? Where
can I find information on the web on such cases?
2. From database creation point of view - should we use a few files that
will create the database or should we use only one ? If we use a few files,
what happends to clustered indexes? Where can I find more reading material?
3. The database has the management tables of the application and the data
tables. One data table will hold most of the information in that database. Do
you think I need to divide te table? if so, how do we do it? What is the
common practice in such cases where a huge table holds so much info
(Currently we have a similar database with 27M records in).
how do you build efficient queries? How do you manage the data in the
separate tables? How do you manage indexes? and again where can I find
material on this?
We know to look inside the BOL but we are looking for common practice
solutions.
TIA!!
Noam
Please don't post independently in separate newsgroups. You can add
multiple newsgroups to the header and then all the answers appear as one.
See my reply in the other newsgroup.
Andrew J. Kelly SQL MVP
"Noam" <Noam@.discussions.microsoft.com> wrote in message
news:2DCD3F8D-DFCF-46F7-BB1C-30355D49B321@.microsoft.com...
> Hi,
> We are designing a large-scale database application. The current one will
> receive information from many inputs constantly.
> We expect it to grow in one year to 60GB (on average of 4-5GB/Mo).
> The database then (after one year) will have a cleaning procedure that
will
> delete information and the size of the database will not increase
> significantly.
> Here are a few questions:
> 1. What are the guide lines to design and implement such a database? Where
> can I find information on the web on such cases?
> 2. From database creation point of view - should we use a few files that
> will create the database or should we use only one ? If we use a few
files,
> what happends to clustered indexes? Where can I find more reading
material?
> 3. The database has the management tables of the application and the data
> tables. One data table will hold most of the information in that database.
Do
> you think I need to divide te table? if so, how do we do it? What is the
> common practice in such cases where a huge table holds so much info
> (Currently we have a similar database with 27M records in).
> how do you build efficient queries? How do you manage the data in the
> separate tables? How do you manage indexes? and again where can I find
> material on this?
> We know to look inside the BOL but we are looking for common practice
> solutions.
> TIA!!
> Noam
>
|||Thank you for your fast reply. This is the first time I posted here and I
will do as you suggest next time!.
Thanks.
Noam
"Andrew J. Kelly" wrote:

> Please don't post independently in separate newsgroups. You can add
> multiple newsgroups to the header and then all the answers appear as one.
> See my reply in the other newsgroup.
>
> --
> Andrew J. Kelly SQL MVP
>
> "Noam" <Noam@.discussions.microsoft.com> wrote in message
> news:2DCD3F8D-DFCF-46F7-BB1C-30355D49B321@.microsoft.com...
> will
> files,
> material?
> Do
>
>

Large scale databases - common practice

Hi,
We are designing a large-scale database application. The current one will
receive information from many inputs constantly.
We expect it to grow in one year to 60GB (on average of 4-5GB/Mo).
The database then (after one year) will have a cleaning procedure that will
delete information and the size of the database will not increase
significantly.
Here are a few questions:
1. What are the guide lines to design and implement such a database? Where
can I find information on the web on such cases?
2. From database creation point of view - should we use a few files that
will create the database or should we use only one ? If we use a few files,
what happends to clustered indexes? Where can I find more reading material?
3. The database has the management tables of the application and the data
tables. One data table will hold most of the information in that database. Do
you think I need to divide te table? if so, how do we do it? What is the
common practice in such cases where a huge table holds so much info
(Currently we have a similar database with 27M records in).
how do you build efficient queries? How do you manage the data in the
separate tables? How do you manage indexes? and again where can I find
material on this?
We know to look inside the BOL but we are looking for common practice
solutions.
TIA!!
NoamPlease don't post independently in separate newsgroups. You can add
multiple newsgroups to the header and then all the answers appear as one.
See my reply in the other newsgroup.
Andrew J. Kelly SQL MVP
"Noam" <Noam@.discussions.microsoft.com> wrote in message
news:2DCD3F8D-DFCF-46F7-BB1C-30355D49B321@.microsoft.com...
> Hi,
> We are designing a large-scale database application. The current one will
> receive information from many inputs constantly.
> We expect it to grow in one year to 60GB (on average of 4-5GB/Mo).
> The database then (after one year) will have a cleaning procedure that
will
> delete information and the size of the database will not increase
> significantly.
> Here are a few questions:
> 1. What are the guide lines to design and implement such a database? Where
> can I find information on the web on such cases?
> 2. From database creation point of view - should we use a few files that
> will create the database or should we use only one ? If we use a few
files,
> what happends to clustered indexes? Where can I find more reading
material?
> 3. The database has the management tables of the application and the data
> tables. One data table will hold most of the information in that database.
Do
> you think I need to divide te table? if so, how do we do it? What is the
> common practice in such cases where a huge table holds so much info
> (Currently we have a similar database with 27M records in).
> how do you build efficient queries? How do you manage the data in the
> separate tables? How do you manage indexes? and again where can I find
> material on this?
> We know to look inside the BOL but we are looking for common practice
> solutions.
> TIA!!
> Noam
>|||Thank you for your fast reply. This is the first time I posted here and I
will do as you suggest next time!.
Thanks.
Noam
"Andrew J. Kelly" wrote:
> Please don't post independently in separate newsgroups. You can add
> multiple newsgroups to the header and then all the answers appear as one.
> See my reply in the other newsgroup.
>
> --
> Andrew J. Kelly SQL MVP
>
> "Noam" <Noam@.discussions.microsoft.com> wrote in message
> news:2DCD3F8D-DFCF-46F7-BB1C-30355D49B321@.microsoft.com...
> > Hi,
> >
> > We are designing a large-scale database application. The current one will
> > receive information from many inputs constantly.
> >
> > We expect it to grow in one year to 60GB (on average of 4-5GB/Mo).
> >
> > The database then (after one year) will have a cleaning procedure that
> will
> > delete information and the size of the database will not increase
> > significantly.
> >
> > Here are a few questions:
> > 1. What are the guide lines to design and implement such a database? Where
> > can I find information on the web on such cases?
> > 2. From database creation point of view - should we use a few files that
> > will create the database or should we use only one ? If we use a few
> files,
> > what happends to clustered indexes? Where can I find more reading
> material?
> > 3. The database has the management tables of the application and the data
> > tables. One data table will hold most of the information in that database.
> Do
> > you think I need to divide te table? if so, how do we do it? What is the
> > common practice in such cases where a huge table holds so much info
> > (Currently we have a similar database with 27M records in).
> > how do you build efficient queries? How do you manage the data in the
> > separate tables? How do you manage indexes? and again where can I find
> > material on this?
> >
> > We know to look inside the BOL but we are looking for common practice
> > solutions.
> >
> > TIA!!
> >
> > Noam
> >
>
>