C# – LINQ Enumerable Methods Link to Microsoft Docs: Here Aggregate – Iterates over the elements in a sequence and aggregates them using the specified aggregate function. – Aggregate function takes in 2 arguments: seed and function Sample Code All – Whether all elements in the collection match a certain predicate – Returns Boolean result […]
C# – Framework Design Guidelines
BEST PRACTICE Returns 1. NULL Returns – When returning a collection or enumerable ALWAYS return an empty enumerable/collection String 1. String Concatenation – Use StringBuilder instead of String concatenation – string concatenation creates new memory allocation for new string – stringBuilder uses the same memory 2. Always use string.IsNullOrEmpty() and string.IsNullOrWhiteSpace() whenever possible LINQ 1. […]
Sago
Sago Names: Sago, sago palm, sago pearls Hindi: Sabudana What is Sago? Sago is produced from sago palm, it is the starch extracted from the center of sago palm stems, then processed into small, circular pellets referred to as pearls. For Vegan: – Good source of protein. Glycemic Index – High GI food: recommended to […]
Lifestyle 01: Glycemic Index
Lifestyle 01: Glycemic Index So I am beginning my first article with Glycemic Index, I was not aware with this term before but now I have enough information to share. What is Glycemic Index? Glycemic Index measures the carbohydrate-rich foods by the amount they elevate blood glucose levels compared to a standard food. Glycemic index […]
Web Development Resource
Web Development Resource Web Performance Link Performance Monitoring Solution Link Bootflat Flat UI color picker Link Free library of website, e-commerce and marketing resources Link Security, WordPress, email, fix, plugins, wordpress, plugins, themes, design, dev, development, security, htaccess, apache, php, sql, html, css, jquery, javascript, tutorials Link A curated directory of resources & tools to […]
Temporary Tables
Temporary Tables/Variables Temporary tables are created in tempdb database. They function like regular tables where you can perform Data Modification Language (DML) queries. If you create temp table inside stored procedure it gets destroyed once the stored procedure is completed. Scope of the temporary table is important, visible only to the particular user. Temporary tables […]
MS SQL SERVER – Triggers
MS SQL SERVER – Triggers Today I was working on Triggers for one of my project so thought to share some information about triggers. What are Triggers? Trigger is a database object that is attached to a table and gets fired upon action. The actions are INSERT, UPDATE or DELETE. How to perform an INSERT/UPDATE […]
C# Learning my way
.NET Library source code: link C# Coding Examples: Link List of Articles Introduction Overview Version and History Keywords Identifiers and Keywords Namespace Collection of Reserved Keywords Constructors and Instantiation Instance and Static Conversions Understanding Value Types Understanding String Reference Variables and Parameters Constant Static C# – Environment Variables Environment Variables C# – Enumerable Methods Enumerable […]
C# Environment Variables
C# Error: Sequence contains no element
C# Error: Sequence contains no element This error happen when I was trying to call Single() command like this: Held holdData = new HeldBusinessLogic().Get(id: cId).Single(); Since there was no record in the Held table, the Single() command results in error: “Sequence contains no elements” To fix the issue I had to change the code to: […]