BAQ to return only Approved Revisions

Thanks Jay,

 

I will give that a try and let you know if it works for me.  

Carol

 


Good morning,

I have created a query in which I only want approved revisions returned.  I have tried using the ECORev table and also the PartRev table and have selected "last" rather than each in both cases. I have tried to filter off by selecting "Approved" = "yes", but it still is returning all revisions for the part. Does anyone have any suggestions on what may work?

Please and thanks in advance.

Carol

Here is the syntax that I have used in the past for this particular problem.

for each Part no-lock , each PartRev where (Part.Company = PartRev.Company and Part.PartNum = PartRev.PartNum) no-lock , each PartPlant where (  PartPlant.PrimWhse = 'DIGITAL' OR  PartPlant.PrimWhse = 'FG-DIGI') and (Part.Company = PartPlant.Company and Part.PartNum = PartPlant.PartNum) no-lock , each ECORev where (  ECORev.ApprovedDate = PartRev.ApprovedDate AND  ECORev.ApprovedBy = PartRev.ApprovedBy) and (PartRev.PartNum = ECORev.PartNum and PartRev.RevisionNum = ECORev.RevisionNum and PartRev.AltMethod = ECORev.AltMethod) no-lock , each ECOOpr where (ECORev.Company = ECOOpr.Company and ECORev.GroupID = ECOOpr.GroupID and ECORev.PartNum = ECOOpr.PartNum and ECORev.RevisionNum = ECOOpr.RevisionNum and ECORev.AltMethod = ECOOpr.AltMethod) no-lock by Part.ProdCode by Part.PartNum by PartRev.RevisionNum by PartRev.AltMethod by ECOOpr.OprSeq.

Basically, the PartRev table will only include the current approved revision, so I go through that, then pull the EcoRev data by filtering: EcoRev.ApprovedDate = PartRev.ApprovedDate and EcoRev.ApprovedBy = PartRev.ApprovedBy. That way it will only give you engineering that was approved on the same date and by the same person as your currently approved PartRev.

Not sure if that is exactly what you were looking for, but it works well for me. If you want me to export my BAQ and upload it or sent it to you, let me know.

Jay


---In vantage@yahoogroups.com, <kschoenung@...> wrote :

#ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 filtered #ygrps-yiv-866332280ygrps-yiv-1267290834 {font-family:Wingdings;panose-1:5 0 0 0 0 0 0 0 0 0;} #ygrps-yiv-866332280 filtered #ygrps-yiv-866332280ygrps-yiv-1267290834 {font-family:Wingdings;panose-1:5 0 0 0 0 0 0 0 0 0;} #ygrps-yiv-866332280 filtered #ygrps-yiv-866332280ygrps-yiv-1267290834 {font-family:Calibri;panose-1:2 15 5 2 2 2 4 3 2 4;} #ygrps-yiv-866332280 filtered #ygrps-yiv-866332280ygrps-yiv-1267290834 {font-family:Tahoma;panose-1:2 11 6 4 3 5 4 4 2 4;} #ygrps-yiv-866332280 filtered #ygrps-yiv-866332280ygrps-yiv-1267290834 {font-family:Verdana;panose-1:2 11 6 4 3 5 4 4 2 4;} #ygrps-yiv-866332280 filtered #ygrps-yiv-866332280ygrps-yiv-1267290834 {font-family:Consolas;panose-1:2 11 6 9 2 2 4 3 2 4;} #ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 #ygrps-yiv-866332280ygrps-yiv-1267290834 p.ygrps-yiv-866332280ygrps-yiv-1267290834MsoNormal, #ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 li.ygrps-yiv-866332280ygrps-yiv-1267290834MsoNormal, #ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 div.ygrps-yiv-866332280ygrps-yiv-1267290834MsoNormal {margin:0in;margin-bottom:.0001pt;font-size:12.0pt;font-family:"Times New Roman", "serif";} #ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 a:link, #ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 span.ygrps-yiv-866332280ygrps-yiv-1267290834MsoHyperlink { color:blue;text-decoration:underline;} #ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 a:visited, #ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 span.ygrps-yiv-866332280ygrps-yiv-1267290834MsoHyperlinkFollowed { color:purple;text-decoration:underline;} #ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 p {

