I wrote a script to update a field value on several thousand records based on certain criteria. I will only be doing this one time, and that's the  reason for not putting the logic in an Apex Class.   I tried running the script in Developer Console and ran into the classic 'Too many query records 50001' error.  I can put the logic in Batch Class, but that would mean writing a test class, and deploying the two classes to production. And after my records are updated , i will not be using this Batch Class again.   My question is -  How can i run the script to update records in Batches to avoid the 50001 error? Is limiting the SOQL to 5000 and running the script manually many time is my only option?
I'm attempting a mass update on Contacts via Execute Anonymous. My code gives me the following error:     System.LimitException: Apex CPU Time Limit Exceeded   Here's my code:  List &lt;Contact&gt; contactList = [select Id, Mass_Update_Checkbox__c from Contact Limit 1000];  for (Contact contact : contactList) {     contact.Mass_Update_Checkbox__c = TRUE;  }  update contactList;
I have a bunch of raw data values that are dollar amounts and I want to find a confidence interval for a percentile of that data.  Is there a formula for such a confidence interval? \ifmmode doesn't seem to work correctly inside an array environment I’m struggling with getting \ifmmode to work correctly when used inside an array environment which is inside a displaymath environment.  Here is a minimal example:  \documentclass{article}  \newcommand{\signal}[1]{%   \ifmmode     1#1   \else     2$#1$   \fi }  \begin{document} \begin{displaymath}   \begin{array}{cc}     \signal{a} \signal{b} &amp; \signal{c} \signal{d} \\   \end{array} \end{displaymath} \end{document}   This example generates the following output:        Why doesn’t all invokations of \signal detect math-mode? Why can't I define a static method in a Java interface? \numcases with \tag I would like to label some cases with specific tags, and was hoping for something like  \begin{numcases}{A = } \frac{r}{a} &amp; r &gt; a \tag{G} \\ \frac{a}{r} &amp; r &lt; a \tag{H} \end{numcases}   utilizing the numcasesenvironment from the cases package, and \tag from amsmath. However, the two don't seem to be compatible:     ! Package amsmath Error: \tag not allowed here.   Is there any alternatives that would do what I hope to accomplish? Why do physicists think that the electron is an elementary particle? I frequently need to check which packages are installed, and I use the following command:  dpkg -l | grep foo  which gives the following output  Desired=Unknown/Install/Remove/Purge/Hold | Status=Not/Inst/Cfg-files/Unpacked/Failed-cfg/Half-inst/trig-aWait/Trig-pend |/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad) ||/ Name                       Version         Description ii   foo                       &lt;version&gt;         &lt;description&gt;    What does the ii mean?  What other flags are there? How to read the flags? (because the explanation is quite complicated, IMO)   Thanks. The following is a rigorous proof of De Moivre's theorem by means of mathematical induction. The theorem put simply is that:  Any complex number, $z = a+bi$, on a cartesian plane can be expressed in polar form, where $a=r\cos\theta$ and $b=r\sin\theta$ and $r$ is the absolute distance from the origin to the point $z$. In light of this, the expression for the complex number $z$ in polar form is $z=r(\cos\theta+i\sin\theta)$ In order to find the $n^{th}$ power of $z$, the following rule applies: $$\displaystyle z^n=(r(\cos\theta+i\sin\theta))^n=r^n(\cos n\theta+i\sin n\theta)$$ where $n\in\mathbb N$ (I have confined $n$ to the natural numbers given that I intend on using mathematical induction to prove the theorem.  Base step: We must prove that what is stated is true for $n=1$, hence $$z^1=r^1(\cos 1\cdot\theta+i\sin1\cdot \theta)$$ $$=r(\cos\theta+i\sin\theta)$$ which is true. Next we assume it is true for $n=k$, and therefore proceed to the inductive step. Inductive step: When calculating $z^{n+1}$, it's the same as calculating $z^nz$, hence $$z^{n+1}=(r^n(\cos n\theta + i\sin n\theta))(r(\cos \theta+i\sin \theta))$$ $$=r^nr(\cos n\theta+i\sin n\theta)(\cos\theta +i\sin \theta)$$ $$=r^{n+1}(\cos n\theta\cdot\cos\theta+\cos n\theta \cdot i\sin\theta+i\sin n\theta\cdot\cos\theta+i^2\sin n\theta\cdot\sin\theta)$$ from here, $i^2=-1$, and therefore $+i^2\sin n\theta\cdot\sin\theta$ becomes $-\sin n\theta\cdot\sin\theta$. In addition to this, the following trigonometric identities will be used: $$\sin(n\theta + \theta) = \sin n\theta\cdot\cos\theta+\cos n\theta\cdot\sin\theta$$ $$or$$ $$k\sin(n \theta+\theta)=k\sin n \theta\cdot\cos \theta + \cos n\theta\cdot k\sin\theta$$ $$and$$ $$\cos(n \theta + \theta)=\cos n\theta\cdot\cos\theta-\sin n\theta\cdot\sin\theta$$ by using these, the original equation has now become $$=r^{n+1}(\cos(n \theta + \theta) + i\sin(n \theta + \theta))$$ then, after factoring out $\theta$, the theorem becomes $$=r^{n+1}(\cos((n+1)\theta)+i\sin((n+1)\theta))$$ which completes the proof. Question: is this proof correct all the way through? Or have I missed any conditions? If all is well in the case of this proof, could somebody aid me in proving it for $\{n|n\in\mathbb R,n\geq1\}$ CHECK constraint in MySQL is not working Under TeX, when I write a line too long, it prints a fat black box at the end of the line.  That is probably a feature, but I dislike it.  How to turn that OFF? Is there a command-line option or something else?   I usually use LaTeX, but I have a complicated file which happens to be plain TeX. How to discard unsaved changes to a view when editing it leads to a WSOD? Symmetric powers of modules Why does Perl's sprintf not round floating point numbers correctly? Value passed with request.setAttribute() is not available by request.getParameter() Show that the LU decomposition of matrices of the form $\left[\begin{smallmatrix}0& x\\0 & y\end{smallmatrix}\right]$ is not unique How can I show that every matrix of the form $\begin{bmatrix}0&amp; x\\0 &amp; y\end{bmatrix}$ has an $LU$ factorization and that even if $L$ is unit lower triangular there is not a unique factorization?  I am completely stuck. Any ideas would be greatly appreciated Holomorphic function $\varphi$ with fixed point $z_0$ such that $\varphi'(z_o)=1$ is linear? This is an exercise in complex analysis:     Let $\Omega\subset{\Bbb C}$ be open and bounded, and $\varphi:\Omega\to\Omega$ a holomorphic function. Prove that if there exists a point $z_0\in\Omega$ such that   $$ \varphi(z_0)=z_0\qquad\text{and   }\qquad \varphi'(z_0)=1 $$   then $\varphi$ is linear.   I'm trying work out the case $z_0=0$ first, in which $$ \varphi(z)=z+\sum_{n=2}^{\infty}a_nz^2. $$ It suffices to show that $a_n=0$ for all $n\geq 2$. If let $$ \varphi(z)=z+a_2z^2+O(z^3) $$ then  $$ \varphi^k(0)=z+ka_2z^2+O(z^3), $$ and $$ \varphi^k(0)=0,\quad (\varphi^k)'(0)=1. $$ If one can show that $\{ka_2\}_{k=1}^{\infty}$ is uniformly bounded, then one at least has $a_2=0$. But I don't know how to go on. Any idea? This is a story that was read on BBC radio about thirty years ago, and this is about as right as I can remember it: The human pilot of a spacecraft is doing some reconnaissance on an alien planet. He crashes but survives. For some reason, no one will know where to look for him. He sees something in the distance that looks like a building of some sort. When he gets there, it seems to be a home. Very much like a human home. There's furniture, but it's strange and uncomfortable . There's food, but it's inedible. There's a faucet but what comes out of it seems more like acid. Everything looks as though it should be right, but it's not. He leaves the house, wanders and after a few days is desperate for water. But there isn't any water anywhere. He's close to death, crawling on the ground and then something happens. There are cracks in the soil and there appears to be water bubbling up from perhaps some underground stream. The water revives him. He goes back to the house and tries the food again. It's delicious and he eats enough to gain back his strength. Then he decides to try the water again. It's pure and wonderful. He takes a shower and the last line of the story is how refreshing the water is on his skin and something about him lifting his tail. Gparted: move extended partition on the left I have some free disk space on the left of my ubuntu (sda5)  What is best solution to extend sda5 ?  I can    copy sda3 or sda5 with dd to bigger disk. delete sda3,5,swap create sda3,5,swap dd original partition.   Not sure how to do it properly.  May be there is a simpler solution. I need to grant select permission for all tables owned by a specific user to another user.  Can I do this with a single command along the lines of:  Grant Select on OwningUser.* to ReceivingUser   Or do I have to generate the sql for each table with something along the lines of:   Select 'GRANT SELECT ON OwningUser.'||Table_Name||'TO ReceivingUser'   From All_Tables Where Owner='OWNINGUSER' Typical software & tools short-list for *manual* QA specialist (tester) working environment For QA workstations preparation (Windows-based PCs) our IT department uses typical batch deployment tools. I'm not at all interested in the details of such process, but IT guys ask me:  What typical set of software you need for everyday manual testing tasks? We could include these in our deployment so that you guys could save more time for testing, not for environment prep &amp; tuning.  Sure thing we do test various range of projects, from web applications to standalone solutions, and each application requires its own set of tools for manual testing, e.g.:  Browsers Virtualization utilities DB clients Screens capturing tools FTP clients XML editors etc.  However, and that's for sure - there's a list of tools every QA MUST have installed on its PC, regardless of project types under testing. My area of experience is mostly standalone / complex web apps, that's why my vision on the task is a bit subjective. So, your suggestions of what are tools / software an average QA specialist can't live without will be highly appreciated. 2 assumptions:  Manual testing is a point of interest. Let's limit the list to not more than 15 (better 10) items.  Thanks in advance! Is "guy" gender-neutral?