Where And Having Clause Difference in SQL


  • Having is used only with the SELECT statement but WHERE clause can be used with Select, Update and Delete statement.
  • Having Clause is used to filter group while WHERE clause is used to filter rows.
  • WHERE clause is used to fetch particular records and this clause is applied after select statement but having clause is used for combination of group by functions.
  • Having clause is typically used in GROUP BY clause, without using GROUP BY function  you can not write the having clause.
  • Having clause works only to columns that also appear in the Group by clause or in an aggregate function.
  • Where clause is applied prior the grouping of data, while having clause is specified after grouping the result of the data.

How to access Dynamics CRM filtered views using a SQL account

  1. Create SQL Account
  2. Add CRMReaderRole role to the account where the organization database to access
  3. Get the GUID for the Dynamics CRM user you would like to impersonate.
  4. Use the Transact-SQL SET CONTEXT_INFO to set the context information to this GUID before querying the filtered view.
    DECLARE  @uid uniqueidentifier
    SET @uid = convert(uniqueidentifier, 'user_guid')
    SET CONTEXT_INFO @uid

    SELECT  *  FROM [FilteredLead]
  5. The query will return the records as if you were connected using the given user's Windows account.  It should be noted that the SET CONTEXT_INFO is only required when establishing the connection, and once set will remain so for the duration of the session



Source: crmland

Software as a Service (or SaaS)

  • software deployed as a hosted service and accessed over the Internet
  • E-Mail is the best example for SaaS (GMail, Yahoo...)

SOA or Service-Oriented Architecture

  • Service-Oriented Architecture (SOA) is a set of principles and methodologies for designing and developing software in the form of interoperable services. 
  • These services are well-defined business functionalities that are built as software components that can be reused for different purposes.
  • XML is commonly used for interfacing with SOA services
  • SOA enables the development of applications that are built by combining loosely coupled and interoperable services

Class member visibility notations in UML

To specify the visibility of a class member (i.e., any attribute or method) there are the following notations that must be placed before the member's name
  • + : Public
  • - : Private
  • # : Protected
  • ___ : Static
  • / : Derived
  • ~ : Package