margin-right:0in;margin-left:0in;font-size:12.0pt;font-family:“Times New Roman”, “serif”;}
#ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 code
{
font-family:“Courier New”;}
#ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 pre
{

margin:0in;margin-bottom:.0001pt;font-size:10.0pt;font-family:“Courier New”;}
#ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 tt
{
font-family:“Courier New”;}
#ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 span.ygrps-yiv-866332280ygrps-yiv-1267290834cat
{}
#ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 span.ygrps-yiv-866332280ygrps-yiv-1267290834ct
{}
#ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 span.ygrps-yiv-866332280ygrps-yiv-1267290834HTMLPreformattedChar
{

font-family:Consolas;}
#ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 p.ygrps-yiv-866332280ygrps-yiv-1267290834attach, #ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 li.ygrps-yiv-866332280ygrps-yiv-1267290834attach, #ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 div.ygrps-yiv-866332280ygrps-yiv-1267290834attach
{

margin-right:0in;margin-left:0in;font-size:9.0pt;font-family:“Arial”, “sans-serif”;}
#ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 p.ygrps-yiv-866332280ygrps-yiv-1267290834bold, #ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 li.ygrps-yiv-866332280ygrps-yiv-1267290834bold, #ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 div.ygrps-yiv-866332280ygrps-yiv-1267290834bold
{

margin-right:0in;margin-left:0in;font-size:10.0pt;font-family:“Arial”, “sans-serif”;font-weight:bold;}
#ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 p.ygrps-yiv-866332280ygrps-yiv-1267290834green, #ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 li.ygrps-yiv-866332280ygrps-yiv-1267290834green, #ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 div.ygrps-yiv-866332280ygrps-yiv-1267290834green
{

margin-right:0in;margin-left:0in;font-size:12.0pt;font-family:“Times New Roman”, “serif”;color:#628C2A;}
#ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 p.ygrps-yiv-866332280ygrps-yiv-1267290834replbq, #ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 li.ygrps-yiv-866332280ygrps-yiv-1267290834replbq, #ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 div.ygrps-yiv-866332280ygrps-yiv-1267290834replbq
{
margin:3.0pt;font-size:12.0pt;font-family:“Times New Roman”, “serif”;}
#ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 p.ygrps-yiv-866332280ygrps-yiv-1267290834ad, #ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 li.ygrps-yiv-866332280ygrps-yiv-1267290834ad, #ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 div.ygrps-yiv-866332280ygrps-yiv-1267290834ad
{

margin-right:0in;margin-left:0in;font-size:12.0pt;font-family:“Times New Roman”, “serif”;}
#ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 p.ygrps-yiv-866332280ygrps-yiv-1267290834underline, #ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 li.ygrps-yiv-866332280ygrps-yiv-1267290834underline, #ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 div.ygrps-yiv-866332280ygrps-yiv-1267290834underline
{

margin-right:0in;margin-left:0in;font-size:12.0pt;font-family:“Times New Roman”, “serif”;}
#ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 span.ygrps-yiv-866332280ygrps-yiv-1267290834yshortcuts
{}
#ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 p.ygrps-yiv-866332280ygrps-yiv-1267290834ad1, #ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 li.ygrps-yiv-866332280ygrps-yiv-1267290834ad1, #ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 div.ygrps-yiv-866332280ygrps-yiv-1267290834ad1
{

margin-right:0in;margin-left:0in;font-size:12.0pt;font-family:“Times New Roman”, “serif”;}
#ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 p.ygrps-yiv-866332280ygrps-yiv-1267290834ad2, #ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 li.ygrps-yiv-866332280ygrps-yiv-1267290834ad2, #ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 div.ygrps-yiv-866332280ygrps-yiv-1267290834ad2
{

margin-right:0in;margin-bottom:7.5pt;margin-left:0in;font-size:12.0pt;font-family:“Times New Roman”, “serif”;}
#ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 p.ygrps-yiv-866332280ygrps-yiv-1267290834underline1, #ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 li.ygrps-yiv-866332280ygrps-yiv-1267290834underline1, #ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 div.ygrps-yiv-866332280ygrps-yiv-1267290834underline1
{

margin-right:0in;margin-left:0in;font-size:12.0pt;font-family:“Times New Roman”, “serif”;text-decoration:underline;}
#ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 span.ygrps-yiv-866332280ygrps-yiv-1267290834yshortcuts1
{
font-family:“Verdana”, “sans-serif”;font-weight:bold;}
#ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 span.ygrps-yiv-866332280ygrps-yiv-1267290834yshortcuts2
{
font-family:“Verdana”, “sans-serif”;font-weight:normal;}
#ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 span.ygrps-yiv-866332280ygrps-yiv-1267290834EmailStyle36
{
font-family:“Calibri”, “sans-serif”;color:#1F497D;}
#ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 .ygrps-yiv-866332280ygrps-yiv-1267290834MsoChpDefault
{
font-size:10.0pt;}
#ygrps-yiv-866332280 filtered #ygrps-yiv-866332280ygrps-yiv-1267290834 {
margin:1.0in 1.0in 1.0in 1.0in;}
#ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 div.ygrps-yiv-866332280ygrps-yiv-1267290834WordSection1
{}
#ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834
filtered #ygrps-yiv-866332280ygrps-yiv-1267290834 {
}
#ygrps-yiv-866332280 filtered #ygrps-yiv-866332280ygrps-yiv-1267290834 {

