Showing posts with label python. Show all posts
Showing posts with label python. Show all posts

Monday, 7 September 2020

Add Python(or Java or anything) to Environment variables

After installation of python in windows 10, python is not added to environment variable by default. If you want to use cmd for python, then python installed path must be configured in the environment variable. 

When you type python in cmd, you'll see the below message:

Follow the below steps to add python to environment:
1) Open System in Control panel
2) Click Advanced system settings
3)Click Environment Variables
4) Select Path in User Variables and click edit
5) Either create new and type in the path of Python installed location or Browse the folder using browse button in the above screenshot.

6) Click OK and close the Environment variables settings window and all other opened windows. 
7) Start a new command prompt and type python to test. 









Done!



How to find first weekday in the month in MSSQL

declare @n datetime = dateadd(mm,0,getDate())    declare @FirstWeekDayOfMonth int    SELECT @FirstWeekDayOfMonth= CASE          WHEN Dat...