471,595 Members | 1,557 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,595 software developers and data experts.

asp with mysql

hai iam working in asp with mysql
i have on problem
asp have a mm/dd/yyyy format
and mysql have a yyyy/mm/dd format
now storing purpose it createing date problem so any one help me
Jun 6 '06 #1
4 2515
ablaye
11
When storing stuff in your mysql database use NOW() in your SQL statement.
When you retrieve the data, you can use ASP to parse the data and convert to the right format.
Jun 7 '06 #2
hi, iam elmaestro i have problems in conncting asp with adobc sql server & adobc mysql
Aug 1 '06 #3
hi,

convert date like that format
FormatDateTime(date_var, 4)

and insert ur DB
Aug 1 '06 #4
hi,

i think that format not working for ur query use this like this

Dim dd As Integer = System.Convert.ToInt32(stringdate.Substring(0, 2))
Dim mm As Integer = System.Convert.ToInt32(stringdate.Substring(3, 2))
Dim yyyy As Integer = System.Convert.ToInt32(stringdate.Substring(6, 4))

Dim dt As DateTime = New DateTime(yyyy, mm, dd)
dt = FormatDateTime(dt, DateFormat.LongDate)

Try it.....
Aug 1 '06 #5

Post your reply

Sign in to post your reply or Sign up for a free account.

Similar topics

4 posts views Thread by mikey | last post: by
reply views Thread by Yun Guan | last post: by
reply views Thread by Mike Chirico | last post: by
2 posts views Thread by Saqib Ali | last post: by
2 posts views Thread by trihanhcie | last post: by
reply views Thread by XIAOLAOHU | last post: by
reply views Thread by leo001 | last post: by
reply views Thread by Anwar ali | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.