sql - MS Access query: Use a select statement within Switch() function -


I am using the switch () function for conditional updates in the MS Access query. Below is my query

  UPDATE T_Generated_OpportunityLine SET PlContact_c = list (Nimnstevl Value_c = 'PTFDS - FD Ancloshor Systems', the OpportunityLine_PostCode.SESA OpportunityLine_PostCode, T_Generated_OpportunityLine where OpportunityLine_PostCode.Postcode = T_Generated_OpportunityLine.Selected_Zip and OpportunityLine_PostCode. OpptyLine_Ref = 'PTFDS', lower value Value_c = 'door entry system', OpportunityLine_PostCode.SESA Select OpportunityLine_PostCode, T_Generated_OpportunityLine where OpportunityLine_PostCode.Postcode = T_Generated_OpportunityLine.Selected_Zip and OpportunityLine_PostCode.OpptyLine_Ref = 'Gateway System');   

I'm aware of the synthesis of the switch () function:

  switch (expression1, value1, expression2, value2,. ..motion_n, value_n)   

I changed the value of the value "section instead of passing a static value I'm bringing this value through dynamically selecting a query

But when I'm trying to execute the query it has an error message that by stating:

  The query should be an updatable query   

I'm sure the problem is to select the statement inside the switch () function, but because of my project This conditional update is required.

Any suitable solution for this? I even compose the "value" part () in the switch? I want to know that a dynamic value can pass

if i have this your problem I do not know, but usually need to engage in subquery brackets:

  update T_Generated_OpportunityLine set PlContact_c the = list (LowestlevelValue_c = 'PTFDS - FD enclosure systems' (Sesa from OpportunityLine_PostCode Select where OpportunityLine_PostCode.Postcode = T_Generated_OpportunityLine.Selected_Zip and OpportunityLine_PostCode.OpptyLine_Ref = 'PTFDS'), LowestlevelValue_c = 'Door Entry Rnali '(Sesa OpportunityLine_PostCode where OpportunityLine_PostCode.Postcode = select T_Generated_OpportunityLine.Selected_Zip and OpportunityLine_PostCode.OpptyLine_Ref =' door entry system "));   

However, I would just write with a subquery:

  update T_Generated_OpportunityLine set PlContact_c = (select Sesa where as PC OpportunityLine_PostCode Pc.Postcode = T_Generated_OpportunityLine .Selected_Zip and (T_Generated_OpportunityLine.LowestlevelValue_c = 'PTFDS - FD Explorer Systems' and PP OpattiLine®Riff =' PTFDS 'or T_JenitedApportPennine.LowestLevelView =' Door Entry System 'and Optline LineRef =' Dyer Entry Tm "));    

Comments

Popular posts from this blog

php - PDO bindParam() fatal error -

logging - How can I log both the Request.InputStream and Response.OutputStream traffic in my ASP.NET MVC3 Application for specific Actions? -

java - Why my included JSP file won't get processed correctly? -