AmitDiwan has Published 11365 Articles

How to use a comma-separated string in an `IN ()` in MySQL?

AmitDiwan

AmitDiwan

Updated on 04-Nov-2019 10:46:30

2K+ Views

Set the comma-separated string in the IN() as in the below syntax:select *from yourTableName where yourColumnName IN('yourCommaSeparatedValue');Let us first create a table −mysql> create table DemoTable1314 -> ( -> Number varchar(100) -> ); Query OK, 0 rows affected (0.53 sec)Insert some records in the table using insert command −mysql> insert ... Read More

A single query to get the sum of count from different tables in MySQL?

AmitDiwan

AmitDiwan

Updated on 04-Nov-2019 10:42:49

2K+ Views

To get the sum of count from different tables, use UNION ALL. Let us first create a table −mysql> create table DemoTable1 -> ( -> Id int, -> Name varchar(30) -> ); Query OK, 0 rows affected (1.55 sec)Insert some records in the table using insert command −mysql> insert into ... Read More

Math.IEEERemainder() Method in C#

AmitDiwan

AmitDiwan

Updated on 04-Nov-2019 10:40:18

41 Views

The Math.IEEERemainder() method in C# is used to return the remainder resulting from the division of a specified number by another specified number.Syntaxpublic static double IEEERemainder (double dividend, double divisor);Let us now see an example to implement Math.IEEERemainder() method −Exampleusing System; public class Demo {    public static void Main(){ ... Read More

Type.GetDefaultMembers() Method in C#

AmitDiwan

AmitDiwan

Updated on 04-Nov-2019 10:37:17

49 Views

The Type.GetDefaultMembers() method in C# is used to search for the members defined for the current Type whose DefaultMemberAttribute is set.Syntaxpublic virtual System.Reflection.MemberInfo[] GetDefaultMembers ();Let us now see an example to implement the Type.GetDefaultMembers() method −Exampleusing System; using System.Reflection; [DefaultMemberAttribute("subject")] public class Demo {    public static void Main(){   ... Read More

Type.GetArrayRank() Method in C#

AmitDiwan

AmitDiwan

Updated on 04-Nov-2019 10:35:11

59 Views

The Type.GetArrayRank() method in C# gets the number of dimensions in an array.Syntaxpublic virtual int GetArrayRank ();Let us now see an example to implement the Type.GetArrayRank() method −Exampleusing System; public class Demo {    public static void Main(string[] args) {       Type type = typeof(int[, , ]);   ... Read More

Type.Equals() Method in C#

AmitDiwan

AmitDiwan

Updated on 04-Nov-2019 10:31:27

718 Views

The Type.Equals() method in C# determines if the underlying system type of the current Type is the same as the underlying system type of the specified Object or Type.Syntaxpublic virtual bool Equals (Type o); public override bool Equals (object o);Above, the parameters are the object whose underlying system type is ... Read More

Tuple Class in C#

AmitDiwan

AmitDiwan

Updated on 04-Nov-2019 10:29:26

56 Views

The Tuple class represents a 7-tuple, which is called septet. A tuple is a data structure that has a sequence of elements.It is used in −Easier access to a data set.Easier manipulation of a data set.To represent a single set of data.To return multiple values from a methodTo pass multiple ... Read More

Tuple Class in C#

AmitDiwan

AmitDiwan

Updated on 04-Nov-2019 10:26:19

54 Views

The Tuple class represents a 6-tuple. A tuple is a data structure that has sequence of elements.It is used in −Easier access to a data set.Easier manipulation of a data set.To represent a single set of data.To return multiple values from a methodTo pass multiple values to a methodIt has ... Read More

Tuple Class in C#

AmitDiwan

AmitDiwan

Updated on 04-Nov-2019 10:14:47

112 Views

The Tuple class represents a 5-tuple, which is called quintuple. A tuple is a data structure that has a sequence of elements.It is used in −Easier access to a data set.Easier manipulation of a data set.To represent a single set of data.To return multiple values from a methodTo pass multiple ... Read More

Math.Floor() Method in C#

AmitDiwan

AmitDiwan

Updated on 04-Nov-2019 10:08:50

3K+ Views

The Math.Floor() method in C# is used to return the largest integral value less than or equal to the specified number.Syntaxpublic static decimal Floor (decimal val); public static double Floor (double val)For the first syntax above, the value val is the decimal number, whereas Val in the second syntax is ... Read More

Advertisements