how to add double quotation to string using C#.net

By
Advertisement
Introduction:
In this article i am going to explain a simple thin that is adding double quotes to the string in C#.Net.


Explanation:
While forming the string or query in c# we may pace the situation where we supposed to add double quotes to the string. We can add double quote to the string by prefixing \ before the double qoute. or by specifying the string between " string " 


Below is the sample code;

string query = "select OrderCode,OrderDesc,to_date(OrderDate,'dd-MON-YYYY') As \"OrderDate\" from tblOrder";
string query = "select OrderCode,OrderDesc,to_date(OrderDate,'dd-MON-YYYY') As "OrderDate" from tblOrder";

Do you like this article. Then comment here or share with your friends. Or like our Facebook page. 

0 comments:

Post a Comment

Online Casino