MySQL Forums
Forum List  »  Microsoft Access

Re: sql from access-pls analyze this error
Posted by: Bob Field
Date: July 06, 2006 09:10AM

The bracket syntax is not accepted by MySQL. If an identifier needs to be enclosed because it has spaces, reserved characters, or is a reserved word, enclose it in backticks. In this instance lose the brackets and you'll be fine.

SELECT d.OrderID, d.DateSold, d.SalePrice, q.Referedby1, d.SalePrice*0.04 AS ReferredBy1Comm
FROM OrderDetails AS d
JOIN Query1 AS q ON OrderDetails.ContactAutoID = Query1.ContactAutoID
WHERE q.Referedby1 IS NOT NULL
AND q.Referedby1>0;

[I've never liked the output of the Access query builder.]

Options: ReplyQuote


Subject
Views
Written By
Posted
Re: sql from access-pls analyze this error
1470
July 06, 2006 09:10AM


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.