MySQL Forums
Forum List  »  Microsoft Access

Re: Time datatype from mysql appearing as date and time in access PTQ
Posted by: Avi Kauffmann
Date: April 06, 2010 06:38AM

Ok I actually figured this out. I'll claim that it came to me in a vision! So basically the solution to this was that I converted the time MySQL datatype into a char character type for the information, but I didn't realize that the index of a time datatype is still retained, so I just ordered it by that column. Way more simple than I thought it was going to be.

Here's the new code:
SELECT CONVERT(tbltime_slots.Time_Slot, CHAR(8)), '' AS Name
FROM tbltime_slots
WHERE Surgery_Day = 18
UNION
SELECT CONVERT(tblschedule.Surgery_Time, CHAR(8)), CONCAT(Last_Name, ', ', First_Name)
FROM tblschedule LEFT JOIN tblpatients ON tblschedule.PatientID = tblpatients.PatientID
WHERE (((tblschedule.Surgery_Date)= 18)) and (((tblschedule.SurgeonID)=2)) ORDER BY 1;

I hope this helps others in the future!
Avi out

Options: ReplyQuote


Subject
Views
Written By
Posted
Re: Time datatype from mysql appearing as date and time in access PTQ
2060
April 06, 2010 06:38AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.