how can i extract date from datetime

All installation and configuration problems and questions

Moderators: gerski, enjay, williamconley, Op3r, Staydog, gardo, mflorell, MJCoate, mcargile, Kumba, Michael_N

how can i extract date from datetime

Postby sharad » Tue Nov 21, 2006 7:59 am

hi sir
i m using vicidial.i have a CRM project in which i can access the asterisk database.but i have a problem in accessing some records

like..........

in the vicidial_agent_log table event_time fields datatype formate is like that
2006-09-15 00:00:00 but that formate not supported by VB.NET.
so how i can access only date from this.

i was trying with changing datatype DATETIME to DATE.but by query it takes default time 12:00 AM automatically.

can u have some guidence ,about that how can i extract only date from datetime

thankyou
sharad
 
Posts: 36
Joined: Fri Jul 21, 2006 7:47 am

Postby mflorell » Tue Nov 21, 2006 11:31 am

Take a look at the mysql documentation:
http://dev.mysql.com/doc/refman/5.0/en/ ... tions.html

You can format datetime fields in just about any way you want.

I am still amazed how inflexible Microsoft makes even their programming languages when it comes to things like this.
mflorell
Site Admin
 
Posts: 18384
Joined: Wed Jun 07, 2006 2:45 pm
Location: Florida


Return to Support

Who is online

Users browsing this forum: No registered users and 120 guests