Sql Server Profiler Free Tool - asp.net

I need A free Sql 2008 R2 Profiler As I Can not Use Sql Server Included Sql Profiler for some reasons. If there are any free profiling tools or something like this - it will be good

To run traces like SQL Server Profiler, even with AnjLab's replacement, you still need server-side permissions to run it.
In SQL Server 2000, you had to be a member of the sysadmin
In SQL Server 2005, you can GRANT ALTER TRACE to allow non-sysadmins to run either profiling tool

Learn about profiling background, Events, traces and Extended events and in your case you will not need a profiler, since you'll be able to do all there tricks by proper querying the sql server itself.
Take a look also on Dynamic Management Views and Functions
And finally there is one free tool available sqlexpressprofiler and also here is one more from Google code named AnjLab
Some solutions provided by Idera

Why can't you use the included one, does it error? I never found anything which came close to the included one apart from AnjLab Profiler. The only annoyance with it is you can't export traces for tuning.

Anjlab Sql Profiler was great, and still is if you can get your hands on the old free version.
Now there is Datawizard SQL Performance Profiler which has a free trial, but is commercial.

There is an open source SQL Profiler by AnjLab which I'm using regularly:
[AnjLab SQLProfiler][1]

Related

Windows Work Flow persistence database?

Few questions:
1. Is SQL server installation needed to run Windows Work Flow?
2. If yes, where does work flow stores (persists) data for a long running process
3. I see that some files are created in .\windows\Microsft.NET\Framework\v4.0\SQL\en\ (some sql scripts to create persistense points)
4. Do we need to run these scripts to manually create database?
5. Can we persist data on file system instead? so that we don't need to install SQL Server?
Thanks
I see one supposed answer already, but "read the docs" answers really aren't good answers, especially in an area so poorly documented as WF, so in case anyone else stumbles across this thread:
(1) SQL Server doesn't have to be installed just to use workflows, but if you want persistence for long running workflows, (2) SQL Server is your easiest way to get it.
(3) and (4) You can let AppFabric do most of the heavy lifting in setting up the persistence database for you.
(5) you could persist on a file system instead of SQL Server but IMHO, from what I've seen in my short time with WF and persistence so far, you'd be crazy to try to implement your own persistence provider like that, especially when just starting out. You can use SQL Server Express to get started. Why reinvent the wheel?

Should I consider migrating from SQL Server to Oracle for my ASP.NET applications?

We're upgrading our systems to support clustering and auto failover features. Our business runs .NET 4 applications, web apps and services on SQL Server Express. We can upgrade to SQL Server Standard, but the cost has motivated us to consider other options. Is it a legitimate option to integrate our .NET data layer with ODP.NET? After searching, I have seen a tendentious statement or two in the negative (viz) and yet it would seem that people are doing it anyway. What development features in the Visual Studio IDE will we lose? Thanks for your help!
Well, I'm now working since 20+ years with Oracle and MS SQL Server, having done a lot of projects. Some projects are running now more than 10 years, with all the updates, maintenance and so on.
My quick answer is: Stay with MS SQL Server. Go to Oracle only, if you have really GOOD TECHNICAL reason, or if you are planning really an ENORMOUS database, and if you have enough staff to handle all thge administration.
The main reason is that SQL Server is much easier to maintain; and it also integrates greatly into the Microsoft environment.
Oracle, in contrast, has a steep learning curve. The handling of Oracle is much more "manual" then MS SQL Server. Well, that's also a good thing, because you are in control of every small detail, but it also means that you need to learn a lot; or you need to pay experts. And it is not so easy to find people who really know what to do.
I really like both Systems, but for a rule of thumb, I normally suggest to use MS SQL Server.
I've been using .net with Oracle for years, and migrate away from it whenever the option is available.
If all your database code is in stored procs and you call it though the codebehind or a library and you use ansi sql your migration from ms sql to oracle will be fairly painless.
If you use TableAdapters, they re-write any sql you put in to the oldschool oracle 8 syntax like table1,table2,table3 then have a big where clause to do the join conditions. There's also some weird bugs where sometimes sql that runs fine over in SQL Developer won't work in the TableAdapters.
If you use Entity Framework migration should be pretty easy, but the MS SQL driver is much better then the Oracle one. There have been several queries I couldn't do though EF in oracle because of some of the various errors with the current driver.
If you need more info let me know.
Also if Cost is the main reason to consider migration, why not go with mysql?
Since you are already working in MS SQL, you must be habitual of the way it work, be it entity framework or any other data execution. Yes offcource, microsoft has very high license rates for it. But if you want to move to any other database, it is perfectly alright. I have personally used MS SQL and MySQL both. Initially you might face some syntax related issues, but do remember that logic remains the same for fetching and saving the data. Further it gives a benefit that you got to learn a new language and that too at the expense of far less money.

Is there any tool to see the queries run against the database?

