469,290 Members | 1,746 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,290 developers. It's quick & easy.

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 2487
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 suresh191 | last post: by
reply views Thread by harlem98 | last post: by
1 post views Thread by Geralt96 | last post: by
reply views Thread by harlem98 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.