How to check Azure SQL firewall rues with TSQL
In the master database of the Azure SQL server. select * from sys.firewall_rules
How to find DOS Short Name for Windows directories or files
To find out the DOS short names assigned for Windows files or directories:
How to download historical stock data using Python and yfinance
yfinance is a Python package you can use to download free stock market data from Yahoo! Finance. Full detail and reference here. https://pypi.org/project/yfinance/ {‘zip’: ‘95014’, ‘sector’: ‘Technology’, ‘fullTimeEmployees’: 147000, ‘longBusinessSummary’: ‘Apple Inc. designs, manufactures, and markets smartphones, personal computers, tablets, wearables, and accessories worldwide. It also sells various related services. The company offers iPhone, a […]
How to download web pages rendered by JavaScript
For Web pages that the final contents are rendered by JavaScript, using requests will not be able to get the final web page. This is a code snip using Selenium to do the job.
How to restore a Azure SQL DB to a new server
From the target server, select “Create database.” 2. Fill in the configuration values. Then go “Next Networking” or just go to tab “Additional Settings”. 3. Set “Use existing data” to “Backup” and select a backup from your existing database backups.
How to check user permissions on DB objects
How to check SQL server DB role membership
This is the TSQL to check the membership of a db role in MS SQL Server
How to set SQL Server from “Windows Authentication mode” to “SQL Server and Windows Authentication mode”
Right click on the server name and select properties; Select security tab; Enable the SQL Server and Windows Authentication mode; Restart the SQL Server service.
How to send email via Office 365 in Python
Pyhton 3. Complete info: https://www.aventistech.com/2016/03/07/python-send-email-via-office-365-tls/