Error inserting multiple rows in a table
''More than one row returned by a subquery used as an expression'' postgres error
Irreducible polynomial which is reducible modulo every prime How to show that $x^4+1$ is irreducible in $\mathbb Z[x]$ but it is reducible modulo every prime $p$?   For example I know that $x^4+1=(x+1)^4\bmod 2$. Also $\bmod 3$ we have that $0,1,2$ are not solutions of $x^4+1=0$ then if it is reducible the factors are of degree $2$. This gives that $x^4+1=(x^2+ax+b)(x^2+cx+d)$ and solving this system of equations $\bmod 3$  gives that $x^4+1=(x^2+x+2) (x^2+2x+2) \pmod 3$. But is there a simpler method to factor $x^4+1$ modulo a prime $p$? 'I have decided to purchase a jet for getting to NYC and back more quickly.' Are the following sentences grammatical or not? If not, does substituting a to-infinite make them grammatical? (Optional: designate if the sentence expresses purpose, reason, aim, or function)  1 I have decided to purchase a jet for getting to NYC and back more quickly. 2 I have decided to buy a jet for having a quicker way to get to NYC and back.  This is my only reason and aim; this will be the jet's only purpose and function.  3 I hate hairdryers, so I am buying a space heater for drying my hair more naturally, and that is my only aim &amp; purpose &amp; reason and that will be its only function 4 For having a lasting shine in your hair, buy ShineOn Shampoo. 5 My neighbor and I have decided to cooperate more for having a better life together.   Research done: ELL  (Note the  here is a restatement of Cambridge Dictionary's ) ELL  ELL  BBC English  (Currently the best site I've found.) ELU  All of which have answers that I find  (i) incomplete (ii) contradictory (iii) terribly confusing, if not (iv) wrong. To sort through the haze, I am focusing on one issue. Background Some sources say that you need to use a to-infinitive for expressing purpose, aim, function, reason, etc. I find these to be rather hazy distinctions, given that the ODO defines  as The reason for which something is done or created or for which something exists and the same work lists as : aim, reason, function, etc. It is my assertion that at least some of the following sentences demonstrate that one can use the -ing form (be it a gerund, verbal noun, participle) to express individual purpose (aim, reason, function, intention, whatever you want to call it). Do you agree, or not? Why (not)?  In shorter terms, are the sentences grammatical? or do we have to substitute a to-infinitive (including in order to + infinitive) to make them grammatical? (Optional: designate if the sentence expresses purpose, reason, aim, function, etc.) Notation question: $\ll$ My overall upgrade went well, but I am left with a critically lingering issue of mysql-server not being able to install itself, and nothing I am trying gets it to work.  This is the error I see when trying to install/reinstall it:  Setting up mysql-server-5.7 (5.7.11-0ubuntu6) ... Job for mysql.service failed because the control process exited with error code. See "systemctl status mysql.service" and "journalctl -xe" for details. invoke-rc.d: initscript mysql, action "start" failed. dpkg: error processing package mysql-server-5.7 (--configure):  subprocess installed post-installation script returned error exit status 1 dpkg: dependency problems prevent configuration of mysql-server:  mysql-server depends on mysql-server-5.7; however:   Package mysql-server-5.7 is not configured yet.  dpkg: error processing package mysql-server (--configure):  dependency problems - leaving unconfigured No apport report written because the error message indicates its a followup error from a previous failure.                    Processing triggers for systemd (229-4ubuntu4) ... Processing triggers for ureadahead (0.100.0-19) ... Errors were encountered while processing:  mysql-server-5.7  mysql-server E: Sub-process /usr/bin/dpkg returned an error code (1)   I've tried completely removing it, though doing so attempts to install MariaDB because of dependencies (?). Any suggestions on what I can do to fix this would be most welcome.  EDIT: Looks like I'm not the only one: I have a dictionary of values read from two fields in a database: a string field and a numeric field. The string field is unique, so that is the key of the dictionary.  I can sort on the keys, but how can I sort based on the values?  Note: I have read Stack Overflow question here  and probably could change my code to have a list of dictionaries, but since I do not really need a list of dictionaries I wanted to know if there is a simpler solution to sort either in ascending or descending order. How can I test whether a command's output is an empty string while not   interfering with buffering?  Example:  command | ??? if [ $? = 0 ] &amp;&amp; [ -n "$output_from_command"]; then    ...   I want the output from the code above to be the same as when running command. Can we move "Start a bounty" to a more intuitive location? Transferring Fallout 4 Saves (PS4) Best Algebraic Geometry text book? (other than Hartshorne) In counting degrees of freedom of a linear molecule, why is rotation about the axis not counted? Texmaker generated pdf file not showing the position of cursor I am compiling LaTeX files with Texmaker on Ubuntu 12.04 system.   When I run pdflatex and then view the pdf file (internal), it does not show me the exact place where I am editing on Texmaker i.e. the generated pdf file does not show me the position of the cursor.   But some days before it was working fine. I don't know what causes this problem.  I already tried uninstalling and then reinstalling, I did update and upgrade too. But the problem still persists. The new profile shouldn't mistakenly imply that you can earn the Informed badge on a meta site Hello and I'm quite new to Math SE.  I am trying to find the largest consecutive sequence of composite numbers. The largest I know is:  $$90, 91, 92, 93, 94, 95, 96$$  I can't make this series any longer because $97$ is prime unfortunately.  I can however, see a certain relation, if suppose we take the numbers like (let $a_1, a_2, a_3,...,a_n$denote digits and not multiplication):  $$a_1a_2a_3...a_n1,\ a_1a_2a_3...a_n2,\ a_1a_2a_3...a_n3,\ a_1a_2a_3...a_n4,\ a_1a_2a_3...a_n5,\ a_1a_2a_3...a_n6,\ a_1a_2a_3...a_n7,\ a_1a_2a_3...a_n8,\ a_1a_2a_3...a_n9,\ a_1a_2a_3...(a_n+1)0$$  The entire list of consecutive natural numbers I showed above can be made composite if:   The number formed by digits $a_1a_2a_3...a_n$ should be a multiple of 3 The numbers $a_1a_2a_3...a_n1$ and $a_1a_2a_3...a_n7$ should be composite numbers   If I didn't clearly convey what I'm trying to say, I mean like, say I want the two numbers (eg: ($121$, $127$) or ($151$, $157$) or ($181$, $187$)) to be both composite.  I'm still quite not equipped with enough knowledge to identify if a random large number is prime or not, so I believe you guys at Math SE can help me out. Specifically, define the sub-gaussian norm for a r.v. X as  $$ \|X\|_{\psi_2}=\inf\{t&gt;0:e^{X^2/t^2}\leq 2\}. $$  How do we prove that the centering inequality with $C=1$ does not hold in general? i.e. $$ \|X-\mathbb{E}X\|_{\psi_2}\leq C\|X\|_{\psi_2}.  $$ A counter example would work too. Thanks in advance! Proving that $S=\{\frac{1}{n}:n\in\mathbb{Z}\}\cup\{0\}$ is compact using the open cover definition Let $S=\{\frac{1}{n}:n\in\mathbb{Z}\}\cup\{0\}$ be a subset of $\mathbb{R}$. I have to prove using the open cover definition that this is compact. Could you help me, please? Why are so many important verbs irregular? C# compiler error: "cannot have instance field initializers in structs" Let A,B be in $M_{mxn}(\mathbb{R})$  Prove that if rank(A + B) = rank(A) + rank(B), then col(A) ∩ col(B) = {0}  I started with a proof by contradiction, since we know that rank(A + B) ≤ rank(A) + rank(B). I assume that if rank(A + B) &lt; rank(A) + rank(B), then col(A) ∩ col(B) = {0}. I realize that we don't have to do the > case. However I am a little confused on how to show col from rank. Measures of variable importance in random forests I've been playing around with random forests for regression and am having difficulty working out exactly what the two measures of importance mean, and how they should be interpreted.  The importance() function gives two values for each variable: %IncMSE and IncNodePurity. Is there simple interpretations for these 2 values?  For IncNodePurity in particular, is this simply the amount the RSS increase following the removal of that variable? I know that $\operatorname{Spec} \mathbb{C}[x]$ can be identified with the set $\mathbb{C}\cup *$, where $*$ is a generic point via the correspondence  $$ \prod_{i}(x-a_i) \leftrightarrow \{a_i\}_i , \ \ \ \ (0)\leftrightarrow *. $$ This correspondence holds for any $\operatorname{Spec} k[x]$ with algebraic closed field $k$.   When $k$ is not algebraic closed, how should one understand $\operatorname{Spec} k[x]$?