I'm getting this error when running the code:     Error Code: 1093. You can't specify target table 'details' for update   in FROM clause   DELETE FROM details WHERE detail NOT IN  (     SELECT detail      FROM user_details     JOIN data ON user_details.data_iddata = data.iddata     JOIN details ON details.iddetails = data.details_iddetails )   What am I doing wrong here?
I have a table story_category in my database with corrupt entries. The next query returns the corrupt entries:  SELECT *  FROM  story_category  WHERE category_id NOT IN (     SELECT DISTINCT category.id      FROM category INNER JOIN         story_category ON category_id=category.id);   I tried to delete them executing:  DELETE FROM story_category  WHERE category_id NOT IN (     SELECT DISTINCT category.id      FROM category        INNER JOIN story_category ON category_id=category.id);   But I get the next error:      #1093 - You can't specify target table 'story_category' for update in FROM clause    How can I overcome this?
Just started blender, following the donut tutorial. Using Blender 2.8. made another donut to practice, when adding Lights I can't find the 'Use Nodes' in the Light settings. Some help would be appreciated &lt;3 How do I run a sudo command in Emacs? Is it possible to make the default scene fill two monitors at startup? I know how to set up the default scene by pressing Ctrl+U, but whenever I startup Blender it always fills only one of my screens, even if I set it to fill both before setting the default scene. I end up having to resize it every time I start it up. Is there a way to set this to happen by default? 1.13 Detect if no mobs with a specific tag exist and execute commands My 1.12 solution can be found . When trying to update command blocks to 1.13, I have the following:  scoreboard objectives add invert dummy   (run at start) then:  scoreboard players set FakePlayer invert 1   (impulse unconditional repeat) chained into:  execute at @e[tag=summoned] run scoreboard players reset FakePlayer invert   (chain unconditional repeat) chained into:  execute if score FakePlayer invert = 1 invert run say "All summoned animals are dead!"   This should reset FakePlayers score continuously until all entities with tag "summoned" are dead, then it should run the final condition. This does not happen, and I can't see why. How to politely negotiate PhD funding offer? I have been fortunate enough to get accepted with 5 years guaranteed funding to my 2nd choice graduate school. While the guarantee is great, the funding is only for 9/months out of the year. Would it be rude to ask them to guarantee summer funding to me for the first year until I can write a grant to get on a RAship? I know I should be more appreciative, since not everyone gets funding, but just an increase of about ~3k a year would make living there so much better and I do not want to accept an offer at a lesser institution just because of money.  What would be the most polite way of doing this?  I want to make it clear that I am not trying to get more money for the sake of getting more money, moreover that I am just not comfortable with so little money and such a high living cost in that area.  Thank you for your time. Latexmk can't see a dependency on a .fmt format file Stealing and reattaching a running process It's sunday and I left an instance of R running in the office. The script finished running, and I would like to save my workspace without going to the office. I can ssh to the computer, but I have not run the program into screen.  Is there a way, over ssh, to disown the process (I don't have access to jobsid of the terminal the program is running on!) and reattach it with say, reptyr? Reptyr and reptyr -T don't work without previously disowning the process  28845 3diag       20   0  139.3m  10.4m   0.0  0.1   0:12.06 S  `- urxvtd                                                                                        5327 3diag       20   0   16.4m   4.6m   0.0  0.1   0:00.02 S      `- bash                                                                                      5335 3diag       20   0 3499.3m 3.244g   0.0 43.3 171:57.89 S          `- R    The unique part of my question is that I explicitly require to detach a program without having access to the terminal in which it was created. How to Query all opportunities ids from account I write a sample query to fetch account Ids from cases of a particular record type.Then i wrote another sample query parent to child relationship to fetch opportunity ids from accounts.  My sample code  List&lt;Case&gt; c=new List&lt;Case&gt;(); c=[Select Id,accountId from case where RecordTypeId = '01290000000sF3L']; List&lt;Id&gt; accountIds= new List&lt;Id&gt;(); List&lt;Account&gt; accounts=new List&lt;Account&gt;(); List&lt;Opportunity&gt; opps=new List&lt;Opportunity&gt;(); for(Case cl:c)  { accountIds.add(cl.accountId); } accounts=[Select Id,name,(select Id,name from opportunities) from account        where Id in:accountIds]; System.debug('Data in accounts '+accounts);   But my issue is how to get opportunity id from above Soql accounts means how to add those opportunity id's to the list.  for(Account ao:accounts) { //How to fetch Opportunity ids from above account list. } How far can you go with rm -rf / as root My two main questions:  Are all URLs that include your User Id tracked?  Can the visitors who use the tracked URLs have Stack Exchange accounts?   Specifically: Recently the ability to earn badges for sharing links to posts on Stack Exchange sites . I'd like to know when and how this tracking works. It's clear that if you go to a question, and make use of the link button, you will get a URL with your User ID that will be tracked if a visitor uses it to get to SO. For example, let's use  as an example. It's regular URL is:  https://stackoverflow.com/questions/309300/defend-php-convince-me-it-isnt-horrible  If you go to that page and use &quot;save link as&quot; in the link section of the question you will be given a tracked url with your User ID:  https://stackoverflow.com/q/309300/[USER ID]  My question is, are there other URLs that would be tracked? All of the following URLs take you to the Question / Answer, but are they tracked? For example what if I just tack my User ID onto the long url?  https://stackoverflow.com/questions/309300/defend-php-convince-me-it-isnt-horrible/[USER ID]  What if I add my User ID to an answer URL?  https://stackoverflow.com/questions/309300/defend-php-convince-me-it-isnt-horrible/309622#309622/[USER ID]  or even  https://stackoverflow.com/q/309622/[USER ID]   Is there a way to know that a URL is being tracked? Is there some sort of format to follow? Are the only tracked URLs the ones provided in the Question links? Finally, does this sentence from the blog post mean that visitors cannot have an account?  Also, the tracked IPs must originate from outside our existing network. Why was the plan for the Purple Wedding so complicated? Spoilers for A Storm of Swords / Season 4 episode 2 "The Lion and the Rose".  At the Purple Wedding,      Littlefinger and Lady Olenna Tyrell   perform their plan of      poisoning King Joffrey.   A short summary of their plan:  Littlefinger orders Ser Dontos Hollard to give Sansa Stark a beautiful silver hairnet adorned with amethysts. At least some of the amethysts are actually strangler crystals in disguise. Ser Dontos also, still under orders of Littlefinger, urges Sansa to wear the hairnet at the wedding, which she then does. At the wedding, when Lady Olenna greets Sansa, she fusses her hairnet a bit, while secretly taking one of the strangler crystals. Later, during the wedding, Lady Olenna puts the crystal in Joffrey's royal cup, poisoning him.  But why was their plan so complicated? Why couldn't Lady Olenna just bring a strangler crystal with her to the wedding (as suggested in )?  Then they wouldn't depend on Ser Dontos and Sansa who could unknowingly have done something to prevent the success of the plan.  The only reason that I could think of, is Littlefinger and Lady Olenna plan for Sansa (and Tyrion as her husband with her) to take the blame for Joffrey's death.  They put the crystals on her person, so that upon examination it would clearly show that Sansa had the murder weapon on her. But Littlefinger had a plan he did not tell Lady Olenna, namely rescuing Sansa during the chaos ensuing the murder (and thereby leaving Tyrion behind as the only accused).  Is there anything confirming or debunking this theory? If my theory doesn't hold up, is there another explanation for why the plan was so needlessly complicated? How should I install HPLIP binary/proprietary plugin/driver for my HP printer or printer+scanner? Let's assume that one has some modern HP printer and/or scanner which is  supported by HPLIP package from official repository. Or supported by newer version of HPLIP package (see  about installation).  From official documentation () it is known that device needs proprietary/binary driver or plugin.  How should one install such plugin? I have seen a few  here on Meta&nbsp;Stack&nbsp;Exchange that cover parts of this, but they are often too local, and none of them seem to cover all the relevant scenarios.  I will break it up into multiple parts in order to make this more specific:     When should I vote on a question:   What are the qualifications for a question to be deserving of being up-voted? When shouldn't I vote up on a question? What are the things that would cause a question to need to be down-voted?   How should I go about down-voting the question (do I wait a little while to give the OP a chance to change it, or do I down-vote it immediately)?  When shouldn't I vote down on a question?  When should I vote on an answer:   What are the qualifications for an answer to be deserving of being up-voted? When shouldn't I vote up on an answer? What are the thing that would cause an answer to need to be down-voted?   How should I go about down-voting the answer (do I wait a little while to give the OP a chance to change it, or do I down-vote it immediately)?  When shouldn't I vote down on an answer?  When should I vote on a comment:   While votes on comments do not affect reputation points, it might be useful to new users to know when to up-vote them.    It seems that a full, comprehensive list of these would be invaluable to new users looking to figure out how the voting system works, but this list seems to be missing from the meta site. executing web service using postman Why does $A\sin{k(x+c)}=a\sin{kx}+b\cos{kx}$ imply that $A=\sqrt{a^2+b^2}$ and $\tan{c}=-b/a$? I don't understand this. These identities are given in the online notes for MIT's 18.01 calculus class. It's related to taking the sum of two trig functions and transforming them into a single trig function. I can use the formulas to do this, but I am having trouble finding anything on the internet to use a proof for my understanding.  Thanks for any responses!  EDITED (added after the first answer):  Sorry, the identity goes like this:  $A\sin{k(x-c)}=a\sin{kx}+b\cos{kx}$ ,  with the relationships  $a=A\cos{kc}$ , $b=-A\sin{kc}$ , $A=\sqrt{a^2+b^2}$ , and $\tan{kc}=-b/a$ What is a combo update and how is it different than the regular update? What is a combo update and how is it different from a normal update? To make your opinion known on MSE you need both up and downvotes. Given at the moment you need 125 rep to downvote on this site, the voting patterns will be skewed positive because not everyone is active on the site.   This is to be expected for regular Stack Exchange sites as you are expected to be involved in the community before you are deemed knowledgeable enough to be part of the community voice. However, MSE is different because you are voting for the entirety of the Stack Exchange network and you shouldn't need to be active on MSE itself to have a voice on changes to the entire network.  This is especially important for questions like  because it will effect every network to do with coding at all. This was brought up in .  I would suggest reducing the rep required to downvote on MSE down to 100 (or 101) rep. This is the amount you get for the site association bonus. This is given once you achieve 200 rep on any network site and shows that you are active in at least one community. I think this would be the perfect use of the association bonus in showing that you are a member of the Stack Exchange community. Mapping ManyToMany with composite Primary key and Annotation: I found there are so much excellent answer to questions about how to product high quality typesetting output. But I wonder how to save ink with LaTeX. What we need to think about to manage cost. page layout or something else? SObject row was retrieved via SOQL without querying the requested field on Contact.Account I am getting this error:     SObject row was retrieved via SOQL without querying the requested   field: Contact.Account   Controller:  public class WrapperAccountCtrl {      public List&lt;Account&gt; acclist{get;set;}     public List&lt;Contact&gt; conlist{get;set;}      public List&lt;MyWrapper&gt; wap{get;set;}      public WrapperAccountCtrl()      {         acclist=[Select id,name from Account];          conlist=[Select id,name,AccountID  from contact where AccountID IN:acclist];          system.debug('Size----'+conlist.size());           wap=new List&lt;MyWrapper&gt;();           for(integer i=0;i&lt;acclist.size();i++)          {              wap.add(new MyWrapper(conlist,acclist[i]));          }     }      public class MyWrapper     {          public Account accn{get;set;}          public List&lt;Contact&gt;conrec{get;set;}          public MyWrapper(List&lt;Contact&gt; con,Account acc)         {             accn=acc;             conrec=con;             }     } }   VF Page:  &lt;apex:page controller="WrapperAccountCtrl" sidebar="false"&gt;       &lt;apex:form &gt;          &lt;apex:pageBlock &gt;              &lt;apex:pageBlockTable value="{!conlist}" var="c"&gt;                  &lt;apex:column value="{!c.account.Name}"/&gt;              &lt;/apex:pageBlockTable&gt;          &lt;/apex:pageBlock&gt;      &lt;/apex:form&gt;  &lt;/apex:page&gt;