font-family:Symbol;}
#ygrps-yiv-866332280 filtered #ygrps-yiv-866332280ygrps-yiv-1267290834 {

font-family:“Courier New”;}
#ygrps-yiv-866332280 filtered #ygrps-yiv-866332280ygrps-yiv-1267290834 {

font-family:Wingdings;}
#ygrps-yiv-866332280 filtered #ygrps-yiv-866332280ygrps-yiv-1267290834 {

font-family:Wingdings;}
#ygrps-yiv-866332280 filtered #ygrps-yiv-866332280ygrps-yiv-1267290834 {

font-family:Wingdings;}
#ygrps-yiv-866332280 filtered #ygrps-yiv-866332280ygrps-yiv-1267290834 {

font-family:Wingdings;}
#ygrps-yiv-866332280 filtered #ygrps-yiv-866332280ygrps-yiv-1267290834 {

font-family:Wingdings;}
#ygrps-yiv-866332280 filtered #ygrps-yiv-866332280ygrps-yiv-1267290834 {

font-family:Wingdings;}
#ygrps-yiv-866332280 filtered #ygrps-yiv-866332280ygrps-yiv-1267290834 {

font-family:Wingdings;}
#ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 ol
{margin-bottom:0in;}
#ygrps-yiv-866332280 #ygrps-yiv-866332280ygrps-yiv-1267290834 ul
{margin-bottom:0in;}

Approved = true

 

From: vantage@yahoogroups.com [mailto:vantage@yahoogroups.com] On Behalf Of cmpelows@…
Sent: Thursday, March 06, 2014 10:02 AM
To: vantage@yahoogroups.com
Subject: [Vantage] BAQ to return only Approved Revisions

 

 


Good morning,

I have created a query in which I only want approved revisions returned.  I have tried using the ECORev table and also the PartRev table and have selected "last" rather than each in both cases. I have tried to filter off by selecting "Approved" = "yes", but it still is returning all revisions for the part. Does anyone have any suggestions on what may work?

Please and thanks in advance.

Carol