Hi friend
i am new and in my project i have use asp.net and oracle database,
when i have enter date in textbox like(9/11/2013 - month-date-year) and run into insert query.
it will give me a error like:(ORA-01843: not a valid month at System.Data.OracleClient.).
so please help me for that.,
Thanks
Loading

Sanjeeb LenkaRank #301 · 8.3K reputationPosted Sep 11, 2013, 9:37 PM EDT
you have to insert it in "DD-MON-YY" or dd-MMM-yyyy format because this is the default format for Oracle.
before inserting to database convert it to "DD-MON-YY" or dd-MMM-yyyy format.
jignesh prajapati7 reputationPosted Sep 11, 2013, 10:01 PM EDT
IN TEXTBOX VALUE LIKE(9/11/2013) THIS,
NOW, IN QUERY I HAVE WRITE CODE LIKE (DateTime.TryParseExact(txtbook_dt.Text, "MM/dd/yyyy", null, System.Globalization.DateTimeStyles.None))
IT IS RIGHT OR WRONG
SO HELP ME
Sanjeeb LenkaRank #301 · 8.3K reputationPosted Sep 11, 2013, 10:32 PM EDT
Suthish NairRank #92 · 22.8K reputationPosted Sep 13, 2013, 2:12 AM EDT
jignesh prajapati7 reputationPosted Sep 13, 2013, 2:54 AM EDT
Sanjeeb LenkaRank #301 · 8.3K reputationPosted Sep 13, 2013, 3:05 AM EDT
share your sample code:aspx and .cs fro insert
jignesh prajapati7 reputationPosted Sep 13, 2013, 3:42 AM EDT
in txtbook_dt.text where am i store date.
protected void btnSave_Click(object sender, EventArgs e)
Suthish NairRank #92 · 22.8K reputationPosted Sep 13, 2013, 4:13 AM EDT