Tuesday, July 21, 2020

How to solve ASP.NET MVC Exception: Timeout expired. The timeout period elapsed prior to completion of the operation or the server is not responding. The statement has been terminated

ASP.NET MVC can give this error probably when you have a long running query. It can happen when:
1. You are running query on a very large dataset
2. Your query is complex and inefficient
3. Database statistics and/or query plan cache are incorrect
4. You are in deadlock

You should be able to find out the specific problem you are facing from stack trace.

Solutions:

Step 1:
If your query needs more than the default 30 seconds, you might want to set the CommandTimeout higher. To do that you'll change it after you instantiated the DataAdapter on the SelectCommand property of that instance, like so:

        protected DataTable GetDataTable(string Query, CommandType cmdType, params SqlParameter[] parameters)
        {
            string strCon = DataContext.Database.Connection.ConnectionString;
            DataTable dt = new DataTable();
            using (SqlConnection con = new SqlConnection(strCon))
            {
                using (SqlCommand cmd = new SqlCommand(Query, con))
                {
                    cmd.CommandType = cmdType;
                    cmd.Parameters.AddRange(parameters);
                    using (SqlDataAdapter da = new SqlDataAdapter(cmd))
                    {
                        da.SelectCommand.CommandTimeout = 60 * 10;
                        da.Fill(dt);
                    }
                }
            }
            return dt;
        }


Step 2:
To reduce query complexity you need to apply different efficient methods to rewrite query as there is no specific method for improving query performance. You can apply indexing if you have large datasets. DBCC command is helpful to re-index and rebuild indexes which can also improve if you have large datasets.
DBCC DBREINDEX ('HumanResources.Employee', ' '); 


Step 3:

Improve database table query plan statiscs for all tables and index with a single command:

exec sp_updatestats

If that doesn't work you could also try

dbcc freeproccache

Hope this can be helpful.

Wednesday, June 24, 2020

Introduction to Continuous Integration and Continuous Delivery

Software Development Life Cycle


Software development follows a flow, starting with identifying new features, planning, doing the actual development, committing the source code changes, running builds and tests (unit, integration, functional, acceptance, etc.), and deploying to production.

With a traditional waterfall software delivery approach, developers could work independently for a very long time. They would not have a clue about how many issues they would run into during the integration phase.

In order to address this issue, the Agile software development model was introduced. Agile changed the way software development teams worked. One of the key principles of this methodology was delivering working software frequently. The focus moved to releasing incremental software, rather than big bang waterfall releases which took months and years.

Delivering software frequently meant producing stable code for every incremental release. It was quite a challenge to integrate changes from various developers on the teams. This led to software teams looking for better approaches. Continuous Integration (CI) offered a ray of hope and started to gain in popularity.


Continuous Integration (CI)


Continuous Integration is an agile engineering practice originating from the extreme programming methodology. It primarily focuses on automated build and test for every change committed to the version control system by the developers.



In order to implement Continuous Integration, you will need:

      • A version control system
        It stores all the source code checked in by the teams, and acts as the single source of truth.
      • Automated build and unit test
        It is not sufficient if the code written by a developer works only on his/her machine. Every commit that makes it to the version control system should be built and tested by an independent continuous integration server.
      • Feedback
        Developers should get feedback on their commits. Anytime a developer’s change breaks the build, they can take the necessary action (example: email notifications).
      • Agreement on ways of working
        It is important that everyone on the team follows the practice of checking-in incremental changes rather than waiting till they are fully developed. Their priority should be to fix any build issues that may arise with the checked-in code.

Continuous Delivery


Continuous Delivery is a logical extension of Continuous Integration. While Continuous Integration lets you automate the software build and test process, Continuous Delivery automates the full application delivery process by taking any change in code (new features, bug fixes, etc.) all the way from development (code commit) to deployment (to environments such as staging and production). It ensures that you are able to release new changes to your customers quickly in a reliable and repeatable manner.


Incorporating Continuous Delivery practices will make your overall release process painless, reduce the time to market for new features, and increase the overall quality of software thereby leading to greater customer satisfaction. It can also significantly reduce your software development costs as your teams will prioritize releasing new features over debugging defects.


Continuous Deployment


Oftentimes, the terms Continuous Delivery and Continuous Deployment are used synchronously by many, but in reality these concepts have a different meaning.

While Continuous Delivery gives you the capability to deploy to production frequently, it does not necessarily mean that you are automating the deployment. You may need manual approval prior to deploying to production, or your business may not want to deploy frequently.