Is there any tool that will inspect either asp.net or sql server and report all the queries that are run against the database? The reason I ask is I am using Linq for a project and want to double check what its actually doing for each page.
Ideally I'd like to view a page in a browser and have a report of all the queries that were run to create that page.
I know I can view the SQL it runs for individual queries using debugging/breakpoints, and I know about LinqPad, but I'm afraid Linq is making several more queries on its own to get related data that I may not be directly aware of. Is there anything (tool/program/report/etc) like what I described? Thanks!
EDIT: Is there any FREE tool that can do this? I am using Sql Server 2008 Express and don't have SQL Profiler unfortunately.
Absolutely, There is a SQL tool called SQL Profiler. It does require elevated database permissions in order to run profiler.
There is a decent tutorial on how to run Profiler on TechRepublic.
Another option out there is the NHibernate Profiler. I know that it is not as "free" as SQL Profiler, have never used it, but the screen shots for it look pretty cool.
Profiler is the best tool of them all for this but it can be expensive in inexperienced hands.
You can also try to do "exec sp_who" and then a "dbcc inputbuffer (111)" - just put the process id in the place of 111.
SQL Profiler does that.
Since you are using SQL Server Express, how about this tool?
Profiler for Microsoft SQL Server 2005/2008 Express Edition
Microsoft SQL Server family includes
free Express edition, that is fully
functional, however has some
disappointing limitations which
prevent from using it in development
process. One of them is absense of
profiling tools, standard SQL profiler
is not included. However, now you have
an ability to use express edition for
tuning your system. SQL Server Express
Edition Profiler provides the most of
functionality standard profiler does,
such as choosing events to profile,
setting filters, etc. By now there are
no analogue free tools.
Download Here
A quick and dirty way to log LINQ to SQL queries in ASP.NET is this (assuming a Northwind.Dbml):
NorthwindDataContext context = new NorthwindDataContext();
context.Log = Response.Output;
This will write all queries to the response stream. Nasty, but handy for instant gratification without need for debuggers or profilers etc.
For the LINQ to SQL queries specifically, you can also use the DataContext.Log property to output the queries to a TextWriter, so you can do things like write to debugger output window or (as in my use) to log4net.
These links might help:
Log to debugger output window, file, or memory
Log to log4net
Won't cover the stuff not generated by L2S, so this may not be the end all solution for you... but I've found it helpful.
This one is only free for the first 45 days, but it gives you runtime profiling/logging with a bunch of filter options, SQL Server query execution plan logging etc. Built specifically for profiling L2S apps:
http://www.huagati.com/L2SProfiler

Is there an open source web based management for MS SQL server?

Does anyone know of a web based MS SQL manager (in ASP.NET or classic ASP)? I'm getting sick of using their studio software, and use MySQL a lot too, so I'm used to the web based management. Thanks :)
Check out SQL Web Data Administrator, it's ASP.NET and sounds like it fits the bill. Not sure I'd ever let it exist outside a local network, but if you're running phpMyAdmin or the like then it's probably not much different.
(Also, spend a week using the real MySQL command-line client - you'll learn to love SQL SMS with all it's clicky draggy syntax-colored quirks.)
I do not know of any open source or free solutions for this, and honestly I'm going to doubt that you are going to find anything at that level that is going to do everything you need.
There is a commercial offering myLittleAdmin that works very well, but it is expensive.
I've been working on a Web based SQL Management Studio that works for the most part. Code at GitHub: https://github.com/sanin17/WebSQL or a demo at https://www.saninsoftware.com/WebSQL/Home/Start/

SqlServer Express slow performance

I am stress testing a .NET web application. I did this for 2 reasons: I wanted to see what performance was like under real world conditions and also to make sure we hadn't missed any problems during testing. We had 30 concurrent users in the application using it as they would during the normal course of their jobs. Most users had multiple windows of the application open.
10 Users: Not bad
20 Users: Slowing down
30 Users: Very, very slow but no timeouts
It was loaded on the production server. It is a virtual server with a 2.66G Hz Xeon processor and 2 GB of RAM. We are using Win2K3 SP2. We have .NET 1.1 and 2.0 loaded and are using SQLExpress SP1.
We rechecked the indexes on all of the tables afterword and they were all as they should be.
How can we improve our application's performance?
This is just something that I thought of, but check to see how much memory SQL Server is using when you have 20+ users - one of the limitations of the Express version is that it is limited to 1GB of RAM. So it might just be a simple matter of there not being enough memory available to to server due to the limitations of Express.
You may be running into concurrency issues, depending on how your application runs. Try performing your reads with the "nolock" keyword.
Try adding in table aliases for your columns (and avoid the use of SELECT *), this helps out MSSQL, as it doesn't have to "guess" which table the columns come from.
If you aren't already, move to SPROCs, this allows MSSQL to index your data better for a given query's normal result set.
Try following the execution plan of your SPROCS to ensure they are using the indexes you think they are.
Run a trace against your database to see what the incoming requests look like. You may notice a particular SPROC is being run over and over: generally a good sign to cache the responses on the client if possible. (lookup lists, etc.)
Update: Looks like SQL Server express is not the problem as they were using the same product in previous version of the application. I think your next step is in identifying the bottlenecks. If you are sure it is in the database layer, I would recommend taking a profiler trace and bringing down the execution time of the most expensive queries.
This is another link I use for collecting statistics from SQL Server Dynamic Management Views (DMVs) and related Dynamic Management Functions (DMFs). Not sure if we can use in the Express edition.
Uncover Hidden Data to Optimize Application Performance.
Are you using SQL Server Express for a web app? As far as I know, it has some limitations for production deployment.
SQL Server Express is free and can be redistributed by ISV's (subject to agreement). SQL Server Express is ideal for learning and building desktop and small server applications. This edition is the best choice for independent software vendors, non-professional developers, and hobbyists building client applications. If you need more advanced database features, SQL Server Express can be seamlessly upgraded to more sophisticated versions of SQL Server.
I would check disk performance on the virtual server. If that's one of the issues, I would recommend putting the database on a separate spindle.
Update: Move to separate spindle or Upgrade SQL Server version as Gulzar aptly suggests.
make sure you close connections after retrieving data.
Run SQL Profiler to see the queries sent to the database. Look for queries that are:
returning too much data
constructed poorly
are being executed too many times

Resources