Sunday, September 25, 2011

Asp.net Error: Sys.WebForms.PageRequestManagerServerErrorException: An unknown error occurred while processing the request on the server. The status code returned from the server was: 500

PROBLEM:
You are developing web site using ASP.NET. You get the flowing error when running your site "Asp.net Error: Sys.WebForms.PageRequestManagerServerErrorException: An unknown error occurred while processing the request on the server. The status code returned from the server was: 500"

SOLUTION:
Remove the characters '<' or '>' from your controls bound data


If you find this solution useful, you are welcome to press one of the ads in this page.. Thanks!


Wednesday, September 14, 2011

Why nHibernate?

PROBLEM:
You have a solid object model, with relationships between objects that are 1:1, 1:m, and m:n, don't have stored procedures, and likes dynamic SQL

SOLUTION:
Working with object-oriented software and a relational database can be cumbersome and time consuming. Hibernate is an Object/Relational Mapping tool for Java and .NET environments. The term Object/Relational Mapping (ORM) refers to the technique of mapping a data representation from an object model to a relational data model with a SQL-based schema.

Hibernate not only takes care of the mapping from Java/.NET classes to database tables (and from Java/.NET data types to SQL data types), but also provides data query and retrieval facilities. It can also significantly reduce development time otherwise spent with manual data handling in SQL and JDBC/ADO.NET

Hibernate's goal is to relieve the developer from 95 percent of common data persistence related programming tasks.

Hibernate may not be the best solution for data-centric applications that only use stored-procedures to implement the business logic in the database, it is most useful with object-oriented domain models and business logic in the Java/.NET-based middle-tier. However, Hibernate can certainly help you to remove or encapsulate vendor-specific SQL code and will help with the common task of result set translation from a tabular representation to a graph of objects.


Hibernate.org

What are the advantages and disadvantages of using an ORM?
http://stackoverflow.com/questions/398134/what-are-the-advantages-of-using-an-orm

ORM Hate?
http://martinfowler.com/bliki/OrmHate.html

If you find this solution useful, you are welcome to press one of the ads in this page.. Thanks!




Sunday, July 17, 2011

Using xp_cmdshell for backup xcopy gives "Invalid drive specification"

PROBLEM:
When I do this, I get an error back that says "Invalid drive specification" so I verified that both UNC Paths were correct by copying and pasting each one into a Run window and each opened up the correct directory.
I typed out the xcopy command in a command prompt on my machine without ANY changes and the command executed fine.

SOLUTION:
SQL is executing the command shell under the account that the SQL service was started under. The SQL server service is running under a local account, not a domain account. Thus it can't see the domain thus it can't find the path you’re looking for. Check what account the service is running under.


If you find this solution useful, you are welcome to press one of the ads in this page.. Thanks!


Thursday, July 7, 2011

Incorrect syntax near “GO”

PROBLEM:
SQL Execution resulted in following Exceptions: System.Data.SqlClient.SqlException: Incorrect syntax near 'GO'. at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()

SOLUTION:
1. Put the “GO” command on a new line, separate from the other statement
2. .SqlDataProvider file wasn't encoded in UTF-8 properly. Do save-as, then save file type with encoding UTF-8
3. Check issues with '+' and '-' signs in CREATE PROCEDURE scripts
4. Put an EOF char after the last “GO”


If you find this solution useful, you are welcome to press one of the ads in this page.. Thanks!


Wednesday, July 6, 2011

Shrink my database?

PROBLEM:
Why do I need to shrink my database?

SOLUTION:
Consider the following information when you plan to shrink a database:
  1. A shrink operation is most effective after an operation that creates lots of unused space, such as a truncate table or a drop table operation. 
  2. Most databases require some free space to be available for regular day-to-day operations. If you shrink a database repeatedly and notice that the database size grows again, this indicates that the space that was shrunk is required for regular operations. In these cases, repeatedly shrinking the database is a wasted operation. 
  3. A shrink operation does not preserve the fragmentation state of indexes in the database, and generally increases fragmentation to a degree. This is another reason not to repeatedly shrink the database. 
  4. Unless you have a specific requirement, do not set the AUTO_SHRINK database option to ON.
If you find this solution useful, you are welcome to press one of the ads in this page.. Thanks!

Team Foundation services are not available. Fatal error while initializing web service

PROBLEM:
You get the following errors using Visual Studio Team Explorer when trying to connect TFS
  • TF31001: Team Foundation cannot retrieve the list of team projects from Team Foundation Server servername. The Team Foundation Server returned the following error: Team Foundation services are not available from the server. 
  • TF30059: Fatal error while initializing web service. 

SOLUTION:
Check if your TFS database and IIS services are OK (up and running..)

If you find this solution useful, you are welcome to press one of the ads in this page.. Thanks!



Thursday, June 30, 2011

SCRUM Wedding

PROBLEM:
You plan a wedding

SOLUTION:
You can use the following instruction guide
http://gregoryheller.com/blog/2010-12/video-scrum-wedding-planning-ignite-talk


If you find this solution useful, you are welcome to press one of the ads in this page.. Thanks!