Continuous Deployment, however, is an automated way of deploying your releases to production. You need to be doing continuous delivery in order to be able to perform automated deployment. Companies like Netflix, Amazon, Google, and Facebook automatically deploy to production multiple times a day.


Deployment Pipelines



Deployment pipelines (or Continuous Delivery pipelines) are the cornerstone of Continuous Delivery as they automate all the stages (build, test, release, etc.) of your software delivery process.

There are numerous benefits to using Continuous Deployment pipelines. An automated pipeline allows all stakeholders to monitor the progress, eliminates the overhead of all the manual work, provides quick feedback, and more importantly builds confidence on the code quality.


The deployment pipeline run starts with a developer committing source code change into a version control repository. The CI server detects the new commit, compiles the code, and runs unit tests. The next stage is deploying the artifacts (files generated from a build) to staging or a feature test environment where you run additional functional, regression, and acceptance tests. Once all the tests are successful, you are ready to deploy into production. In case of failure during any stage, the workflow stops and an immediate feedback is sent back to the developer.



Tools for Deployment Pipeline



In order to automate the various stages of your deployment pipeline, you will need multiple tools. For example:

      • a version control system such as Git to store your source code
      • a Continuous Integration (CI) tool such as Jenkins to run automated builds
      • test frameworks such as xUnit, Selenium, etc., to run various test suites
      • a binary repository such as Artifactory to store build artifacts
      • configuration management tools such as Ansible
      • a single dashboard to make the progress visible to everyone
      • frequent feedback in the form of emails, or Slack notifications.

And that’s not all. You will also need a single tool that can bring all these tools together to achieve CI/CD goals which is to automate software delivery.


Saturday, May 30, 2020

How to make a google map from excel, customize map view and share with p...







Here I show how to make a google map from excel file. Google map allows you to create custom map by uploading location data from excel or other format. You can customize base map view, share with people, embed to website or print to pdf.



The video of creating a google map from excel data file not only shows how to create a google map but also discuss on following google map features:

1. Importing excel data to map

2. Applying style to placemarker

 3. Applying label to placemarker

4. Apply base map

5. Display Map Preview

6. Sharing options

7. Adding a new place marker

 8. Routing line drawing between places

9. Direction between places

10. Distance measurement between places

11. How to print map

12. How to embed to website

13. Create new map using existing map



Please watch till the end of the video, I hope you will enjoy it.

If you have enjoy the video, please go ahead and like it.

Write us in comment how helpful this video for you. If you think this might be helpful for your friends, Please share the video with your friends.

If you have any question, regarding the video, Please write us through comments.

Please join in our community through subscription of channel and subscription of video notification.



In triksbuddy channel, you will get different interesting tech stuffs that will help you enrich your technology knowledge. Please subscribe our channel to get updates of our videos. Subscription link: https://goo.gl/GE4g8v



 Please subscribe in below link and like our video.

Subscription URL: https://goo.gl/GE4g8v

Channel URL: https://goo.gl/VYi58K

Most Recent Videos: https://goo.gl/hXFN4w

Most Popular Video: https://goo.gl/7u7B1x



Social:

Facebook: https://www.facebook.com/triksbuddy/

Linked in: https://www.linkedin.com/company/trik...

Blog: https://triksbuddy.blogspot.com/

Tumblr: https://imrulquaes89.tumblr.com/

RSS Feed: https://www.youtube.com/feeds/videos....



 Referral links that will not charge you but help me earning commissions:
Buy tubebuddy for your channel: https://bit.ly/2HP5lJR

Sunday, April 5, 2020

How To Schedule And Join A Zoom Meeting in Two Minutes







Learn how To Schedule And Join A Zoom Meeting with your free account in Two Minutes. In this video tutorial, I show you how to set up,  schedule and invite people to a zoom meeting, and how host and initiate a zoom meeting. You can host user conferences, executive briefing centers, customer and prospect events, webinars, or training sessions virtually over Zoom.

Zoom is the leader in modern enterprise video communications, with an easy, reliable cloud platform for video and audio conferencing, chat, and webinars. Zoom is a great video conferencing platform that allows you to schedule and hold video conference meetings with your team.

Zoom is removing the 40 min time limit on our Basic free account for K-12 schools affected by the COVID-19 Corona virus.

During corona virus situation, adapt to remote working, stay connected and productive in a remote work environment with the use of zoom.





