MySQL Forums
Forum List  »  Stored Procedures

Ambiguous column name 'AssetID'
Posted by: Casey Westover
Date: February 16, 2012 08:52AM

I'm getting a Ambiguous column name 'AssetID' error when i execute this stored procedure. Can someone help?

SELECT  @SqlSelect = "SELECT  h.Location " 
                + "       ,h.LocNo "
                + "       ,h.AssetID " 
                + "       ,h.AssetNo "
                + "       ,h.Description " 
                + "       ,h.AFENo "
                + "       ,h.Dept " 
                + "       ,h.SerialNo " 
                + "       ,h.Op "
                + "       ,h.NonOp " 
                + "       ,h.Disp "
                + "       ,h.DispDate "
                + "       ,h.UsefulLife " 
                + "       ,h.AcqDate "
                + "       ,h.AcqValue " 
                + "	      ,h.Depr "
                + "       ,h.NetBook " 
                + "       ,h.SalvValue "
                + "	      ,h.Active " 
                + "       ,h.PlaceServ "
                + "       ,d.DetailIndex " 
                + "       ,d.AuditDate " 
                + "       ,d.QuarterAudited "
                + "       ,d.Auditor " 
                + "       ,d.Labeled "
                + "       ,d.MaintNo "
                + "       ,d.TagLoc " 
                + "       ,d.AreaDesc "
                + "       ,d.Notes " 
                + "FROM FASTrackingHeader h "
                + "JOIN FASTrackingDetail d " 
                + "ON h.AssetID = d.AssetID " 
					 
        EXEC (@SqlSelect + @SqlWhere + @SqlOrderBy)


Options: ReplyQuote


Subject
Views
Written By
Posted
Ambiguous column name 'AssetID'
1733
February 16, 2012 08:52AM
743
February 16, 2012 09:26AM


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.