Thursday, March 22, 2012
Do I need a data extension?
complex class that allows them to do various forms of sales estimations for
stores who fail to report their weekly sales. I say "complex" because it
has a detailed class hierarchy under it and performs lot of SQL Server work
inside its "black box." Using this class within a web page is working
great...
Now they want this functionality to also appear in a report, and I'm
wondering what I have to do -- never done a RS data extension and first am
wondering: Is this what I need to add this function to a report?
If the answer is "yes," is there a resource that describes in detail how to
do it, with a non-trivial example?
I'm really under the gun on this one, so I'll be grateful for any help --
thanks!
JoeI'd start with the sample reports that ship with the product. Check
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/RSAMPLES/htm/rss_overview_v1_631v.asp?frame=true
for details.
--
Ravi Mumulla (Microsoft)
SQL Server Reporting Services
This posting is provided "AS IS" with no warranties, and confers no rights.
"Joe Helmick" <joe_helmick@.4dv.net> wrote in message
news:O2r7tE5jEHA.1652@.TK2MSFTNGP09.phx.gbl...
> I'm working on a project for a national restaurant chain. I've built a
> complex class that allows them to do various forms of sales estimations
for
> stores who fail to report their weekly sales. I say "complex" because it
> has a detailed class hierarchy under it and performs lot of SQL Server
work
> inside its "black box." Using this class within a web page is working
> great...
> Now they want this functionality to also appear in a report, and I'm
> wondering what I have to do -- never done a RS data extension and first am
> wondering: Is this what I need to add this function to a report?
> If the answer is "yes," is there a resource that describes in detail how
to
> do it, with a non-trivial example?
> I'm really under the gun on this one, so I'll be grateful for any help --
> thanks!
> Joe
>|||Joe,
One option in your scenario may be to dump your object data (state) in a
database before the report is run. Unfortunately, version 1.0 of Reporting
Services doesn't support events, so to implement preprocessing you need to
get somewhat innovative. One option is to attach an expression to a property
of the report body band (it will fire before the regions get loaded). This
expression could gather the report parameters, pass it to your object which
in turn can serialize itself to the database and let the regions pick data
from there. Of course, this is a rather simplified version of what you may
need to do.
Yes, another and more elegant option is to wrap you object in a custom data
extension. This is actually very straightforward. You need to expose your
object data as a forward-only tabular stream which conforms to the
IDataReader interface. You may find my ADO.NET custom data extension
(http://www.gotdotnet.com/Community/UserSamples/Details.aspx?SampleGuid=B846
8707-56EF-4864-AC51-D83FC3273FE5) useful to get you started. It comes with
step-by-step help instructions.
Hope this helps.
----
Teo Lachev, MCSD, MCT
Author: "Microsoft Reporting Services in Action"
Publisher website: http://www.manning.com/lachev
Buy it from Amazon.com: http://shrinkster.com/eq
Home page and blog: http://www.prologika.com/
----
"Joe Helmick" <joe_helmick@.4dv.net> wrote in message
news:0l1aj0h4452vd72jles53foioiqfhfdphn@.4ax.com...
> Ravi,
> Thanks, but I have all the samples and unless I missed something due
> to my newbie-ness, I don't see what I need. I don't need drilldown or
> drillthrough, and simple functions in a code-behind don't seem like
> they'd nearly fill the bill. I'm already doing cascading parameters
> from multiple datasets and stuff like that, no problem, but attaching
> functionality from a 700-line VB class with deep inheritance? I don't
> see anything like that in the samples...
> Did I miss something, or do I need another resource besides the
> samples?
> Joe
> "Ravi Mumulla \(Microsoft\)" <ravimu@.online.microsoft.com> bellowed
> forth with this wisdom for all to hear:
> > I'd start with the sample reports that ship with the product. Check
> >
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/RSAMPLES/htm/rss_overview_v1_631v.asp?frame=true
> > for details.
>sql
Sunday, March 11, 2012
DLL wanted!
know?|
| SQLVersionControl.VCS_SQL class. Which dll contains that class? Does
anybody
| know?
|
--
The dll you're after is mdt2dbsv.dll. The description for this dll is
Microsoft Design Tools - VID/VSS integration. This dll comes with Visual
Studio.
Hope this helps,
--
Eric Cárdenas
SQL Server support
dll in c# sql 2005
I wrote a class in C# with one method that returns a string. I built the dll and deployed it into sql 2005 and everything works just fine.
I am now in a situation where I need to use this function in SQL 2000. Is there any way that I can use the existing dll and create a sql 2000 function, and if so how do I go about doing this?
Here is the c# code from the deployed dll.
using System;
using System.Data;
using System.Data.SqlClient;
using System.Data.SqlTypes;
using Microsoft.SqlServer.Server;
using System.Text.RegularExpressions;
public partial class GECBI
{
[Microsoft.SqlServer.Server.SqlFunction(IsDeterministic = true, IsPrecise = true)]
public static string RegExMatch(string pattern, string matchString)
{
Regex r1 = new Regex(pattern);
if (r1.Match(matchString.TrimEnd(null)).Success)
{
Regex testReg = new Regex(pattern);
Match regMatch = testReg.Match(matchString);
string runnumber = regMatch.ToString();
return runnumber;
}
else
{
return null;
}
}
};
Accesing CLR Function is only possible in SQL2k5. Wrapping the .NET object in a COM object or calling the function on a SQL2k5 Server would be very slow during execution time.HTH, JEns K. Suessmeyer.
http://www.sqlserver2005.de|||So what would be an alternative for me to achieve the above? Can someone give me an example of how to create the above function in something that I can use with sql 2k please?|||There is actually no alternativ for that. have a look in the internet, there have been some samples implemented to mimic the functionality.
http://www.google.de/search?hl=de&q=regular+expressions+sql+server+2000&meta= http://www.codeproject.com/managedcpp/xpregex.asp
HTH, Jens K. Suessmeyer.
http://www.sqlserver2005.de
DLL and Xtended Proc...
I've created my own sendmail in VB6 SP5 as a DLL and put it on my SQL server
2K SP3. I've a class module with only one public funtion in it.
I want to use the function in this dll so I decalred my DLL as an extended
proc in SQL . apprently SQL doesn't recognize the function in my dll. How
can I use it? What's the best way to do it?
Best regards,I'm not sure if a VB6 DLL can be registered as an extended stored procedure
this way.
If you want to use the functionality of your DLL from SQL Server, you could
use the sp_OA* set of procedures for the same. Refer to
http://www32.brinkster.com/srisamp/sqlarchives.asp for articles on COM
accessibility. You can refer to the articles titled "Using COM Objects in
SQL Server" and "Extending SQL Server with COM Objects".
--
HTH,
SriSamp
Please reply to the whole group only!
http://www32.brinkster.com/srisamp
"Philippe RUELLO" <pruello@.tibco.fr> wrote in message
news:OMjpLlYuDHA.2712@.tk2msftngp13.phx.gbl...
> Hello,
> I've created my own sendmail in VB6 SP5 as a DLL and put it on my SQL
server
> 2K SP3. I've a class module with only one public funtion in it.
> I want to use the function in this dll so I decalred my DLL as an extended
> proc in SQL . apprently SQL doesn't recognize the function in my dll. How
> can I use it? What's the best way to do it?
> Best regards,
>|||Just to confirm - VB only produces COM type .dlls, not call level type which
are required for extended stored procedures. So you cannot register VB .dlls
for use as extended stored procedures in SQL Server.
The other method that SriSamp has suggested (sp_OACreate) is the only way to
access your VB .dll directly from T-SQL.
Regards,
Greg Linwood
SQL Server MVP
"SriSamp" <ssampath@.sct.co.in> wrote in message
news:#j7#xrYuDHA.1576@.TK2MSFTNGP11.phx.gbl...
> I'm not sure if a VB6 DLL can be registered as an extended stored
procedure
> this way.
> If you want to use the functionality of your DLL from SQL Server, you
could
> use the sp_OA* set of procedures for the same. Refer to
> http://www32.brinkster.com/srisamp/sqlarchives.asp for articles on COM
> accessibility. You can refer to the articles titled "Using COM Objects in
> SQL Server" and "Extending SQL Server with COM Objects".
> --
> HTH,
> SriSamp
> Please reply to the whole group only!
> http://www32.brinkster.com/srisamp
> "Philippe RUELLO" <pruello@.tibco.fr> wrote in message
> news:OMjpLlYuDHA.2712@.tk2msftngp13.phx.gbl...
> > Hello,
> > I've created my own sendmail in VB6 SP5 as a DLL and put it on my SQL
> server
> > 2K SP3. I've a class module with only one public funtion in it.
> > I want to use the function in this dll so I decalred my DLL as an
extended
> > proc in SQL . apprently SQL doesn't recognize the function in my dll.
How
> > can I use it? What's the best way to do it?
> > Best regards,
> >
> >
>|||Thanks for the answer.
I tried to use that methos but i've some troubles using the attachements
with CDONT.Newmail
I could use Xp_sendmail, but I want to modify the parameter From.
Have some clues?
"SriSamp" <ssampath@.sct.co.in> a écrit dans le message de
news:%23j7%23xrYuDHA.1576@.TK2MSFTNGP11.phx.gbl...
> I'm not sure if a VB6 DLL can be registered as an extended stored
procedure
> this way.
> If you want to use the functionality of your DLL from SQL Server, you
could
> use the sp_OA* set of procedures for the same. Refer to
> http://www32.brinkster.com/srisamp/sqlarchives.asp for articles on COM
> accessibility. You can refer to the articles titled "Using COM Objects in
> SQL Server" and "Extending SQL Server with COM Objects".
> --
> HTH,
> SriSamp
> Please reply to the whole group only!
> http://www32.brinkster.com/srisamp
> "Philippe RUELLO" <pruello@.tibco.fr> wrote in message
> news:OMjpLlYuDHA.2712@.tk2msftngp13.phx.gbl...
> > Hello,
> > I've created my own sendmail in VB6 SP5 as a DLL and put it on my SQL
> server
> > 2K SP3. I've a class module with only one public funtion in it.
> > I want to use the function in this dll so I decalred my DLL as an
extended
> > proc in SQL . apprently SQL doesn't recognize the function in my dll.
How
> > can I use it? What's the best way to do it?
> > Best regards,
> >
> >
>|||How about xp_smtp_sendmail from www.SQLDev.Net?
--
Tibor Karaszi, SQL Server MVP
Archive at: http://groups.google.com/groups?oi=djq&as_ugroup=microsoft.public.sqlserver
"Philippe RUELLO" <pruello@.tibco.fr> wrote in message news:uXn1yUZuDHA.2408@.tk2msftngp13.phx.gbl...
> Thanks for the answer.
> I tried to use that methos but i've some troubles using the attachements
> with CDONT.Newmail
> I could use Xp_sendmail, but I want to modify the parameter From.
> Have some clues?
> "SriSamp" <ssampath@.sct.co.in> a écrit dans le message de
> news:%23j7%23xrYuDHA.1576@.TK2MSFTNGP11.phx.gbl...
> > I'm not sure if a VB6 DLL can be registered as an extended stored
> procedure
> > this way.
> > If you want to use the functionality of your DLL from SQL Server, you
> could
> > use the sp_OA* set of procedures for the same. Refer to
> > http://www32.brinkster.com/srisamp/sqlarchives.asp for articles on COM
> > accessibility. You can refer to the articles titled "Using COM Objects in
> > SQL Server" and "Extending SQL Server with COM Objects".
> > --
> > HTH,
> > SriSamp
> > Please reply to the whole group only!
> > http://www32.brinkster.com/srisamp
> >
> > "Philippe RUELLO" <pruello@.tibco.fr> wrote in message
> > news:OMjpLlYuDHA.2712@.tk2msftngp13.phx.gbl...
> > > Hello,
> > > I've created my own sendmail in VB6 SP5 as a DLL and put it on my SQL
> > server
> > > 2K SP3. I've a class module with only one public funtion in it.
> > > I want to use the function in this dll so I decalred my DLL as an
> extended
> > > proc in SQL . apprently SQL doesn't recognize the function in my dll.
> How
> > > can I use it? What's the best way to do it?
> > > Best regards,
> > >
> > >
> >
> >
>