Please watch till the end of the video, I hope you will enjoy it.

If you have enjoy the video, please go ahead and like it.

Write us in comment how helpful this video for you. If you think this
might be helpful for your friends, Please share the video with your
friends.

If you have any question, regarding the video, Please write us through
comments.



Please join in our community through subscription of channel and
subscription of video notification.

In triksbuddy channel, you will get different interesting tech stuffs
that will help you enrich your technology knowledge.



Please subscribe
our channel to get updates of our videos.

Subscription link:
https://goo.gl/GE4g8v



Please subscribe in below link and like our video.

Subscription URL: https://goo.gl/GE4g8v

Channel URL: https://goo.gl/VYi58K

Most Recent Videos: https://goo.gl/hXFN4w

Most Popular Video: https://goo.gl/7u7B1x

Social:
Facebook: https://www.facebook.com/triksbuddy/

Linked in: https://www.linkedin.com/company/triksbuddy/

Blog: https://triksbuddy.blogspot.com/

Tumblr: https://www.tumblr.com/blog/imrulquaes89

RSS Feed:
https://www.youtube.com/feeds/videos.xml?channel_id=UCKFouta2JOolZmAmHeo3ZKw

Thursday, March 12, 2020

How to get random rows in SQL? SQL Query to get Random data. Top N Random Records.

There are a number of ways to get Random data from database. Following are some examples that works without any extra algorithm:

SQL Server:

SELECT TOP 20 *
FROM table_name
ORDER BY NEWID()

MySQL:

SELECT *
FROM table_name
ORDER BY RAND()
LIMIT 20



PostgreSQL:

SELECT *
FROM table_name
ORDER BY RANDOM()
LIMIT 20

Oracle:

SELECT *  FROM
( SELECT *
FROM table_name
ORDER BY dbms_random.value )
WHERE rownum <= 20











Thursday, March 5, 2020

Indonesia Public Holidays 2020


  Indonesia Public Holidays 2020

Following table contains a national calendar of all 2020 public holidays for Indonesia which is subject to change on official decision by the government of Indonesia.

DateDayHoliday
1 JanuaryWednesdayNew Year's Day
25 JanuarySaturdayChinese New Year
22 MarchSundayIsra Mi'raj
25 MarchWednesdayBali Hindu New Year
10 AprilFridayGood Friday
1 MayFridayLabour Day
7 MayThursdayWaisak Day
21 MayThursdayAscension Day of Jesus Christ
22 MayFridayLebaran Holiday
24 May to 25 MaySunday to MondayHari Raya Idul Fitri
26 May to 27 MayTuesday to WednesdayLebaran Holiday
1 JuneMondayPancasila Day
31 JulyFridayIdul Adha
17 AuguestMondayIndependence Day
20 AuguestThursdayIslamic New Year
29 OctoberThursdayProphet Muhammad's Birthday
24 DecemberThursdayChristmas Holiday
25 DecemberFridayChristmas Day


Wednesday, March 4, 2020

Thailand Public Holidays 2020

  Thailand Public Holidays 2020

Following table contains a national calendar of all 2020 public holidays for Thailand which is subject to change on official decision by the government of Thailand.

Date Day Holiday
1 January Wednesday New Year's Day
25 January Saturday Chinese New Year
8 FebruarySaturdayMakha Bucha Day
10 FebruaryMondayMakha Bucha Holiday
6 AprilMondayChakri Day
13 April to 16 AprilMonday to ThursdaySongkran Festival
1 MayFridayLabour Day
4 MayMondayCoronation of King Vajiralongkorn
6 MayWednesdayVisakha Bucha Day
11 MayMondayRoyal Ploughing Ceremony
24 MaySundayEnd of Ramadan
3 JuneWednesdayQueen Suthida's Birthday
5 JulySundayAsahna Bucha Day
6 JulyMondayKhao Phansa Day
6 JulyMondayAsahna Bucha Day Holiday
7 JulyTuesdayKhao Phansa Holiday
28 JulyTuesdayKing Vajiralongkorn's Birthday
12 AugustWednesdayHer Majesty the Queen Mother's Birthday
13 OctoberTuesdayPassing of His Majesty the Late King
23 OctoberFridayChulalongkorn Memorial Day
5 DecemberSaturdayHis Majesty the Late King's Birthday
7 DecemberMondayHis Majesty the Late King's Birthday Holiday
10 DecemberThursdayConstitution Day
25 DecemberFridayChristmas Day
31 December Thursday New Year's Eve


