Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

C# SQL Statement

Status
Not open for further replies.

Pluto87

Programmer
Oct 7, 2011
23
US
Hi, I need a little help on this Sql Statement. The below function won't run in C#. I think and know my date function is wrong, can someone please correct the error? Thanks in advance!



string dataSQL = "";

dataSQL += " , Confirm_Date = to_date('" + DateTime.Now + "', 'MM/DD/YYYY HH:MI:SS AM') ";
 
What is the error you are getting, what is the definition of your SQL function? You need to provide more info.
 
I am getting an Execution fail. I believe it is this string because when I comment it out, it works fine.
 


What database are you attmpting to run against? to_date is Oracle specific syntax.


Mark

"You guys pair up in groups of three, then line up in a circle."
- Bill Peterson, a Florida State football coach
 
I am attempting SQL. Yes I know the statement is in Oracle, but I seem to can;t figure the SQL syntax.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top