Monday, March 26, 2012
More code access issues again
has necessitated dealing with code access security to a new degree. My
extension is actually a complex set of interdependant DLLs:
1. My managed assembly that implements the Data Extension and two delivery
extensions. This calls into...
2. A set of third party UNmanaged DLLs. Via a callback mechanism, these
call into...
3. Another of my managed assemblies.
By doing the following, my Data extension now runs perfectly in the browser
(via the report manager interface):
A. Create a Code Group in the policy config file.
B. Add AllowPartiallyTrustedCallers attribute to all my managed assemblies
C. Put my assemblies in the GAC
While my extension now works in the browser, it fails when run as a
scheduled report. My managed assembly #1 and the unmanaged DLLs #2 seem to
load, but in the log files I see:
Could not load file or assembly <my managed assembly #3, above> Failed to
grant minimum permission requests. (Exception from HRESULT: 0x80131417)
So I guess my question comes down to this: Why would the code access
security context be different when the report is run on a schedule as
opposed to being run on the server?
Thanks for you help!Hello Stephen,
How about turned off the Caspol by running command caspol -s off?
Also, please try to create a new code group.
1. On the Web server, open Administrative Tools, and then double-click
Microsoft
.NET Framework Configuration 2.0.
2. Expand Runtime Security Policy, expand Machine, and then expand Code
Groups.
3. Right-click All_Code, and then click New.
4. Select Create a new code group. Give your code group a relevant name,
such as
the name of the applications share.
5. Click Next.
6. In the Choose the condition type for this code group list, select GAC.
7. Click Next. On the next page, select Use an existing permission set, and
then
8. select FullTrust.
9. Click Next, and then click Finish.
Once these steps have been done, plese turn off the caspol and restart the
server.
Sincerely,
Wei Lu
Microsoft Online Community Support
==================================================
Get notification to my posts through email? Please refer to
http://msdn.microsoft.com/subscriptions/managednewsgroups/default.aspx#notif
ications.
Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
where an initial response from the community or a Microsoft Support
Engineer within 1 business day is acceptable. Please note that each follow
up response may take approximately 2 business days as the support
professional working with you may need further investigation to reach the
most efficient resolution. The offering is not appropriate for situations
that require urgent, real-time or phone-based interactions or complex
project analysis and dump analysis issues. Issues of this nature are best
handled working with a dedicated Microsoft Support Engineer by contacting
Microsoft Customer Support Services (CSS) at
http://msdn.microsoft.com/subscriptions/support/default.aspx.
==================================================(This posting is provided "AS IS", with no warranties, and confers no
rights.)|||I can not do "caspol -s off" in this environment, but I believe your other
comments have pointed me in the right direction. Thanks!
"Wei Lu [MSFT]" <weilu@.online.microsoft.com> wrote in message
news:1krHN%23KzGHA.4340@.TK2MSFTNGXA01.phx.gbl...
> Hello Stephen,
> How about turned off the Caspol by running command caspol -s off?
> Also, please try to create a new code group.
> 1. On the Web server, open Administrative Tools, and then double-click
> Microsoft
> NET Framework Configuration 2.0.
> 2. Expand Runtime Security Policy, expand Machine, and then expand Code
> Groups.
> 3. Right-click All_Code, and then click New.
> 4. Select Create a new code group. Give your code group a relevant name,
> such as
> the name of the applications share.
> 5. Click Next.
> 6. In the Choose the condition type for this code group list, select GAC.
> 7. Click Next. On the next page, select Use an existing permission set,
> and
> then
> 8. select FullTrust.
> 9. Click Next, and then click Finish.
> Once these steps have been done, plese turn off the caspol and restart the
> server.
> Sincerely,
> Wei Lu
> Microsoft Online Community Support
> ==================================================> Get notification to my posts through email? Please refer to
> http://msdn.microsoft.com/subscriptions/managednewsgroups/default.aspx#notif
> ications.
> Note: The MSDN Managed Newsgroup support offering is for non-urgent issues
> where an initial response from the community or a Microsoft Support
> Engineer within 1 business day is acceptable. Please note that each follow
> up response may take approximately 2 business days as the support
> professional working with you may need further investigation to reach the
> most efficient resolution. The offering is not appropriate for situations
> that require urgent, real-time or phone-based interactions or complex
> project analysis and dump analysis issues. Issues of this nature are best
> handled working with a dedicated Microsoft Support Engineer by contacting
> Microsoft Customer Support Services (CSS) at
> http://msdn.microsoft.com/subscriptions/support/default.aspx.
> ==================================================> (This posting is provided "AS IS", with no warranties, and confers no
> rights.)
>
Friday, March 23, 2012
Month and date wrong way around
Hi,
I am querying a report that was written with reporting services, via a webpage in vs2005. However when I input a date field to query from i.e 14/01/2007, this produces an error because the report is seeing this as 01/14/2007, even though in the database the record shows 14/01/2007? Please can someone offer any advice what to check?
thanks,
Harry.
Is that report runs client side?
|||It seems to happen when report is tested in 'preview mode', and when the report is deployed it happens on the client. An error results because it can't handle the DD/MM the wrong way around?
There must be something I'm missing here...?
Many thanks,
Harry
|||Hi, Harry:
You should try to format your date before you using them.
You can check out this article about how to format the date in SSRS.
http://msdn2.microsoft.com/en-us/library/ms157328.aspx
I hope the above information will be helpful. If you have any issues or concerns, please let me know. It's my pleasure to be of assistance
|||Hi,
I'm a little confused how I can use the conversions,
I'm passing StartDate AND EndDate from 2 txtboxes,, my data is SELECT par1, par2, par2 from tbldatabase1 WHERE par1 >@.StartDate and par1 <@.EndDate.
But the parameters from the date boxes are taken in the wrong wat around. Do you know how I can implement some code to change this?. My main visual studio pages are written in c#?.
Or would you do this in the query itself?
Any help would be greatly appreciated.
Thanks Harry.
|||HI,camper :
If your referring toReport Manager displaying the DateTime in theparameter input box, then no, you cannotformat this. You can onlyformat the date within thereport itself, or like the example I posted as following, give the user a dropdownparameter list of dates.
Apparently you can set theparameter to a string and then it won't enter the time, though you'll have to convert it into a date before it runs against your dataset. This way though,report users can enter a non-date as aparameter.
For some of myreports I create aparameter dataset based on the table holding the dates.
SELECT DATENAME(day, MyDateField) + ' ' + DATENAME(month, MyDateField) + ' ' + DATENAME(year, MyDateField) AS Label, MyDateField AS Value
FROM MyTable
GROUP BY DATENAME(day, MyDateField) + ' ' + DATENAME(month, MyDateField) + ' ' + DATENAME(year, MyDateField), MyDateField
ORDER BY MyDateField
This creates 2 fields, 'Label' which is what the user selects from and 'Value' which the dataset uses to query on.
Create aparameter (@.MyParameterDate) and reference it against your main dataset e.g.
SELECT * FROM MyTable WHERE MyDateField = @.MyParameterDate
In yourReportparameters set the values to be from a query and select yourparameter dataset. Set the Value and Label datafields to the ones created above and ensure theparameter datatype is DateTime. You can change the aboveformat if you don't want dates displaying as '7 November 2005'
I hope the above information will be helpful. If you have any issues or concerns, please let
me know. It's my pleasure to be of assistance
|||Hi,
I know it's a few months since the last entry but I was having the same problems and fixed it by setting the Report properties: Language Property to my locale (English (United Kingdom) in this case). You can get at these properties from the report designer (in local mode) and clicking on the grey area outside the design grid. This stopped the report from swapping the months and days around :-)
Good luck.
|||
Change this line in your model's smdl file
<Culture>de-DE</Culture>
In this case German yyyy.mm.dd
|||I am having the same problem. I saw your solution and tried that. However, it appears that those settings do not get passed to the report server. The report now correctly allows entry of the date in the Visual Studio designer, and when selected shows the date correctly, however, when the report is delpyed, the server, does not change behavior. It still thinks it is using mm/dd/yyy format.
Any ideas how to change the server side format to allow dd/mm/yy parameter format entry?
|||I also had to change regional settings to YYYY/MM/DD format on server. In layout view click properties on righthand side and select report from available fields, Click on language and choose English South Africa for YYYY/MM/DD format.sqlMonday, March 19, 2012
monitoring servers
and services on multiple different servers. Basically I want on screen
that can display that status of many sql servers and services on
multiple servers.
Thanks !bringmewater@.gmail.com a crit:
> Is there a way (script, tool, whatever) that I can monitor sql servers
> and services on multiple different servers. Basically I want on screen
> that can display that status of many sql servers and services on
> multiple servers.
>
Hello,
I've used Nagios for this purpose. You can have a look at
http://www.babaluga.org/doku.php/sq...r/outils/nagios for some notes
I've taken about how to do it.
Rudi Bruchez, MCDBA
http://www.babaluga.com/|||excellent! thanks
Rudi Bruchez wrote:
> bringmewater@.gmail.com a =E9crit:
>
> Hello,
> I've used Nagios for this purpose. You can have a look at
> http://www.babaluga.org/doku.php/sq...r/outils/nagios for some notes
> I've taken about how to do it.
>=20
> --=20
> Rudi Bruchez, MCDBA
> http://www.babaluga.com/
Monitoring server performance during nightly Analysis Services processing
Hello all,
We would like to get figures about the server performance when processing Analysis Services database. The processing takes place nightly. The prosessing is automatic and takes place outside of office hours. So there's nobody in the office who could monitor the server performance.
We'd like to know for example the following issues.
- memory usage in the server
- page file usage (reads / writes)
- CPU load (we have 4 processors)
- suitable data available of Analysis Server (don't know if there's any)
I know these are very high level requirements... What I have in mind is that we would have something similar to "CPU usage history" and "Page File Usage History" in Windows Task manager, but for a longer time period. I've tried to find a suitable tool for this, but I've had no luck and have found nothing. I know that many others must have had similar problems.
So, how to get the figures? Any suggestions would be highly respected.
r,
JM
One easy way to capture all this is to schedule performance logging on your server. All the counters you mention above are available as well as many that are specific to SSAS.
To set up a log, go to Computer Management and expand Performance Logs and Alerts. Right-click Counter Logs and select New Log Settings. Give the log a meaningful name, e.g. "SSAS Nightly Logging". Add the counters of interest, set the sampling rate and a file location/format, and schedule the logging for the period of interest.
Setting the sampling rate appropriately can be tricky. Try to push it to as high a duration as you can stand because there is overhead with each sample. Also, consider how you want to consume the output. In the past, I've dumped the data to flat file and set up a little data mart and ETL layer to present the data in a simple star-schema for slicing and dicing.
Bryan
|||Hello,
Thanks fot the advice, the idea really works.
We use now Performance Monitor to log the selected counter values to a file and later we use Performance Monitor to analyze the files. This approach is enough for our purposes now.
Seems that it's not possible to collect the performance data to a binary format log file and at the same time open the file for analysis in Performance Monitor. We have to stop the data collection first. I'm not totally sure about this. Logging and reading the log file simultaneously would be needed to make real time monitoring possible so that also history data would be available.
r,
J
|||There are a few ways you can address this. The simplest is to cap the size of the performance log files and have the logging start a new log once the max size is reached. You can then open and consume the old files closer real-time. However, it's still not real time.
Another way is to interface with WMI. This is a little tricky and will require some custom dev work. I believe this is how Microsoft Operations Management (MOM) works (which is another option for you).
Yet another good option is to open the perfmon utility, add the counters, and monitor these in real-time through there.
Hope that helps,
Bryan
Monitoring server performance during nightly Analysis Services processing
Hello all,
We would like to get figures about the server performance when processing Analysis Services database. The processing takes place nightly. The prosessing is automatic and takes place outside of office hours. So there's nobody in the office who could monitor the server performance.
We'd like to know for example the following issues.
- memory usage in the server
- page file usage (reads / writes)
- CPU load (we have 4 processors)
- suitable data available of Analysis Server (don't know if there's any)
I know these are very high level requirements... What I have in mind is that we would have something similar to "CPU usage history" and "Page File Usage History" in Windows Task manager, but for a longer time period. I've tried to find a suitable tool for this, but I've had no luck and have found nothing. I know that many others must have had similar problems.
So, how to get the figures? Any suggestions would be highly respected.
r,
JM
One easy way to capture all this is to schedule performance logging on your server. All the counters you mention above are available as well as many that are specific to SSAS.
To set up a log, go to Computer Management and expand Performance Logs and Alerts. Right-click Counter Logs and select New Log Settings. Give the log a meaningful name, e.g. "SSAS Nightly Logging". Add the counters of interest, set the sampling rate and a file location/format, and schedule the logging for the period of interest.
Setting the sampling rate appropriately can be tricky. Try to push it to as high a duration as you can stand because there is overhead with each sample. Also, consider how you want to consume the output. In the past, I've dumped the data to flat file and set up a little data mart and ETL layer to present the data in a simple star-schema for slicing and dicing.
Bryan
|||Hello,
Thanks fot the advice, the idea really works.
We use now Performance Monitor to log the selected counter values to a file and later we use Performance Monitor to analyze the files. This approach is enough for our purposes now.
Seems that it's not possible to collect the performance data to a binary format log file and at the same time open the file for analysis in Performance Monitor. We have to stop the data collection first. I'm not totally sure about this. Logging and reading the log file simultaneously would be needed to make real time monitoring possible so that also history data would be available.
r,
J
|||There are a few ways you can address this. The simplest is to cap the size of the performance log files and have the logging start a new log once the max size is reached. You can then open and consume the old files closer real-time. However, it's still not real time.
Another way is to interface with WMI. This is a little tricky and will require some custom dev work. I believe this is how Microsoft Operations Management (MOM) works (which is another option for you).
Yet another good option is to open the perfmon utility, add the counters, and monitor these in real-time through there.
Hope that helps,
Bryan
Wednesday, March 7, 2012
Monitor SQL Server status through Notification Services
Hello,
I am new to Notification Services. My question is can notification services be used to monitor the status of sql server 2005 (stopped/started) and databases (online/offline).
Thanks
I probably wouldn't use NS for this. Use the Microsoft Operations Manager with the SQL Server MOM pack. The MOM pack is available at http://www.microsoft.com/downloads/details.aspx?familyid=79F151C7-4D98-4C2B-BF72-EC2B4AE69191&displaylang=en.
Or, you can use SQL Trace and event notifications to receive notifications of SQL Server events. See the Montioring Events section of SQL Server Books Online for more information. See http://msdn2.microsoft.com/en-us/library/ms190378.aspx.
-Diane Larsen
SQL Server User Education
Saturday, February 25, 2012
Monitor Database up or down and email to DBA
HI,
I like to know what different tools and scripts different people are using to monitor their SQL 2005 Databases.
We need to monito two services they are up and running all the time.
MSSQLServer & SQLAgent
Currently we have 3 different sql 2005 server and each one have 4 databases, we like to monitor.
Thanks in advance
I hear good things about Quest's Spotlight and Idera's Diagnostic Manager, but haven't worked with either enough to be able to recommend them myself.
Ask in the tools group (http://groups.google.com/group/microsoft.public.sqlserver.tools) or the Tools forum (http://forums.microsoft.com/MSDN/ShowForum.aspx?ForumID=84&SiteID=1)
HTH...
Joe
Monday, February 20, 2012
Money field
I am using Sql Server reporting services 2000. I have a money field which should show postive or negative amount. I used the format as currency. But it shows as ($40.00) for negative amount(it is placing it in braces) and $40.00 for positive amount. How can I show -$40.00??
HI, Nissan:
You can use this expression instead: =FormatCurrency(Fields!UnitPrice.Value,,,False,)
If i misunderstand you about your question, please feel free to correct me and i will try to help you with more information.
I hope the above information will be helpful. If you have any issues or concerns, please let me know. It's my pleasure to be of assistance
|||
HI, Nissan:
We are marking this issue as "Answered". If you have any new findings or concerns, please feel free to unmark the issue.
Thank you for your understanding!
MOM Reporting Configuration Query?
MOM 2005 SP1 Frontend & DAS
MOM 2005 SP1 Frontend
MOM 2005 SP1 DB w/ SQL 2000 SP4
SQL Reporting Services 2000 w/ MOM 2005 SP1 Reporting Pack
Will applying SQL 2000 RS SP2 break MOM reporting?No it won't. Whilst the RTM MOM Reporting install complains if RS SP2 is
installed when you try and initially install MOM Reporting, if you apply SP2
after you have installed MOM Reporting it should be fine. I just tried this
and then added some new reports from a management pack and it worked fine.
The link below also has this quote that seems to confirm this
"With MOM 2005 Service Pack 1, you can use SQL 2000 Reporting Services SP2,
which is independent of service packs for SQL Server 2000."
http://www.microsoft.com/technet/prodtechnol/mom/mom2005/Library/1e823712-c25b-4107-941d-e078f3937f3e.mspx
--
HTH,
Jasper Smith (SQL Server MVP)
http://www.sqldbatips.com
<damian.yates@.gtsi.com> wrote in message
news:1140192996.396977.158350@.g14g2000cwa.googlegroups.com...
> My current environment is as follows:
> MOM 2005 SP1 Frontend & DAS
> MOM 2005 SP1 Frontend
> MOM 2005 SP1 DB w/ SQL 2000 SP4
> SQL Reporting Services 2000 w/ MOM 2005 SP1 Reporting Pack
>
> Will applying SQL 2000 RS SP2 break MOM reporting?
>
MOM Report Integration with Sharepoint Portal
I work for a partner, and we use MOM 2005 in a "managed services" scenario
to monitor client environments, and are attempting to develop client-facing
sites within Sharepoint portal to display various reports and alert information.
This effort spawned the following question:
What would be the best way to provide a MOM "State View" (green/yellow/red)
within a Sharepoint site. I cannot find the state data within the Onepoint
database (nor any reference in the MOMSDK), nor any existing SPS web part
to fit the bill.
Any pointer to where in the database this data lies or opinions on the best
way to address the challenge would be appreciated.
Thanks,
PetMOM 2005 comes with a range of Reporting Services reports, probably
including the one you want. With Reporting Services SP 2, there comes 2 web
parts for SharePoint, the Report Explorer and the Report Viewer. So what you
can do is to set up Reporting Services, and then install the two RS Web
parts to your SharePOint site, and point the reports you want to see. I
think you can use the Report Viewer to show just one report, so you don't
show everyone all the other MOM reports.
Kaisa M. Lindahl
"Pete Zerger" <pete.zerger@.nospam.gmail.com> wrote in message
news:7e9e9bb33a01d8c792709c6ecd86@.msnews.microsoft.com...
> All,
> I work for a partner, and we use MOM 2005 in a "managed services" scenario
> to monitor client environments, and are attempting to develop
> client-facing sites within Sharepoint portal to display various reports
> and alert information. This effort spawned the following question:
> What would be the best way to provide a MOM "State View"
> (green/yellow/red) within a Sharepoint site. I cannot find the state data
> within the Onepoint database (nor any reference in the MOMSDK), nor any
> existing SPS web part to fit the bill.
> Any pointer to where in the database this data lies or opinions on the
> best way to address the challenge would be appreciated.
>
> Thanks,
> Pete
>
MOM 2005 Reporting and Reporint Services SP1
"Jeremy" wrote:
> Does anyone know if MOM 2005 Reporting works on Reporting Services SP1.