Finally SQL Server 2016 Released on 1st June 2016

Yes, you saw correct news. SQL SERVER 2016 finally released on 1st June 2016. It is most awaited NEWS. You will find many surprising features in this Build.

Below are some upcoming features which you will see in this feature

  1. Temporal Table
  2. Stretch Database
  3. Row Level Security
  4. Poly Base
  5. Running Estimation Plan
  6. JSON Support
  7. Security Data Masking
  8. Always Encrypted

SQL_SERVER_2016_

And many more. We will discuss it soon on our blog

Mean while you can download SQL SERVER 2016 from link Download.

And to read more about this release you can check at  SQL Blog

Till than Enjoy.

Advertisements

How to automate web UI testing for smart developers ?

As a developer, I do agree that we have to do Unit testing of the code  and most of us write different unit test program and execute them but this is not enough at our end. It is a developer responsibility to test the application at his/her hand before deploying into the QA environment.

Now, It feels sometime boring to test same page again and again or check whole flow of application every time indeed it is time consuming as well. Here. In this series, We are going to see various different options by which we can ensure that everything which wrote earlier or the  previous functionalities are also working fine. As a developer this is our first and for most important to cross check our work and also make sure everything is working fine after our changes.

Here in this post I am sharing one simple smart step to test your website again and again by just one click. This requires only first time efforts.

So, the magical thing is “Selenium IDE“ which is a FireFox  Add-on. You can download and install from below URL

https://addons.mozilla.org/en-US/firefox/addon/selenium-ide/

Selenium_IDE

Once, you installed you will get the icon as shown below.

installedIDE

Now, when you click on this Selenium icon you will get following screen.

seleinum_ide_Indiandotnet_1

To make it simple to understand, we are using a simple example. Here in Base URL we are adding  http://NerdTechies.com  and clicking on Record button as shown in below figure

seleinum_ide_Indiandotnet_2

Once, you added base URL it means you are going to capture all the happening on this base URL.

Now open this URL in Firefox browser and once the site is open click on different links which you want to test whether that working or not? The selenium IDE capture all the events which you performing. Once your think you tested all the mandatory things again click on the record button to stop the test case.

Now once your capture everything you can save this test case.

seleinum_ide_Indiandotnet_3

Once you saved it. You can run this test case later on as well. Now, Here you are thinking that you have capture the test cases , saved test cases but, how to run the test case.

seleinum_ide_Indiandotnet_4

When you run test case by clicking the play button as shown above figure you will see that , whatever action you performed earlier will repeat again in browser. If everything worked according to your last action then test case is successful else test case will fail.

Now, This is the simplest way to cross check your monotonous work (test cases) again and again by just one click.

In near future we will share two more important tips

1) Selenium with .NET

2) Coded UI  a .NET project

I hope meanwhile you will enjoy this selenium IDE with Firefox. I am pretty much sure once you start using it you will save your time and do smart work.

Enjoy !!

RJ!!

Thanks for your support in 2014

Dear Friends,

Thanks for your support in 2014.

The WordPress.com stats helper monkeys prepared a 2014 annual report for our blog.

Here’s an excerpt:

The concert hall at the Sydney Opera House holds 2,700 people. This blog was viewed about 18,000 times in 2014. If it were a concert at Sydney Opera House, it would take about 7 sold-out performances for that many people to see it.

Click here to see the complete report.

New windows App from Indiandotnet in to increase peace, prosperity and success enjoy downloading it and share.

 

Dear All,

it give me immense pleasure to introduce that “Indiandotnet” release first version of  peace mantra “Ganesha Mantra”

This mantra help you in many ways.

I would like to thank many friends “SK”, “SV” who helped me in this idea and thanks all the other team member who helped me and provided feedback.

so why are you waiting enjoy by downloading  http://www.windowsphone.com/en-us/store/app/ganesha-mantra/6c8225fa-26f9-4cc5-ac20-09a67c9c851a

GaneshaMantra_Indiandotnet

So Just download and enjoy & share

Many more to come in this week.

Enjoy learning, enjoy sharing.

|| Shri Ganeshaye namah ||

 

Thanks

Indiandotnet Team

How to create RESTful WCF Service ?

 

Hello friends,

Many times you heard about RESTful services. I know most of you pretty much aware also but let me Introduce in my way.

The first question  come to your mind which is

What is REST?

So here is my answer it is Representational State Transfer.

Its all about using HTTP protocol.With the help of this you can perform various action like PUT,GET,POST,DELETE etc.

Suppose you have a student database and want to pull a particular roll number’s record. then in that case you will do following thing
http://indiandotnet.in/GetData/Name

Where 123 is roll number. So with simple URL you can fetch the information similar way you can edit,delete and create student record also with similar type of URL(may be few parameters vary depending on your requirement)

How to create a RESTFUL WCF services ?

Creating RESTFUL WCF service is not a typical part Lets understand it by Step by Step Example

So lets start a new project WCF project as shown in below image i have added one project

 REST_Solution_1

Step 2:-

