Example XML using element nodes:  &lt;?xml version="1.0" encoding="utf-8"?&gt; &lt;users&gt;   &lt;user&gt;     &lt;name&gt;David Smith&lt;/name&gt;     &lt;phone&gt;0441 234443&lt;/phone&gt;     &lt;email&gt;dave.s33@domain.com&lt;/email&gt;     &lt;addresses&gt;       &lt;address&gt;         &lt;street&gt;1 Some Street&lt;/street&gt;         &lt;town&gt;Toy Town&lt;/town&gt;         &lt;country&gt;UK&lt;/country&gt;       &lt;/address&gt;       &lt;address&gt;         &lt;street&gt;5 New Street&lt;/street&gt;         &lt;town&gt;Lego City&lt;/town&gt;         &lt;country&gt;US&lt;/country&gt;       &lt;/address&gt;     &lt;/addresses&gt;   &lt;/user&gt; &lt;/users&gt;   Example XML using attributes:  &lt;?xml version="1.0" encoding="utf-8"?&gt; &lt;users&gt;   &lt;user name="David Smith" phone="0441 234443" email="dave.s33@domain.com"&gt;     &lt;addresses&gt;       &lt;address street="1 Some Street" town="Toy Town" country="UK" /&gt;       &lt;address street="5 New Street" town="Lego City" country="US" /&gt;     &lt;/addresses&gt;   &lt;/user&gt; &lt;/users&gt;   I'm needing to build an XML file based on data from a relational database and can't work out whether I should use attributes or elements.  What is best practice when building XML files and why?
At work we are being asked to create XML files to pass data to another offline application that will then create a second XML file to pass back in order to update some of our data. During the process we have been discussing with the team of the other application about the structure of the XML file.   The sample I came up with is essentially something like:  &lt;INVENTORY&gt;    &lt;ITEM serialNumber="something" location="something" barcode="something"&gt;       &lt;TYPE modelNumber="something" vendor="something"/&gt;     &lt;/ITEM&gt; &lt;/INVENTORY&gt;   The other team said that this was not industry standard and that attributes should only be used for meta data. They suggested:  &lt;INVENTORY&gt;    &lt;ITEM&gt;       &lt;SERIALNUMBER&gt;something&lt;/SERIALNUMBER&gt;       &lt;LOCATION&gt;something&lt;/LOCATION&gt;       &lt;BARCODE&gt;something&lt;/BARCODE&gt;       &lt;TYPE&gt;          &lt;MODELNUMBER&gt;something&lt;/MODELNUMBER&gt;          &lt;VENDOR&gt;something&lt;/VENDOR&gt;       &lt;/TYPE&gt;    &lt;/ITEM&gt; &lt;/INVENTORY&gt;   The reason I suggested the first is that the size of the file created is much smaller. There will be roughly 80000 items that will be in the file during transfer. Their suggestion in reality turns out to be three times larger than the one I suggested. I searched for the mysterious "Industry Standard" that was mentioned, but the closest I could find was that XML attributes should only be used for meta data, but said the debate was about what was actually meta data.  After the long winded explanation (sorry) how do you determine what is meta data, and when designing the structure of an XML document how should you decide when to use an attribute or an element?
Considering the irreducible (by condition) polynomial $f=X^4-2aX^2+b\in\mathbb Q[X]$ and the field extension $K=\mathbb Q(\sqrt{a^2-b})$ of $\mathbb Q$, I want to show the following result:    For $[L:\mathbb Q]=4$ we have $\sqrt b\in K$ where $L$ is the splitting field of $f$.   My thoughts so far: The four roots of $f$ are $\pm\sqrt{a\pm\sqrt{a^2-b}}$. If $L$ is of degree $4$ it must be primitive since $f$ is irreducible, so $L=\mathbb Q\left(\sqrt{a+\sqrt{a^2-b}}\right)$. Then, by multiplying the two roots $\sqrt{a+\sqrt{a^{2}-b}}\cdot\sqrt{a-\sqrt{a^{2}-b}}=\sqrt{b}$ we have that $\sqrt{b}\in L$. Now I want to look at $$\mathbb Q\subset K\subset K(\sqrt b)\subset L$$ and differentiate some cases. The case where $[L:K]=1$ is trivial and the case $[L:K]=4$ can't happen because if we square any root and subtract $a$, we get $\pm\sqrt{a^2-b}\in K$ which means $[L:K]\leq 2$. So let's look at the case where $[L:K]=2$. As I see it, we get two subcases:   For $[L:K(\sqrt b)]=2$ we have $K(\sqrt b)=K$ which finishes the proof. For $[L:K(\sqrt b)]=1$ we have $K(\sqrt b)=L$. This means that $L$ is also the splitting field of $(x^2-b)(x^2-(a^2-b))$. Is this a contradiction? How do I finish this case? I'm writing up my dissertation and I'm really confused where to use "the". Examples:     In this experiment, (the?) heat transfer coefficient was calculated, allowing to estimate (the?)frost thickness.    And:     Firstly, (the?) air properties are defined.   And:     As (the?) crystals grow in radius, the amount of air in (the?) ice is reduced, due to (the?) ice becoming more packed.   None of the nouns mentioned above have been used for the first time, so I rule out the use of "a".   Would appreciate any help. SQL Server: Cannot insert an explicit value into a timestamp column error: requested operation requires superuser privilege Set same icon for all my Forms Is there any way to set the same icon to all my forms without having to change one by one? Something like when you setup GlobalAssemblyInfo for all your projects inside your solution. Package repository down, how to relocate? I would like to use the function of TeXnicCenter 1.0, where is automatically downloads missing packages used. The problem is, that the repository it wants to download from does not exist anymore (the one on piotrkosoft.net).  How do I get TeXnicCenter to try with another repository? Scenario: I have a custom button on a standard layout, which will call an apex class to do some validation on a record. If not validated, it needs to throw out some errors on that page. What are the best UX options to achieve this?  I am not too sure how to achieve this. Within a trigger, you can use the addError method to add the custom errors.  Can my Apex class reference the fields of a standard object? The ideal approach would be to do the following:  Contact.Email.addError('Please enter the right format here');   How can I achieve this via an apex class that the custom button will call?  What I have thought: Having a VF Page popup on the screen so that user can see all the errors, but that's not the best approach as UX is a big deal for this application  Thanks. Origins of Tension First of all, I have a confusion about the definition and idea of Tension. For example, in my Physics Textbook, the idea of tension is written like this: &quot;Let's say there is a wire with a cross-section area of A and its length is $L_o$. If I hang the wire from a point and hang a weight of W on the other end of the wire, it will generate a repulsive force of T. This T is called the Tension Force.&quot; For me, this only explains to me what force will we call tension force, but it doesn't quite explain to me what is exactly this Tension force or where it originates from. Also, I have been doing pulley problems (Figuring out the acceleration of weights hanging from pulleys)  by first labeling all of the tension forces by $T_1$, $T_2$, and then doing some math with them to get my answer. But It bugs me that I am using these tension force values without even knowing where they came from or what they are. My idea was, maybe Tension force comes from the intermolecular bonds between the molecules of the rope, rubber or wire, etc. But even then, I have some different situational questions. For example:  Why you can't push a rope, copper wire against a wall?  What happens when I pull on two ends of a wire with 2 different forces?  Does the force increase proportionally to the applied force? Why does the wire break after a certain amount of force is exceeded.?  Does the idea of tension apply to everyday objects,(for example, a coffee mug, glass pane, etc). If it does, can I use something like a heat map or 3D equation to describe the tension in every point of the object? [Edit: more concisely, is there a mathematical way to show the various amounts of tension forces on a 2D (like a metal sheet) and 3D objects (like a football ) instead of a 1D object(like a string)].  If I take a metallic object like a paperclip or a thin wire. I can bend It multiple times and it eventually breaks into two pieces. I used to do this to pull of capacitors from old circuit boards. But does it happen with things like ropes or paper? If not, why it doesn't happen? ( Maybe it has something to do with intermolecular forces and the various internal stresses?)  Let's say I have an iron bar and I have thrown it out into space. Does that iron bar have equal stress distribution or still uneven or will the stress on all points become zero? (Is there even such thing as zero stress?) I used a  for Photoshop, and was able to create some boxes with it. These boxes were shaped in the form of Software Boxes, while I require Customized Dimensions Boxes, which currently I'm trying to create with .   This software creates a box with no Reflection, and I disabled shadows in it, cause it doesn't allow transparency while saving to png. It allows custom dimensions, rotation, etc settings, but doesn't save transparency or reflections.  Here's the difference in output from both the above mentioned apps.. I'm trying to get the reflection + shadow in the 3D box Generator to the Protomissume generated image.   My question: How can I create similar Reflection &amp; Shadow in Photoshop?   Images:  3D Box Generator   Protomissume Box Shot   Thanks for any help.  Here are the Box Shot images (Photoshop, Protomissume) :  [  ] Is a capacitor in an open circuit charged? Say I have a circuit consisting of a battery, a wire, an open switch, and a capacitor. The circuit is open since the switch is open.  My book says that the capacitor will only be charged when the switch is closed, but I don't see why this is true. I would expect the capacitor to be charged a little - not as much as if the circuit is closed, but still charged none the less.  To further illustrate my point consider this: If the circuit is open, the current must be zero. Consequently the field must be zero. For the field to be zero, the capacitor's field must cancel out the battery's field. Therefore the capacitor must be charged.  Generalizing this concept, shouldn't capacitors be charged (to a lesser degree) in open circuits?  EDIT: In other words, if the field is zero, the capacitor must be charged to cancel out the field of the battery. Date Formatting C# How to read such figures with % as "up (by) 120%" and "increased (by) 120%". Do they mean the same? How do I prove that a graph is a topological manifold I'm having problems with that:  Prove that M is a topological manifold.  $f:U \to \mathbb R^k$, U $\subset \mathbb R^{n}$ open, f continuous  M = $\{\left(x,y\right)\in \mathbb R^{n+k} \mid x \in U, y=f(x) \}$  Can anyone help me please? What is this style of text-as-image called? I'm seeing a trend (especially on pinterest) of these posters where the image and subject is the text. THe text itself isn't really that important either, it's mainly the typefaces used and composition.  Does this style have a name to it? Is it just called text-as-image? Create a tar archive split into blocks of a maximum size Notifications in browser tab A very nice feature for Stack Overflow (and other Stack Exchange sites) would be to indicate the number of notifications (if any) in the browser tab like seen on Facebook:    Of course that would require automatic update if content has changed. Some kind of 'push-notification' which would be a nice feature as well. I will give this question a little context. Firstly, as I understand it, as soon as I "close the switch" on a circuit, electric current pretty quickly establishes a steady state where, at any given cross section along a wire, the average kinetic energy of that slice is both constant and equal anywhere along the wire. (Please correct me if I am misunderstanding).   If the average kinetic energy is constant anywhere throughout the wire in the circuit (which confuses me, as I would think that the electrons should all accelerate after exiting the resistor since they are no longer being impeded as much), that means that the average velocity is constant. So, in the example of a simple circuit with a battery of v Volts and a resistor of o Ohms, my question is the following:  Because a 'voltage drop' is known to occur across the resistor, what type energy is being "traded" to generate the heat that radiates from the resistor? I would think that the reflexive answer is "electrical energy"...hence the VOLTAGE drop (the sacrificed energy is clearly not kinetic, as the velocity is constant everywhere). However, I find this confusing. Does this mean that if I had a positive test charge, it would be easier for me to bring it to the beginning of the resistor as compared to bringing it to the end of the resister?     Further, if the correct answer IS "electrical energy", why exactly DOES electrical energy get "dissipated" as the electrons pass through the resistor? I always here the comment Oh! It's because all the electrons are running into densely packed crap which impedes their flow but that to me sounds like a reason for their KINETIC energy to be reduced. However, clearly that's not the case. So, ultimately, I guess the real question is:  **What goes on in the resistor that is literally removing electrical energy **. I am sure that this is a quantum mechanics question, but my quantum mechanics knowledge is not terribly strong. If I could get an answer that is devoid of crazy wave function equations, I would greatly appreciate it. Thanks! The most common way to refer to non-immediate family? How to disable a USB port in Windows (XP) and make it available only for charging? A generalization for Serret's integral $\int_0^a \frac{\ln(1+ax)}{1+x^2}dx$