G
Guest
I'm trying to put a sql statment from an access query into a pivot table
query builder. I built the query in access then took the sql view and tried
to put it into the excel query builder -- not working.
Access put dbo_ in front of all of the table names so I took that out but
it's got other problems too. Not sure how the date range should be specified
and I wanted it to search a text field for the word "implant". In access I
did this by specifying *implant* but sql doesn't seem to like it.
Here's the statement:
SELECT ApptPending.CreateDate, ApptPending.ApptPendingID,
ApptPending.OfficeID, ApptPending.ProviderID
FROM ApptPending
WHERE (((ApptPending.PendingSource)=0) AND ((ApptPending.ApptTypeID)=6 Or
(ApptPending.ApptTypeID)=16)) OR (((ApptPending.ApptNote) Like "*implant*"))
GROUP BY ApptPending.CreateDate, ApptPending.ApptPendingID,
ApptPending.OfficeID, ApptPending.ProviderID
HAVING (((ApptPending.CreateDate)<=#3/16/2006#));
query builder. I built the query in access then took the sql view and tried
to put it into the excel query builder -- not working.
Access put dbo_ in front of all of the table names so I took that out but
it's got other problems too. Not sure how the date range should be specified
and I wanted it to search a text field for the word "implant". In access I
did this by specifying *implant* but sql doesn't seem to like it.
Here's the statement:
SELECT ApptPending.CreateDate, ApptPending.ApptPendingID,
ApptPending.OfficeID, ApptPending.ProviderID
FROM ApptPending
WHERE (((ApptPending.PendingSource)=0) AND ((ApptPending.ApptTypeID)=6 Or
(ApptPending.ApptTypeID)=16)) OR (((ApptPending.ApptNote) Like "*implant*"))
GROUP BY ApptPending.CreateDate, ApptPending.ApptPendingID,
ApptPending.OfficeID, ApptPending.ProviderID
HAVING (((ApptPending.CreateDate)<=#3/16/2006#));