Now  i am adding two methods here which are  basically for showing two different format XML & JASON using REST WCF application. The important point

definedTwomethod

Step 3:-

Now to make this method as a RESTful service we need to add WebGET attribute as  i am dealing with only Fetching and GET method. as shown in above image.  I am using WebGet but you can try different method like, POST,DELETE,PUT using Web Invoke attribute.

To make this simple to understand i am using Student class with only two property first name & Last Name

Student_Class

Step 4: Below are the two methods in which from one method  we are responding XML & from one method we are returning the JASON.

Method_Definition

Step5:

Once step 4 is done we will configure most the most important part of RESTFUL WCF application which is binding , contract  information etc.

Capture

Once the above configuration is done just run the service.

lets run it with fiddler to understand it more.

When we  running the URL with GETData method as shown it below

  http://localhost:51550/Service1.svc/GetData/Name 

running_1

When we run it we get xml Response as shown below

Rest_Response_XML_2

Now we are running other method using JASON method (as shown in below method)

We will get following response.

Response_XML_3

So in this way we can create RESTFul application.

You can download  code from

Thanks & Best Regards,

Rajat Jaiswal

How to Improve query by reducing CXPACKET WAIT type with simple option?

 

Dear All,

I am sure you have faced this problem that when you running query like Aggregation , grouping etc then due to default setting the query uses all the CPU available to machine and this case is parallelism.

Now you are thinking its very good your query will be faster if it distributed amount the multiple processor.

but sometime this is not the case due to this distribution suppose one process is processing slowly then  overall your combine result have to wait this wait is “CXPACKET WAIT”

Now you are wondering how to handle this. so no worries Microsoft provided option to tweak this setting with MAXDOP (Maximum degree of Parallelism ) option.

You can change overall SQL Server setting or for particular query.

see below screen from where you can change MAXDOP settings.

MAXDOP

Now the default value is “0” . It means can use all the CPU.

Now this is not we generally prefer instead of this we can use MAXDOP option in query option.

But before doing this you just need to cross check whether you require it or not ?

if your CXPACKET wait type  if too much then you can use this option

SELECT ISNULL(MAX(EnrollmentHistoryId),0) AS maxenrmollmentHistoryId ,     
           se.StudentId      
       FROM dbo.StudentEnrollment se WITH (NOLOCK)       
       INNER JOIN dbo.student s WITH (NOLOCK) ON s.studentId = sh.studentId       
                             AND s. YearId = @YearID
       WHERE sh.Statusid = @StatusActivateId 
       GROUP BY sh.StudentID
    OPTION (MAXDOP 1)

in the above query we used MAXDOP 1 which means query use only once CPU.

With this option the CXPACKET will reduce but it may be possible your query may take time so be careful.

But this is good option. It helped me to reduce the time.

Lets try if this can help you.

Enjoy  learning 🙂

Thanks & Best Regards,

Rajat Jaiswal

Utility for SQL server maintenance (Defragment Utility)

Dear Friends,

Database maintenance is one of the tedious task sometime if you are not well aware what to apply. So don’t worry now

Indiandotnet providing a simple utility which help you in analyzing the Indexes for  which need maintenance and for which we need to run some maintenance script.

So let me explain the utility first

when you run the utility you will get following screen.

Login_Screen

Now you need to fill SQL Server name username & password and click on login button. If the login is wrong then you will get error message else the database(s) name(s) which exists on that particular server is populated in just below drop which is select Database once you select the database for which you need to analyze the index defragment then click on analyze button.  After the button click you will find the result in below grid.

In the grid you will get index with name & table name with fragmentation details.

Indexes which  have fragmentation percentage  more then 35% shows in Red color. Indexes which have fragmentation higher then 5% and lower than 35% shows in Yellow color.

If the Row in Red color means you need to Rebuild the index and if it is in Yellow color then you need to Reorganize.

Once you select the rows  and click on Improve button then it will generate a script and you can run this directly on the server.

As the Index build  & reorganize depends on database size so you need to take care when you can run it.

You can download the application code from download.

Please feel free to give your feedback & comments.

Enjoy defragmentation 🙂

Thanks & Best Regards,

Rajat Jaiswal

LINQ with CheckBox List–LINQ Tips

Dear All,

There are many situation where you need to comma separated values of all the checked items of a checkbox list for this situation you generally write following  code

string allowedProductfamilies = string.Empty;
foreach (ListItem lItem in chkFamily.Items)
                {
                    if (lItem.Selected)
                    {
                        allowedProductfamilies += lItem.Value + ",";
                    }
                }

Now the above code is fine but can be improve more with following lines of code you can directly replace above lines with following lines of the code

string allowedProductfamilies = string.Empty;

allowedProductfamilies = chkFamily.Items.Cast<ListItem>().Where(lItem => lItem.Selected).Aggregate(allowedProductfamilies, (current, lItem) => current + (lItem.Value + ","));

 

I am sure you like the code.

Enjoy .Net , Enjoy LINQ .

Your Friend,

Rajat Jaiswal