How To
DBCC CHECKIDENT RESEED 0
By Tan Lee Published on Dec 12, 2024 361
The DBCC CHECKIDENT command in SQL Server is used to check the current identity value of a table and, optionally, to reset the seed value of an identity column.
How to use LINQ to Entities Queries in Entity Framework
By Tan Lee Published on Feb 16, 2024 557
LINQ (Language Integrated Query) is a powerful feature in C# that allows you to query various data sources, including Entity Framework (EF) data contexts.
Using LINQ's Distinct() on a Specific Property
By Tan Lee Published on Dec 10, 2024 399
Here's an example of how to use LINQ's Distinct() method to filter unique values based on a particular property.
Difference Between Select and SelectMany in LINQ
By Tan Lee Published on Dec 10, 2024 335
In LINQ, Select and SelectMany are both used to project elements from a collection, but they behave differently, especially when dealing with nested collections or sequences.
Using LINQ to Query DataTables
By Tan Lee Published on Dec 10, 2024 413
To perform LINQ queries on a DataTable in C#, you first need to ensure that you are working with LINQ to DataSet, which allows you to query DataTable objects using LINQ syntax.
How to get value of element in JQuery
By Tan Lee Published on Dec 11, 2024 321
To get the value of an element using jQuery, you can use different methods depending on the type of element you're working with.
How do I copy a folder from remote to local using scp?
By Tan Lee Published on Dec 11, 2024 387
To copy a folder (directory) from a remote server to your local machine using scp, you need to use the -r (recursive) option, which tells scp to copy the entire folder and its contents.
How to drop temporary table if exists
By Tan Lee Published on Dec 11, 2024 384
To drop a temporary table if it exists, you can use the following SQL command.
How to download a file from server using SSH?
By Tan Lee Published on Dec 11, 2024 390
To download a file from a server using SSH, you'll typically use SCP (Secure Copy Protocol) or SFTP (SSH File Transfer Protocol).
How to generate random number in Javascript?
By Tan Lee Published on Dec 11, 2024 388
In JavaScript, you can generate random numbers using the Math.random() function. This function returns a random floating-point number between 0 and 1.
How to convert SQL Server's timestamp column to datetime format
By Tan Lee Published on Dec 11, 2024 1.38K
SQL Server's `TIMESTAMP` datatype has no relation to date or time. It is simply a hexadecimal representation of a consecutive 8-byte integer used for versioning, ensuring that a row hasn't been modified since it was last read.
IEnumerable<T> vs IQueryable<T>
By Tan Lee Published on Dec 10, 2024 257
The primary difference between IQueryable<T> and IEnumerable<T> lies in how and when the data is retrieved and processed.