Google Sheet Tutorial Basic Mathematical Functions & Formulas





Google Sheet Tutorial Basic Mathematical Functions and Formulas. Google Sheets is an online spreadsheet app that lets you create and format spreadsheets and work with other people. With Google Sheets, everyone can work together in the same spreadsheet at the same time. Use formulas, functions, and formatting options to save time and simplify common spreadsheet tasks. Google sheet is alternative to Microsoft Excel and have some facilities over Microsoft excel.


Referral links that will not charge you but help me earning commissions. Buy tubebuddy channel booster plugin for your channel: https://bit.ly/2HP5lJR

Please watch till the end of the video, I hope you will enjoy it. If you have enjoy the video, please go ahead and like it. Write us in comment how helpful this video for you. If you think this might be helpful for your friends, Please share the video with your friends.

If you have any question, regarding the video, Please write us through comments. Please join in our community through subscription of channel and subscription of video notification.

In triksbuddy channel, you will get different interesting tech stuffs that will help you enrich your technology knowledge. Please subscribe our channel to get updates of our videos. Subscription link: https://goo.gl/GE4g8v



Please subscribe in below link and like our video.

Subscription URL: https://goo.gl/GE4g8v

Channel URL: https://goo.gl/VYi58K

Most Recent Videos: https://goo.gl/hXFN4w

Most Popular Video: https://goo.gl/7u7B1x


Social:

Facebook: https://www.facebook.com/triksbuddy/

Linked in: https://www.linkedin.com/company/triksbuddy/

Blog: https://triksbuddy.blogspot.com/

Tumblr: https://imrulquaes89.tumblr.com/

RSS Feed:
https://www.youtube.com/feeds/videos.xml?channel_id=UCKFouta2JOolZmAmHeo3ZKw



 #GoogleSheetTutorial, #triksbuddy

How to Draw Usecase Diagram using Draw.io







Learn How to Draw Usecase Diagram using Draw.io. This video shows you how easily you can draw usecase uml diagram using www.Draw.io. 

Use cases are a way of describing interactions between users and a system using a graphical model and structured text. They were first introduced in the Objectory method and have now become a fundamental feature of the Unified Modeling Language (UML). In their simplest form, a use case identifies the actors involved in an interaction and names the type of interaction. You then add additional information describing the interaction with the system. The additional information may be a textual description or one or more graphical models such as the UML sequence or state charts.

Use cases identify the individual interactions between the system and its users or other systems. Each use case should be documented with a textual description. These can then be linked to other models in the UML that will develop the scenario in more detail.

There are many tools available in the market for drawing use case diagrams. Visio is one of the most popular tool from microsoft which is not free for use. As an alternative of visio, draw.io is a great tool that allows you free access along with free storage and integration with other cloud applications like google drive, dropbox etc for storing you drawings.

 
 
If you have enjoy the video and get it interesting, please hit like button.

Write us in comment how helpful this video for you. If you think this might be helpful for your friends, Please share the video with your friends.

If you have any question, regarding the video, Please write us through comments.

Please join in our community through subscription of channel and subscription of video notification. 
 
In triksbuddy channel, you will get different interesting tech stuffs that will help you enrich your technology knowledge. Please subscribe our channel to get updates of our videos. 
Subscription link: https://goo.gl/GE4g8v 
Please subscribe in below link and like our video. 
Subscription URL: https://goo.gl/GE4g8v 
Channel URL: https://goo.gl/VYi58K 
Most Recent Videos: https://goo.gl/hXFN4w 
Most Popular Video: https://goo.gl/7u7B1x 
Social:
Facebook: https://www.facebook.com/triksbuddy/ 
Linked in: https://www.linkedin.com/company/triksbuddy/ 
Blog: https://triksbuddy.blogspot.com/ 
Tumblr: https://www.tumblr.com/blog/imrulquaes89 
RSS Feed: https://www.youtube.com/feeds/videos.xml?channel_id=UCKFouta2JOolZmAmHeo3ZKw
 

Creating a Meeting in GSuite Google Calender - triksbuddy







This video will shows way of creating a meeting in GSuite Google
Calender. Google GSuite allows you to create a meeting call easily using
google calender. The application allows you to setup meeting
notification which will be shown to the participants before the given
period of time before the meeting. GSuite allows you to setup available
meeting rooms of your organization. You can invite internal and external
guest.