Technical

Differences between SQL and NoSQL

1.Language SQL databases: SQL databases use structured query language (SQL) for defining and manipulating data. This is extremely powerful: SQL is one of the most many-sided and widely-used options available, making it a safe choice and especially great for complex queries. But it can be restrictive. SQL requires that you use predefined schemas to determine the structure of...

Exception Handling in Angular 10

I am using Angular 10 and when I click to open Persons page I get “Nulljector error” and redirect me to the home page . NullInjectorError: No provider for PersonServiceProxy! <a ng-reflect-router-link="/app/main/phonebook" href="/app/main/phonebook">phonebook </a> The solution : Add your ServiceProxy to providers in "\angular\src\shared\service-proxies\service-proxy.module.ts". Open service-proxy.module.ts fileIn @NgModule > providers > Add this Line “ApiServiceProxies.PersonServiceProxy” like this

How to migrate a domain without losing your SEO

1. Map All Old Domain URLs To Their New Domain Versions  This basically required mapping all of the dynamic and static old domain URLs to new domain URLs so they could all be 301 redirected at launch. 2. Understand How Any UI Changes Might Affect SEO  Changing UI while changing domains should be avoided whenever possible to...

How to execute a T-SQL command to every table in SQL Server database

sp_MSforeachtable is a stored procedure that is mostly used to apply a T-SQL command to every table, iteratively, that exists in the current database. Examples on how to use it: 1-Perform an unconditional reindex over all tables in the database: EXEC sp_MSforeachtable 'DBCC DBREINDEX(''?'')' 2-Truncate all tables in the database: EXEC sp_MSforeachtable 'TRUNCATE TABLE ?' 3-Get the information about the...

10 deadly sins of programming

Here are a few deadly sins that you should avoid while programming, they are not in a particular order: Assuming your code works.Code before you think.Coding without using a version control system.No code comments.No exception handling.Not using meaningful names for variables, methods, classes, etc.Overengineering.Overuse of inheritance and overriding.Reinventing the wheel.Untraceable Changes. If you have other sins,...

How to format DateTime in SQL Server

When expression is a date or time data type, style can be one of the values shown in the below Text: 101 >>>>>>>> mm/dd/yy102 >>>>>>>> yy.mm.dd103 >>>>>>>> dd/mm/yy104 >>>>>>>> dd.mm.yy111 >>>>>>>> yy/mm/dd114 >>>>>>>> hh:mi:ss:mmm(24h) we will assume that we have a table contain a DateTime data type field, the result of the below query will be...

Get geo location data using HTML5 & JavaScript

In case you are using Google Chrome you will have to enable getting location by the following steps: Open Google Chrome > on the top right click on the vertical 3 dots then select SettingsAt the bottom click Show advanced settingsIn the "Privacy" section, click Content settingsIn the dialog that appears, scroll down to the...

Subdomain Mapping in ASP.NET Boilerplate

In AbpTenants table in the database. You can add your custom properties to Tenant class.AbpTenant class defines some basic properties, the most important properties are: TenancyName: This is a unique name of a tenant in the application. It should not be changed normally. It can be used to allocate subdomains to tenants like 'mytenant.mydomain.com'. Tenant.TenancyNameRegex constant defines the...