qid int64 4 19.1M | question stringlengths 18 48.3k | answers list | date stringlengths 10 10 | metadata list |
|---|---|---|---|---|
156,686 | <p>How do I initialize an automatic download of a file in Internet Explorer?</p>
<p>For example, in the download page, I want the download link to appear and a message: "If you download doesn't start automatically .... etc". The download should begin shortly after the page loads.</p>
<p>In Firefox this is easy, you j... | [
{
"answer_id": 156703,
"author": "ullmark",
"author_id": 23044,
"author_profile": "https://Stackoverflow.com/users/23044",
"pm_score": 5,
"selected": false,
"text": "setTimeout(function () { window.location = 'my download url'; }, 5000)\n"
},
{
"answer_id": 156715,
"author": ... | 2008/10/01 | [
"https://Stackoverflow.com/questions/156686",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/4685/"
] |
156,688 | <p>I have an error occuring frequently from our community server installation whenever the googlesitemap.ashx is traversed on a specific sectionID. I suspect that a username has been amended but the posts havn't recached to reflect this.</p>
<p>Is there a way a can check the data integruity by performing a select stat... | [
{
"answer_id": 156703,
"author": "ullmark",
"author_id": 23044,
"author_profile": "https://Stackoverflow.com/users/23044",
"pm_score": 5,
"selected": false,
"text": "setTimeout(function () { window.location = 'my download url'; }, 5000)\n"
},
{
"answer_id": 156715,
"author": ... | 2008/10/01 | [
"https://Stackoverflow.com/questions/156688",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/5055/"
] |
156,689 | <p>Do you have a common base class for Hibernate entities, i.e. a MappedSuperclass with id, version and other common properties? Are there any drawbacks?</p>
<p>Example:</p>
<pre><code>@MappedSuperclass()
public class BaseEntity {
private Long id;
private Long version;
...
@Id @GeneratedValue(strate... | [
{
"answer_id": 414950,
"author": "Matt Sidesinger",
"author_id": 1481472,
"author_profile": "https://Stackoverflow.com/users/1481472",
"pm_score": 3,
"selected": false,
"text": "public abstract class BaseEntity implements Serializable {\n\n public abstract Long getId();\n public ab... | 2008/10/01 | [
"https://Stackoverflow.com/questions/156689",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/18722/"
] |
156,696 | <p>Which browsers other than Firefox support Array.forEach()? <a href="http://developer.mozilla.org/En/Core_JavaScript_1.5_Reference:Objects:Array:forEach#Compatibility" rel="noreferrer">Mozilla say it's an extension to the standard</a> and I realise it's trivial to add to the array prototype, I'm just wondering what ... | [
{
"answer_id": 65302130,
"author": "jac wida",
"author_id": 14762559,
"author_profile": "https://Stackoverflow.com/users/14762559",
"pm_score": 0,
"selected": false,
"text": "foreach ?Support unknow"
}
] | 2008/10/01 | [
"https://Stackoverflow.com/questions/156696",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/21030/"
] |
156,697 | <p>In my environment here I use Java to serialize the result set to XML.
It happens basically like this:</p>
<pre><code>//foreach column of each row
xmlHandler.startElement(uri, lname, "column", attributes);
String chars = rs.getString(i);
xmlHandler.characters(chars.toCharArray(), 0, chars.length());
xmlHandler.endEl... | [
{
"answer_id": 156741,
"author": "Eugene Yokota",
"author_id": 3827,
"author_profile": "https://Stackoverflow.com/users/3827",
"pm_score": 2,
"selected": false,
"text": "<column num=\"1\"><![CDATA[10069]]></column>\n<column num=\"2\"><![CDATA[sd&]]></column>\n"
},
{
"answer_id": ... | 2008/10/01 | [
"https://Stackoverflow.com/questions/156697",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/21027/"
] |
156,701 | <p>This is a question with many answers - I am interested in knowing what others consider to be "best practice".</p>
<p>Consider the following situation: you have an object-oriented program that contains one or more data structures that are needed by many different classes. How do you make these data structures access... | [
{
"answer_id": 156919,
"author": "Zarkonnen",
"author_id": 15255,
"author_profile": "https://Stackoverflow.com/users/15255",
"pm_score": 2,
"selected": false,
"text": "FwurzleDigestionListener Fwurzle DigestionTract"
}
] | 2008/10/01 | [
"https://Stackoverflow.com/questions/156701",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/7732/"
] |
156,712 | <p>If I hit a page which calls <code>session_start()</code>, how long would I have to wait before I get a new session ID when I refresh the page?</p>
| [
{
"answer_id": 156733,
"author": "jochil",
"author_id": 23794,
"author_profile": "https://Stackoverflow.com/users/23794",
"pm_score": 3,
"selected": false,
"text": "phpinfo() session.gc_maxlifetime session.cache_expire session.cookie_lifetime"
},
{
"answer_id": 156819,
"autho... | 2008/10/01 | [
"https://Stackoverflow.com/questions/156712",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1741868/"
] |
156,724 | <p>I'm having a problem with my Seam code and I can't seem to figure out what I'm doing wrong. It's doing my head in :) Here's an excerpt of the stack trace:</p>
<pre><code>Caused by: java.lang.IllegalArgumentException: Can not set java.lang.Long field com.oobjects.sso.manager.home.PresenceHome.customerId to java.la... | [
{
"answer_id": 157090,
"author": "Chobicus",
"author_id": 1514822,
"author_profile": "https://Stackoverflow.com/users/1514822",
"pm_score": 0,
"selected": false,
"text": "<f:param name=\"customerId\" value=\"#{customerId.toString()}\" />"
},
{
"answer_id": 157310,
"author": "... | 2008/10/01 | [
"https://Stackoverflow.com/questions/156724",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1900/"
] |
156,745 | <p>I am using Eclipse for quite some time and I still haven't found how to configure the Problems View to display only the Errors and Warnings of interest. Is there an easy way to filter out warnings from a specific resource or from a specific path? For example, when I generate javadoc I get tons of irrelevant html war... | [
{
"answer_id": 9283019,
"author": "Claude COULOMBE",
"author_id": 1209842,
"author_profile": "https://Stackoverflow.com/users/1209842",
"pm_score": 2,
"selected": false,
"text": "Configure Contents Use item limits Configure Contents Number of items visible per group:"
}
] | 2008/10/01 | [
"https://Stackoverflow.com/questions/156745",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/24054/"
] |
156,748 | <p>How do I go about using HTTPS for some of the pages in my ASP.NET MVC based site?</p>
<p>Steve Sanderson has a pretty good tutorial on how to do this in a DRY way on Preview 4 at:</p>
<p><a href="http://blog.codeville.net/2008/08/05/adding-httpsssl-support-to-aspnet-mvc-routing/" rel="noreferrer">http://blog.codev... | [
{
"answer_id": 1116780,
"author": "Simon_Weaver",
"author_id": 16940,
"author_profile": "https://Stackoverflow.com/users/16940",
"pm_score": 4,
"selected": false,
"text": " [RequireSsl(Redirect = true)]\n"
},
{
"answer_id": 2359061,
"author": "Amadiere",
"author_id": 7... | 2008/10/01 | [
"https://Stackoverflow.com/questions/156748",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/13238/"
] |
156,767 | <p>When verbally talking about methods, I'm never sure whether to use the word <em>argument</em> or <em>parameter</em> or something else. Either way the other people know what I mean, but what's correct, and what's the history of the terms?</p>
<p>I'm a C# programmer, but I also wonder whether people use different ter... | [
{
"answer_id": 156787,
"author": "Torbjörn Hansson",
"author_id": 22683,
"author_profile": "https://Stackoverflow.com/users/22683",
"pm_score": 11,
"selected": true,
"text": "public void MyMethod(string myParam) { }\n\n...\n\nstring myArg1 = \"this is my argument\";\nmyClass.MyMethod(myA... | 2008/10/01 | [
"https://Stackoverflow.com/questions/156767",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/5351/"
] |
156,769 | <p>The workflow is like this:</p>
<ol>
<li>I receive a scan of a coupon with data (firstname, lastname, zip, city + misc information) on it.</li>
<li>Before I create a new customer, I have to search the database if the customer might exist already.</li>
</ol>
<p>Now my question: What's the best way to find an existin... | [
{
"answer_id": 156805,
"author": "Treb",
"author_id": 22114,
"author_profile": "https://Stackoverflow.com/users/22114",
"pm_score": -1,
"selected": false,
"text": "SELECT ID FROM tbl_customers WHERE \n first_name LIKE 'JOHN' \n AND last_name LIKE 'Doe' \n AND zip_code=12345 \n AN... | 2008/10/01 | [
"https://Stackoverflow.com/questions/156769",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/24053/"
] |
156,777 | <p>This is a followup question of <a href="https://stackoverflow.com/questions/156697/how-to-encode-characters-from-oracle-to-xml">How to encode characters from Oracle to Xml?</a></p>
<p>In my environment here I use Java to serialize the result set to xml. I have no access to the output stream itself, only to a org.xm... | [
{
"answer_id": 157635,
"author": "Josh",
"author_id": 2204759,
"author_profile": "https://Stackoverflow.com/users/2204759",
"pm_score": 4,
"selected": true,
"text": "<![CDATA[ DefaultHandler2 TransformerHandler CDATA_SECTION_ELEMENTS StreamResult streamResult = new StreamResult(out);\nSA... | 2008/10/01 | [
"https://Stackoverflow.com/questions/156777",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/21027/"
] |
156,779 | <p>I've written a simple SessionItem management class to handle all those pesky null checks and insert a default value if none exists. Here is my GetItem method:</p>
<pre><code>public static T GetItem<T>(string key, Func<T> defaultValue)
{
if (HttpContext.Current.Session[key] == null)
{
Ht... | [
{
"answer_id": 156789,
"author": "Konrad Rudolph",
"author_id": 1968,
"author_profile": "https://Stackoverflow.com/users/1968",
"pm_score": 2,
"selected": false,
"text": "defaultValue.Invoke() defaultValue()"
},
{
"answer_id": 156802,
"author": "Marc Gravell",
"author_id"... | 2008/10/01 | [
"https://Stackoverflow.com/questions/156779",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/192/"
] |
156,799 | <p>In C++ the storage class specifier static allocates memory from the data area. What does "data area" mean?</p>
| [
{
"answer_id": 156876,
"author": "janm",
"author_id": 7256,
"author_profile": "https://Stackoverflow.com/users/7256",
"pm_score": 3,
"selected": false,
"text": "static int s_value_one;\nstatic int s_value_two = 123;\n"
}
] | 2008/10/01 | [
"https://Stackoverflow.com/questions/156799",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/11554/"
] |
156,800 | <p>I have created a nice silverlight control doing exactly what I want it to do, and it looks great :) When I host it in the test projects ASPX sample file or the HTML sample file it shows up nicely.</p>
<p>I now have to use the control in my existing ASP.NET 2.0 project, which has a fancy design. The problem I'm havi... | [
{
"answer_id": 225662,
"author": "Torbjørn",
"author_id": 22621,
"author_profile": "https://Stackoverflow.com/users/22621",
"pm_score": 3,
"selected": true,
"text": "<script type=\"text/javascript\">\n function refreshSL()\n {\n var div = document.getElementById('silverlight... | 2008/10/01 | [
"https://Stackoverflow.com/questions/156800",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/22621/"
] |
156,810 | <p>What is the best way to download files to local hard drive when logged in to another computer using ssh in bash. I'm aware of sftp, but it is not convienent, e.g. it lacks tab completion of directory names. I'm using Ubuntu 8.04.1 . I don't have a public IP and would not like to setup dynamic Dynamic DNS solution.</... | [
{
"answer_id": 156881,
"author": "Sam Stokes",
"author_id": 20131,
"author_profile": "https://Stackoverflow.com/users/20131",
"pm_score": 4,
"selected": true,
"text": "$ scp me@myserver.mydomain.com:.bashr<TAB>\n $ scp me@myserver.mydomain.com:.bashrc .\n sudo apt-get install bash-comple... | 2008/10/01 | [
"https://Stackoverflow.com/questions/156810",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/11439/"
] |
156,815 | <p>In a <a href="https://stackoverflow.com/questions/9033#9099">question answer</a> I find the following coding tip:-</p>
<p>2) simple lambdas with one parameter:</p>
<pre><code>x => x.ToString() //simplify so many calls
</code></pre>
<p>As someone who has not yet used 3.0 I don't really understand this tip but i... | [
{
"answer_id": 156823,
"author": "Jacob",
"author_id": 22107,
"author_profile": "https://Stackoverflow.com/users/22107",
"pm_score": 2,
"selected": false,
"text": "private string Lambda(object x) {\n return x.ToString();\n}\n"
},
{
"answer_id": 156838,
"author": "Jon Skeet",... | 2008/10/01 | [
"https://Stackoverflow.com/questions/156815",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/22284/"
] |
156,833 | <p>I need to consume a wcf service dynamically when all i know is its URL. I do not have the option of creating a service reference or web reference as my client side code picks up the URL from a config file. What classes and methods can i use from the System.ServiceModel namespace for doing so.</p>
| [
{
"answer_id": 156848,
"author": "Rinat Abdullin",
"author_id": 47366,
"author_profile": "https://Stackoverflow.com/users/47366",
"pm_score": 1,
"selected": false,
"text": "using (WebChannelFactory<IService> wcf = new WebChannelFactory<IService>(new Uri(\"http://localhost:8000/Web\")))\n... | 2008/10/01 | [
"https://Stackoverflow.com/questions/156833",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/16439/"
] |
156,835 | <p>I have inherited some code for a custom CMS that is a little out of my league and keep stumbling over the same errors, Notice: Undefined variable: media in /Applications/MAMP/htdocs/Chapman/Chapman_cms/admin/team-2.php on line 48. This is supposed to create new users and edit old users. However, it does not work whe... | [
{
"answer_id": 156882,
"author": "Lasar",
"author_id": 9438,
"author_profile": "https://Stackoverflow.com/users/9438",
"pm_score": 0,
"selected": false,
"text": "<?=$media['copy']?> error_reporting(E_ERROR | E_WARNING | E_PARSE);\n"
},
{
"answer_id": 156909,
"author": "Ólafur... | 2008/10/01 | [
"https://Stackoverflow.com/questions/156835",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] |
156,852 | <p>Ok, here's one for the Java/JavaScript gurus:</p>
<p>In my app, one of the controllers passes a TreeMap to it's JSP. This map has car manufacturer's names as keys and Lists of Car objects as values. These Car objects are simple beans containing the car's name, id, year of production etc.
So, the map looks something... | [
{
"answer_id": 156865,
"author": "Community",
"author_id": -1,
"author_profile": "https://Stackoverflow.com/users/-1",
"pm_score": 1,
"selected": false,
"text": "var map = {\n 'porsche': [ 'boxter', '911', 'carrera' ],\n 'fiat': ['punto', 'uno']\n};\n"
},
{
"answer_id": 16060... | 2008/10/01 | [
"https://Stackoverflow.com/questions/156852",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/19911/"
] |
156,873 | <p>I'm writing a shell for a project of mine, which by design parses commands that looks like this:</p>
<p>COMMAND_NAME ARG1="Long Value" ARG2=123 ARG3=me@me.com</p>
<p>My problem is that Python's command line parsing libraries (getopt and optparse) forces me to use '-' or '--' in front of the arguments. This behavio... | [
{
"answer_id": 156901,
"author": "Thomas Wouters",
"author_id": 17624,
"author_profile": "https://Stackoverflow.com/users/17624",
"pm_score": 0,
"selected": false,
"text": "parser = optparse.OptionParser()\nparser.add_option(\"--ARG1\", dest=\"arg1\", help=\"....\")\nparser.add_option(..... | 2008/10/01 | [
"https://Stackoverflow.com/questions/156873",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/9941/"
] |
156,880 | <p>I have some REST web services implemented in WCF. I wish to make these services return "Bad Request" when the xml contains invalid elements.</p>
<p>The xml serialization is being handled by XmlSerializer. By default XmlSerializer ignores unknown elements. I know it is possible to hook XmlSerializer.UnknownElement a... | [
{
"answer_id": 163331,
"author": "DavidWhitney",
"author_id": 1297,
"author_profile": "https://Stackoverflow.com/users/1297",
"pm_score": 1,
"selected": false,
"text": " protected override void OnWriteMessage(XmlDictionaryWriter writer)\n {\n ...\n }\n\n protected over... | 2008/10/01 | [
"https://Stackoverflow.com/questions/156880",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/2281/"
] |
156,911 | <p>I am going to work on a project where a fairly large web app needs to tweaked to handle several languages. The thing runs with a hand crafted PHP code but it's pretty clean.</p>
<p>I was wondering what would be the best way to do that?</p>
<ol>
<li><p>Making something on my own, trying to fit the actual architectu... | [
{
"answer_id": 1620010,
"author": "Niklas Rosencrantz",
"author_id": 108207,
"author_profile": "https://Stackoverflow.com/users/108207",
"pm_score": -1,
"selected": false,
"text": "{% get_current_language as LANGUAGE_CODE %}{{ LANGUAGE_CODE }}{% get_available_languages as LANGUAGES %}{% ... | 2008/10/01 | [
"https://Stackoverflow.com/questions/156911",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/9951/"
] |
156,912 | <p>I am working on developing an on-screen keyboard with java. This keyboard has a <code>JComponent</code> for every possible key. When a mouse down is detected on the button, I want to send a specific keyboard code to the application currently on focus. The keyboard itself is within a <code>JFrame</code> with no de... | [
{
"answer_id": 187501,
"author": "Mario Ortegón",
"author_id": 2309,
"author_profile": "https://Stackoverflow.com/users/2309",
"pm_score": 2,
"selected": false,
"text": " setUndecorated(true);\n setFocusableWindowState(false);\n setFocusable(false);\n enableInputMethods(false... | 2008/10/01 | [
"https://Stackoverflow.com/questions/156912",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/2309/"
] |
156,913 | <p><strong>Concrete use case:</strong>
In the Eclipse IDE, new 'plugins' can be added by copying a plugin's file(s) into the <code>$ECLIPSE_HOME/plugins</code> directory. However, I want to keep my original Eclipse installation 'clean' without additional plugins because I want to run this basic installation on its own ... | [
{
"answer_id": 157180,
"author": "VonC",
"author_id": 6309,
"author_profile": "https://Stackoverflow.com/users/6309",
"pm_score": 1,
"selected": false,
"text": "/path/links -> /remote/links/commonPlugins\n/eclipse/links -> ../links\n"
}
] | 2008/10/01 | [
"https://Stackoverflow.com/questions/156913",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] |
156,916 | <p>I need to list all files whose names start with 'SomeLongString'. But the case of 'SomeLongString' can vary. How?</p>
<p>I am using zsh, but a bash solution is also welcome.</p>
| [
{
"answer_id": 156953,
"author": "Horst Gutmann",
"author_id": 22312,
"author_profile": "https://Stackoverflow.com/users/22312",
"pm_score": 4,
"selected": false,
"text": "find find . -iname 'SomeLongString*' -maxdepth 1\n -iname -name"
},
{
"answer_id": 156958,
"author": "Ja... | 2008/10/01 | [
"https://Stackoverflow.com/questions/156916",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/45603/"
] |
156,930 | <p>We have an existing classic ASP intranet consisting of hundreds of pages. Its directory structure looks like this...</p>
<pre><code>/root
app_1
app_2
...
img
js
style
</code></pre>
<p>Obviously app_1 and so on have better names in the actual directory structure.</p>
<p>Even though the many... | [
{
"answer_id": 157244,
"author": "rohancragg",
"author_id": 5351,
"author_profile": "https://Stackoverflow.com/users/5351",
"pm_score": 2,
"selected": false,
"text": "/root\n app_1\n app_2\n dotnetapp_1\n <virtual>img\n <virtual>js\n ...\n img\n js\n style\n"
},
{
"a... | 2008/10/01 | [
"https://Stackoverflow.com/questions/156930",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/7508/"
] |
156,936 | <p>I have been using C# for a while now, and going back to C++ is a headache. I am trying to get some of my practices from C# with me to C++, but I am finding some resistance and I would be glad to accept your help.</p>
<p>I would like to expose an iterator for a class like this:</p>
<pre><code>template <class T&g... | [
{
"answer_id": 156995,
"author": "Sébastien RoccaSerra",
"author_id": 2797,
"author_profile": "https://Stackoverflow.com/users/2797",
"pm_score": 1,
"selected": false,
"text": "typedef typename std::vector<T>::iterator MyIterator;\n vector<T> size_type typename"
},
{
"answer_id":... | 2008/10/01 | [
"https://Stackoverflow.com/questions/156936",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/2166173/"
] |
156,941 | <p>I have a scenario like this which I want to use capistrano to deploy my ruby on rails application:</p>
<ol>
<li>The web application is on a thin cluster with the config file stored under /etc/thin. also an init script is in /etc/init.d/thin, so it would start automatically whenever my server needs a reboot</li>
<li... | [
{
"answer_id": 156957,
"author": "Dre",
"author_id": 23033,
"author_profile": "https://Stackoverflow.com/users/23033",
"pm_score": 2,
"selected": false,
"text": "someuser ALL=NOPASSWD: /etc/init.d/apache2\n $ sudo ls\n[sudo] password for someuser: \nSorry, user someuser is not allowed to... | 2008/10/01 | [
"https://Stackoverflow.com/questions/156941",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/16371/"
] |
156,954 | <p>I need something in between a full text search and an index search:<br>
I want to search for text in one column of my table (probably there will be an index on the column, too, if that matters).</p>
<p>Problem is, I want to search for words in the column, but I don't want to match parts. </p>
<p>For example, my c... | [
{
"answer_id": 156978,
"author": "Biri",
"author_id": 968,
"author_profile": "https://Stackoverflow.com/users/968",
"pm_score": 2,
"selected": false,
"text": "where BusinessName like 'Break%' -- to find if it is beginning with the word\nor BusinessName like '% Break%' -- to find if it co... | 2008/10/01 | [
"https://Stackoverflow.com/questions/156954",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/7021/"
] |
156,975 | <p>I have a JLabel (actually, it is a JXLabel).</p>
<p>I have put an icon and text on it.</p>
<p><code><icon><text></code></p>
<p>Now I wand to add some spacing on the left side of the component, like this:</p>
<p><code><space><icon><text></code></p>
<p>I DON'T accept suggestion to mo... | [
{
"answer_id": 157017,
"author": "rjohnston",
"author_id": 246,
"author_profile": "https://Stackoverflow.com/users/246",
"pm_score": 2,
"selected": false,
"text": "JPanel panel = new JPanel();\npanel.setLayoutManager(new BoxLayout(panel, BoxLayout.LINE_AXIS);\n\npanel.add(new JLabel(\"th... | 2008/10/01 | [
"https://Stackoverflow.com/questions/156975",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/15173/"
] |
156,994 | <p>I'm running MySQL 5 on a linux server on my local network. Running windows XP for my desktop. Had a look at the <a href="http://dev.mysql.com/downloads/gui-tools/5.0.html" rel="nofollow noreferrer">MySQL GUI Tools</a> but I dont think they help. I cannot install apache on the remote server & use something like... | [
{
"answer_id": 157066,
"author": "Liam",
"author_id": 18333,
"author_profile": "https://Stackoverflow.com/users/18333",
"pm_score": 1,
"selected": false,
"text": "insert into tablename values(' '',' '');"
},
{
"answer_id": 160585,
"author": "Gareth",
"author_id": 24352,
... | 2008/10/01 | [
"https://Stackoverflow.com/questions/156994",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/6828/"
] |
157,005 | <p>In HTML forms, buttons can be disabled by defining the "disabled" attribute on them, with any value:</p>
<pre><code><button name="btn1" disabled="disabled">Hello</button>
</code></pre>
<p>If a button is to be enabled, the attribute should not exist as there is no defined value that the disabled attribu... | [
{
"answer_id": 157064,
"author": "Marcus Downing",
"author_id": 1000,
"author_profile": "https://Stackoverflow.com/users/1000",
"pm_score": -1,
"selected": false,
"text": "<% if (isDisabled) { %>\n <button name=\"btn1\" disabled=\"disabled\">Hello</button>\n<% } else { %>\n <button nam... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157005",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/24068/"
] |
157,018 | <p>I recently started learning <a href="http://www.gnu.org/software/emacs/" rel="noreferrer">Emacs</a>. I went through the tutorial, read some introductory articles, so far so good.</p>
<p>Now I want to use it for Python development. From what I understand, there are two separate Python modes for Emacs: python-mode.el... | [
{
"answer_id": 4569972,
"author": "seb",
"author_id": 559140,
"author_profile": "https://Stackoverflow.com/users/559140",
"pm_score": 3,
"selected": false,
"text": "__init__.py"
}
] | 2008/10/01 | [
"https://Stackoverflow.com/questions/157018",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/712/"
] |
157,020 | <p>I have an script that falls over if any of the procedures it is trying to create already exists. How can I check/drop if this procedure is already created?</p>
| [
{
"answer_id": 157248,
"author": "Tom H",
"author_id": 5696608,
"author_profile": "https://Stackoverflow.com/users/5696608",
"pm_score": 1,
"selected": false,
"text": "IF EXISTS\n(\n SELECT *\n FROM SYSPROCS\n WHERE SPECIFIC_SCHEMA = ???\n AND SPECIFIC_NAME = ???\n AND... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157020",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] |
157,034 | <p>I have column that contains strings. The strings in that column look like this:</p>
<p>FirstString/SecondString/ThirdString</p>
<p>I need to parse this so I have two values:</p>
<p>Value 1: FirstString/SecondString
Value 2: ThirdString</p>
<p>I could have actually longer strings but I always nee it seperated lik... | [
{
"answer_id": 157135,
"author": "tzot",
"author_id": 6899,
"author_profile": "https://Stackoverflow.com/users/6899",
"pm_score": 2,
"selected": true,
"text": "Left(col, InStrRev(col, \"/\") - 1), Mid(col, InStrRev(col, \"/\") + 1) \n last_index= InStrRev(your_string, \"/\")\n\nfirst_par... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157034",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/17744/"
] |
157,039 | <p>I have an iterable of entries on which I would like to gather some simple statistics, say the count of all numbers divisible by two and the count of all numbers divisible by three.</p>
<p>My first alternative, While only iterating through the list once and avoiding the list expansion (and keeping the <a href="http:... | [
{
"answer_id": 157080,
"author": "David Webb",
"author_id": 3171,
"author_profile": "https://Stackoverflow.com/users/3171",
"pm_score": 2,
"selected": false,
"text": "filter r = xrange(1, 10)\n\ndef is_div_two(n):\n return n % 2 == 0\n\ndef is_div_three(n):\n return n % 3 == 0\n\np... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157039",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/2010/"
] |
157,044 | <p>I'm attempting to check for the existence of a node using the following .NET code:</p>
<pre><code>xmlDocument.SelectSingleNode(
String.Format("//ErrorTable/ProjectName/text()='{0}'", projectName));
</code></pre>
<p>This always raises:</p>
<blockquote>
<p>XPathException: Expression must evaluate to a nod... | [
{
"answer_id": 157085,
"author": "rjohnston",
"author_id": 246,
"author_profile": "https://Stackoverflow.com/users/246",
"pm_score": 1,
"selected": false,
"text": "Node node = xmlDocument.SelectSingleNode(String.Format(\"//ErrorTable/ProjectName = '{0}'\", projectName));\n\nif (node != n... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157044",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/6651/"
] |
157,058 | <p>I have a list of tuples eg. [{1,40},{2,45},{3,54}....{7,23}] where 1...7 are days of the week (calculated by finding calendar:day_of_the_week()). So now I want to change the list to [{Mon,40},{Tue,45},{Wed,54}...{Sun,23}]. Is there an easier way to do it than lists:keyreplace?</p>
| [
{
"answer_id": 157112,
"author": "Jon Gretar",
"author_id": 5601,
"author_profile": "https://Stackoverflow.com/users/5601",
"pm_score": 3,
"selected": true,
"text": "lists:map(fun({A,B}) -> {httpd_util:day(A),B} end, [{1,40},{2,45},{3,54},{7,23}]).\n"
},
{
"answer_id": 173536,
... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157058",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/2727/"
] |
157,070 | <p>When you're adding javaDoc comments to your code and you're outlining the structure of an XML document that you're passing back, what's the best way to represent attributes? Is there a best practice for this?</p>
<p>My general structure for my javaDoc comments is like this:</p>
<pre><code>/**
* ...
*
* @return... | [
{
"answer_id": 166205,
"author": "Philip Morton",
"author_id": 21709,
"author_profile": "https://Stackoverflow.com/users/21709",
"pm_score": 0,
"selected": false,
"text": "/**\n * ...\n * \n * @return XML document in the form:\n * \n * <pre>\n * <ROOT_ELEMENT>\n * <AN_ELEMENT... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157070",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/21709/"
] |
157,101 | <p>I downloaded some example code from the internet, but when I compiled it I ran into some trouble. My compiler tells me: comdef.h: No such file or directory.</p>
<p>I searched a bit on the internet, but I couldn't find anyone else with the same problem and I have no clue where I can obtain this header file.</p>
<p>... | [
{
"answer_id": 157154,
"author": "C. K. Young",
"author_id": 13,
"author_profile": "https://Stackoverflow.com/users/13",
"pm_score": 2,
"selected": false,
"text": "comdef.h #import"
}
] | 2008/10/01 | [
"https://Stackoverflow.com/questions/157101",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/23163/"
] |
157,114 | <p>I made a view to abstract columns of different tables and pre-filter and pre-sort them. There is one column whose content I don't care about but I need to know whether the content is null or not. So my view should pass an alias as "<em>true</em>" in case the value of this specified column <strong>isn't null</strong>... | [
{
"answer_id": 157136,
"author": "Adam Bellaire",
"author_id": 21632,
"author_profile": "https://Stackoverflow.com/users/21632",
"pm_score": 7,
"selected": true,
"text": "SELECT CASE WHEN columnName IS NULL THEN 'false' ELSE 'true' END FROM tableName;\n"
},
{
"answer_id": 157148,... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157114",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/5703/"
] |
157,117 | <p>We have a strange problem occurring <em>once in a while</em> on our servers. It usually happens when one or more of our web applications are upgraded. Debugging the problem has gotten me this far...</p>
<p>During the processing of a request:</p>
<ul>
<li>In the ASP.NET application we put an object in session</li>
... | [
{
"answer_id": 157140,
"author": "Eduardo Molteni",
"author_id": 2385,
"author_profile": "https://Stackoverflow.com/users/2385",
"pm_score": 0,
"selected": false,
"text": "If Not IsNothing(Context.Session) Then\n 'do something\nend if\n"
}
] | 2008/10/01 | [
"https://Stackoverflow.com/questions/157117",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/22621/"
] |
157,119 | <p>As far as i know it is not possible to do the following in C# 2.0</p>
<pre><code>public class Father
{
public virtual Father SomePropertyName
{
get
{
return this;
}
}
}
public class Child : Father
{
public override Child SomePropertyName
{
get
... | [
{
"answer_id": 157128,
"author": "Anthony",
"author_id": 5599,
"author_profile": "https://Stackoverflow.com/users/5599",
"pm_score": 1,
"selected": false,
"text": "public class FatherProp\n{\n}\n\npublic class ChildProp: FatherProp\n{\n}\n\n\npublic class Father\n{\n public virtual Fa... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157119",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20335/"
] |
157,132 | <p>I'd like to limit the size of the file that can be uploaded to an application. To achieve this, I'd like to abort the upload process from the server side when the size of the file being uploaded exceeds a limit.</p>
<p>Is there a way to abort an upload process from the server side without waiting the HTTP request t... | [
{
"answer_id": 157188,
"author": "Nikhil Kashyap",
"author_id": 11299,
"author_profile": "https://Stackoverflow.com/users/11299",
"pm_score": 1,
"selected": false,
"text": "multi = new MultipartRequest(request, dirName, FILE_SIZE_LIMIT); \n\nif(submitButton.equals(multi.getParameter(\"Su... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157132",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/686/"
] |
157,149 | <p>Is it possible to split the information in a .csproj across more than one file? A bit like a project version of the <code>partial class</code> feature.</p>
| [
{
"answer_id": 157175,
"author": "Jorge Ferreira",
"author_id": 6508,
"author_profile": "https://Stackoverflow.com/users/6508",
"pm_score": 6,
"selected": true,
"text": "<Project DefaultTargets=\"Build\" xmlns=\"http://schemas.microsoft.com/developer/msbuild/2003\">\n ....\n</Project>... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157149",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/24092/"
] |
157,163 | <p>I want to run a command as soon as a certain text appears in a log file. How do I do that in Bash?</p>
| [
{
"answer_id": 157171,
"author": "ketorin",
"author_id": 24094,
"author_profile": "https://Stackoverflow.com/users/24094",
"pm_score": 5,
"selected": true,
"text": "tail -f file.log | grep --line-buffered \"my pattern\" | while read line\ndo\n echo $line\ndone\n --line-buffered"
},
... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157163",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/24094/"
] |
157,178 | <p>I still very new using Subversion.</p>
<p>Is it possible to have a working copy on a network available share (c:\svn\projects\website) that everyone (in this case 3 of use) can checkout and commit files to? We don't need a build server because it is an asp site and the designers are used to having immediate results... | [
{
"answer_id": 157290,
"author": "Rinat Abdullin",
"author_id": 47366,
"author_profile": "https://Stackoverflow.com/users/47366",
"pm_score": 2,
"selected": false,
"text": "[general]\npassword-db = userfile\nrealm = example realm\n\n# anonymous users can only read the repository\nanon-ac... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157178",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/3747/"
] |
157,195 | <p>Anybody knows how to do this? I got all the information of the email (body, subject, from , to, cc, bcc) and need to generate an .eml file out of it.</p>
| [
{
"answer_id": 157229,
"author": "Neall",
"author_id": 619,
"author_profile": "https://Stackoverflow.com/users/619",
"pm_score": 3,
"selected": false,
"text": "From: \"DR CLEMENT OKON\" <drclement@nigerianspam.com>\nTo: \"You\" <you@yourdomain.com>\nSubject: REQUEST FOR URGENT BUSINESS R... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157195",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/6200/"
] |
157,198 | <p>I was reading <a href="http://www.ibm.com/developerworks/java/library/j-dcl.html" rel="nofollow noreferrer">this article</a> about "Double-Checked locking" and out of the main topic of the article I was wondering why at some point of the article the author uses the next Idiom: </p>
<blockquote>
<p>Listing 7. Att... | [
{
"answer_id": 157240,
"author": "David Santamaria",
"author_id": 24097,
"author_profile": "https://Stackoverflow.com/users/24097",
"pm_score": 0,
"selected": false,
"text": "public static Singleton getInstance()\n{\n if (instance == null)\n {\n synchronized(Singleton.class) { ... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157198",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/24097/"
] |
157,208 | <p>I would like to send HTML email with graphic elements included. I have no idea to attach garaphics to this email.</p>
| [
{
"answer_id": 160804,
"author": "acrosman",
"author_id": 24215,
"author_profile": "https://Stackoverflow.com/users/24215",
"pm_score": 2,
"selected": false,
"text": " $headers = \"From: sender@example.com\\n\" .\n \"MIME-Version: 1.0\\n\" .\n \"Content-type: text/html; charset=iso... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157208",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] |
157,232 | <p>I have wrapped Log4net in a static wrapper and want to log </p>
<pre><code>loggingEvent.LocationInformation.MethodName
loggingEvent.LocationInformation.ClassName
</code></pre>
<p>However all I get is the name of my wrapper.</p>
<p>How can I log that info using a forwardingappender and a static wrapper class li... | [
{
"answer_id": 157891,
"author": "Claus Thomsen",
"author_id": 15555,
"author_profile": "https://Stackoverflow.com/users/15555",
"pm_score": 6,
"selected": true,
"text": " public static class Logger\n {\n private readonly static Type ThisDeclaringType = typeof(Logger);\n private st... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157232",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/15555/"
] |
157,254 | <p>Image a Button on your windows form that does something when being clicked.</p>
<p>The click events thats raised is typically bound to a method such as</p>
<blockquote>
<p>protected void Button1_Click(object
sender, EventArgs e) {</p>
<p>}</p>
</blockquote>
<p>What I see sometimes in other peoples' code ... | [
{
"answer_id": 157291,
"author": "Jon Skeet",
"author_id": 22656,
"author_profile": "https://Stackoverflow.com/users/22656",
"pm_score": 1,
"selected": false,
"text": "button1.Click += delegate { DoStuff(); }\n"
}
] | 2008/10/01 | [
"https://Stackoverflow.com/questions/157254",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/23369/"
] |
157,260 | <p>In the past and with most my current projects I tend to use a for loop like this:</p>
<pre><code>var elements = document.getElementsByTagName('div');
for (var i=0; i<elements.length; i++) {
doSomething(elements[i]);
}
</code></pre>
<p>I've heard that using a "reverse while" loop is quicker but I have no rea... | [
{
"answer_id": 157264,
"author": "Per Hornshøj-Schierbeck",
"author_id": 11619,
"author_profile": "https://Stackoverflow.com/users/11619",
"pm_score": 3,
"selected": false,
"text": ".forEach"
},
{
"answer_id": 157286,
"author": "roenving",
"author_id": 23142,
"author_... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157260",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/21677/"
] |
157,272 | <p>We have a database that we are using to store test results for an embedded device. There's a table with columns for different types of failures (details not relevant), along with a primary key 'keynum' and a 'NUM_FAILURES' column that lists the number of failures. We store passes and failures, so a pass has a '0' ... | [
{
"answer_id": 157285,
"author": "mbyrne215",
"author_id": 5241,
"author_profile": "https://Stackoverflow.com/users/5241",
"pm_score": 0,
"selected": false,
"text": "CREATE VIEW tablename_view AS SELECT keynum FROM tablename WHERE NUM_FAILURES!='0' \n ORDER BY keynum DESC LIMIT 50;\nC... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157272",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/5241/"
] |
157,294 | <p>We have a project consisting of multiple subprojects. With each subproject we potentially have some hibernate mapping files but in the end only <strong>one actual hibernate session</strong>. Those subprojects could be combined in several ways, some depend on each other. My problem is that actually I want to have a S... | [
{
"answer_id": 157338,
"author": "skaffman",
"author_id": 21234,
"author_profile": "https://Stackoverflow.com/users/21234",
"pm_score": 0,
"selected": false,
"text": "LocalSessionFactoryBean"
}
] | 2008/10/01 | [
"https://Stackoverflow.com/questions/157294",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/917/"
] |
157,318 | <p>We are using a PHP scripting for tunnelling file downloads, since we don't want to expose the absolute path of downloadable file:</p>
<pre><code>header("Content-Type: $ctype");
header("Content-Length: " . filesize($file));
header("Content-Disposition: attachment; filename=\"$fileName\"");
readfile($file);
</code></... | [
{
"answer_id": 157352,
"author": "Sietse",
"author_id": 6400,
"author_profile": "https://Stackoverflow.com/users/6400",
"pm_score": 4,
"selected": false,
"text": "Range"
},
{
"answer_id": 157355,
"author": "Mike Dimmick",
"author_id": 6970,
"author_profile": "https://... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157318",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] |
157,342 | <p>Cron installation is vixie-cron</p>
<p><code>/etc/cron.daily/rmspam.cron</code></p>
<pre><code>#!/bin/bash
/usr/bin/rm /home/user/Maildir/.SPAM/cur/*;
</code></pre>
<p>I Have this simple bash script that I want to add to a cron job (also includes spam learning commands before) but this part always fails with "Fil... | [
{
"answer_id": 157350,
"author": "Mark Biek",
"author_id": 305,
"author_profile": "https://Stackoverflow.com/users/305",
"pm_score": 0,
"selected": false,
"text": "00 3 * * * /home/me/myscript.sh\n 00 3 * * * myscript.sh\n"
},
{
"answer_id": 157369,
"author": "janm",
"aut... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157342",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/4275/"
] |
157,354 | <p>I happened to debate with a friend during college days whether advanced mathematics is necessary for any veteran programmer. He used to argue fiercely against that. He said that programmers need only basic mathematical knowledge from high school or fresh year college math, no more no less, and that almost all of pro... | [
{
"answer_id": 2367748,
"author": "Earlz",
"author_id": 69742,
"author_profile": "https://Stackoverflow.com/users/69742",
"pm_score": 2,
"selected": false,
"text": "(x|y) & (x|z) & (x|foo)\n x | (y & z & foo)\n"
},
{
"answer_id": 2367840,
"author": "Arun",
"author_id": 27... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157354",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/24113/"
] |
157,357 | <p>Is there a way to use form fields that does not correspond to database field for temporary processings?</p>
<p>I.e. I want to add:</p>
<ul>
<li>temp fields <strong>item1</strong>, <strong>item2</strong></li>
<li>database field <strong>sum</strong></li>
<li>button with record hook that sets <strong>sum</strong> = <... | [
{
"answer_id": 971132,
"author": "Randakar",
"author_id": 36574,
"author_profile": "https://Stackoverflow.com/users/36574",
"pm_score": 2,
"selected": false,
"text": "$session->SetNameValue(\"item1\", $value1);\n$session->SetNameValue(\"item2\", $value2);\n my $item1 = GetNameValue(\"ite... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157357",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/3448/"
] |
157,359 | <p>I've been building an error logging app recently and was after a way of accurately timestamping the incoming data. When I say accurately I mean each timestamp should be accurate relative to each other (no need to sync to an atomic clock or anything like that).</p>
<p>I've been using datetime.now() as a first stab, ... | [
{
"answer_id": 157711,
"author": "Brian",
"author_id": 9493,
"author_profile": "https://Stackoverflow.com/users/9493",
"pm_score": 4,
"selected": true,
"text": " class TimeStamper(object):\n def __init__(self):\n self.lock = threading.Lock()\n self.prev = ... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157359",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/15369/"
] |
157,392 | <p>I want to find out, with an SQL query, whether an index is UNIQUE or not. I'm using SQLite 3.</p>
<p>I have tried two approaches:</p>
<pre><code>SELECT * FROM sqlite_master WHERE name = 'sqlite_autoindex_user_1'
</code></pre>
<p>This returns information about the index ("type", "name", "tbl_name", "rootpage" and ... | [
{
"answer_id": 157636,
"author": "dland",
"author_id": 18625,
"author_profile": "https://Stackoverflow.com/users/18625",
"pm_score": 2,
"selected": false,
"text": "select count(*) from t\ngroup by foo, bar, baz\nhaving count(*) > 1\n select count(*) from (\n select count(*) from t\n ... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157392",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/12534/"
] |
157,424 | <p>I have a dictionary of 200,000 items (the keys are strings and the values are integers).</p>
<p>What is the best/most pythonic way to print the items sorted by descending value then ascending key (i.e. a 2 key sort)?</p>
<pre><code> a={ 'keyC':1, 'keyB':2, 'keyA':1 }
b = a.items()
b.sort( key=lambda a:a[0])
b.sort... | [
{
"answer_id": 157445,
"author": "S.Lott",
"author_id": 10661,
"author_profile": "https://Stackoverflow.com/users/10661",
"pm_score": 5,
"selected": true,
"text": "a = { 'key':1, 'another':2, 'key2':1 }\n\nb= a.items()\nb.sort( key=lambda a:(-a[1],a[0]) )\nprint b\n def valueKeyCmp( a, b... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157424",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] |
157,459 | <p>I have a products table...</p>
<p><a href="http://img357.imageshack.us/img357/6393/productscx5.gif" rel="nofollow noreferrer">alt text http://img357.imageshack.us/img357/6393/productscx5.gif</a></p>
<p>and a revisions table, which is supposed to track changes to product info</p>
<p><a href="http://img124.imagesha... | [
{
"answer_id": 159621,
"author": "Bill Karwin",
"author_id": 20860,
"author_profile": "https://Stackoverflow.com/users/20860",
"pm_score": 3,
"selected": true,
"text": "SELECT p.*, r.*\nFROM products AS p\n JOIN revisions AS r USING (product_id)\n LEFT OUTER JOIN revisions AS r2 \n ... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157459",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/18856/"
] |
157,480 | <p>How can this line in Java be translated to Ruby:<br>
String className = "java.util.Vector";<br>
...<br>
Object o = Class.forName(className).newInstance(); </p>
<p>Thanks!</p>
| [
{
"answer_id": 157499,
"author": "Ken",
"author_id": 20621,
"author_profile": "https://Stackoverflow.com/users/20621",
"pm_score": 7,
"selected": true,
"text": "Object::const_get('String').new()\n"
},
{
"answer_id": 158145,
"author": "Ian Terrell",
"author_id": 9269,
... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157480",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] |
157,504 | <p>I have object A which in turn has a property of type Object B</p>
<pre><code>Class A
property x as Object B
End Class
</code></pre>
<p>On my ASP.NET page when I select a gridview item which maps to an object of type A I serialize the object onto the QueryString and pass it to the next page. </p>
<p>However I ru... | [
{
"answer_id": 157593,
"author": "Ben Scheirman",
"author_id": 3381,
"author_profile": "https://Stackoverflow.com/users/3381",
"pm_score": 1,
"selected": false,
"text": "public void Page_Load()\n{\n\n if(!IsPostBack)\n { \n const string key = \"FunkyObject\";\n if(S... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157504",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/11802/"
] |
157,511 | <p>I have a <code>Dictionary<string, someobject></code>.</p>
<p>EDIT: It was pointed out to me, that my example was bad. My whole intention was not to update the references in a loop but to update different values based on differnt threads need to update/get the data. I changed the loop to a method.</p>
<p>I ne... | [
{
"answer_id": 157536,
"author": "Sander",
"author_id": 2928,
"author_profile": "https://Stackoverflow.com/users/2928",
"pm_score": 3,
"selected": false,
"text": "string a = \"Something\";\nstring b = \"Something\";\n class Something\n{\n bool threadSafeBool = true;\n object thread... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157511",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/11619/"
] |
157,528 | <p>As in a title, does anyone know how to freeze GridView header in ASP.NET ? </p>
| [
{
"answer_id": 157606,
"author": "Galwegian",
"author_id": 3201,
"author_profile": "https://Stackoverflow.com/users/3201",
"pm_score": 2,
"selected": false,
"text": ".Freezing\n{\n position:relative ;\n top:expression(this.offsetParent.scrollTop);\n z-index: 10;\n} \n"
},
{
... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157528",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/3182/"
] |
157,554 | <p>I've got a XmlNodeList which I need to have it in a format that I can then re-use within a XSLT stylesheet by calling it from a C# extension method.</p>
<p>Can anyone help? I have read that it might have something to do with using a XPathNavigator but I'm still a bit stuck.</p>
| [
{
"answer_id": 157624,
"author": "Jeff Yates",
"author_id": 23234,
"author_profile": "https://Stackoverflow.com/users/23234",
"pm_score": 4,
"selected": true,
"text": "XsltArgumentList arguments = new XsltArgumentList();\nXmlNodeList nodelist;\nXmlDocument nodesFrament = new XmlDocument(... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157554",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/4455/"
] |
157,557 | <p>In VB.Net, I can declare a variable in a function as Static, like this:</p>
<pre><code>Function EncodeForXml(ByVal data As String) As String
Static badAmpersand As Regex = new Regex("&(?![a-zA-Z]{2,6};|#[0-9]{2,4};)")
data = badAmpersand.Replace(data, "&amp;")
''// more processing
return ... | [
{
"answer_id": 157575,
"author": "Joel Coehoorn",
"author_id": 3043,
"author_profile": "https://Stackoverflow.com/users/3043",
"pm_score": 5,
"selected": true,
"text": "Monitor"
},
{
"answer_id": 157733,
"author": "Rinat Abdullin",
"author_id": 47366,
"author_profile"... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157557",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/3043/"
] |
157,600 | <p>I would like to receive suggestions on the data generators that are available, for SQL server. If posting a response, please provide any features that you think are important. </p>
<p>I have never used a application like this, so I am looking to be educated on the topic. Thank you.</p>
<p>(My goal is to fill a dat... | [
{
"answer_id": 157688,
"author": "S.Lott",
"author_id": 10661,
"author_profile": "https://Stackoverflow.com/users/10661",
"pm_score": 3,
"selected": false,
"text": "import csv\nimport random\n\nclass SomeEntity( list ):\n titles = ( 'attr1', 'attr2' ) # ... for all columns\n def __... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157600",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/19854/"
] |
157,603 | <p>I'm using VisualSVN Server to host an SVN repo, and for some automation work, I'd like to be able to get specific versions via the http[s] layer.</p>
<p>I can get the HEAD version simply via an http[s] request to the server (httpd?) - but is there any ability to specify the revision, perhaps as a query-string? I ca... | [
{
"answer_id": 157726,
"author": "Bert Huijben",
"author_id": 2094,
"author_profile": "https://Stackoverflow.com/users/2094",
"pm_score": 2,
"selected": false,
"text": "using (SvnClient client = new SvnClient())\nusing (FileStream fs = File.Create(\"c:\\\\temp\\\\file.txt\"))\n{\n // ... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157603",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/23354/"
] |
157,628 | <p>I have a helper method has been created which allows a MovieClip-based class in code and have the constructor called. Unfortunately the solution is not complete because the MovieClip callback <b>onLoad()</b> is never called. </p>
<p>(Link to the <a href="http://www.flashdevelop.org/community/viewtopic.php?f=13&... | [
{
"answer_id": 164928,
"author": "Luke",
"author_id": 21406,
"author_profile": "https://Stackoverflow.com/users/21406",
"pm_score": 2,
"selected": false,
"text": "import mx.events.EventDispatcher;\n\nclass com.tequila.common.View extends MovieClip\n{\n private static var _symbolClass ... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157628",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/14747/"
] |
157,629 | <p>Hi im new to MVC and I've fished around with no luck on how to build MVC User Controls that have ViewData returned to them. I was hoping someone would post a step by step solution on how to approach this problem. If you could make your solution very detailed that would help out greatly.</p>
<p>Sorry for being so di... | [
{
"answer_id": 157743,
"author": "stimms",
"author_id": 361,
"author_profile": "https://Stackoverflow.com/users/361",
"pm_score": 0,
"selected": false,
"text": "<%Html.RenderPartial(\"~/UserControls/CategoryChooser.ascx\", ViewData);%>\n"
},
{
"answer_id": 157745,
"author": "... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157629",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/24130/"
] |
157,646 | <p>I was looking for a generic method in .Net to encode a string for use in an Xml element or attribute, and was surprised when I didn't immediately find one. So, before I go too much further, could I just be missing the built-in function? </p>
<p>Assuming for a moment that it really doesn't exist, I'm putting toget... | [
{
"answer_id": 157674,
"author": "GSerg",
"author_id": 11683,
"author_profile": "https://Stackoverflow.com/users/11683",
"pm_score": 3,
"selected": false,
"text": "XmlTextWriter.WriteString()"
},
{
"answer_id": 421938,
"author": "Dscoduc",
"author_id": 51949,
"author_... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157646",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/3043/"
] |
157,661 | <p>Say you have several webparts, one as a controller and several which take information from the controller and act on it. This is fairly easy to model using the Consumer/Producer interface introduced in ASP 2.0. </p>
<p>How would you be able to add interactions the other way around whilst still maintaining the above... | [
{
"answer_id": 159715,
"author": "andrew",
"author_id": 17767,
"author_profile": "https://Stackoverflow.com/users/17767",
"pm_score": 1,
"selected": false,
"text": " private Calendar _calendarWP = null;\n public Calendar CalendarWP\n {\n get\n {\n if (_calend... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157661",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/21299/"
] |
157,685 | <p>I'm trying to change the background color of a single subplot in a MATLAB figure.</p>
<p>It's clearly feasible since the UI allows it, but I cannot find the function to automate it.</p>
<p>I've looked into <code>whitebg</code>, but it changes the color scheme of the whole figure, not just the current subplot. </p>... | [
{
"answer_id": 157719,
"author": "Douglas F Shearer",
"author_id": 13831,
"author_profile": "https://Stackoverflow.com/users/13831",
"pm_score": 2,
"selected": false,
"text": "subplot(3, 2, 4), hist(rand(50)), whitebg('y');\n"
},
{
"answer_id": 157725,
"author": "Doug Trojan"... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157685",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/8027/"
] |
157,689 | <p>How do I use the ofstream to write text to the end of a file without erasing its content inside?</p>
| [
{
"answer_id": 157698,
"author": "Konrad Rudolph",
"author_id": 1968,
"author_profile": "https://Stackoverflow.com/users/1968",
"pm_score": 3,
"selected": false,
"text": "ios::app ofstream ofs(\"filename\", ios::app);\n"
},
{
"answer_id": 1488730,
"author": "Nona Urbiz",
... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157689",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] |
157,705 | <p>I've got some XML, for example purposes it looks like this:</p>
<pre><code><root>
<field1>test</field1>
<f2>t2</f2>
<f2>t3</f2>
</root>
</code></pre>
<p>I want to transform it with XSLT, but I want to suppress the second f2 element in the output - how do ... | [
{
"answer_id": 158125,
"author": "samjudson",
"author_id": 1908,
"author_profile": "https://Stackoverflow.com/users/1908",
"pm_score": 4,
"selected": true,
"text": "<xsl:if test=\"count(preceding-sibling::node()[name()=name(current())])=0\">\n ... do stuff in here.\n</xsl:if>\n"
},
... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157705",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/22073/"
] |
157,737 | <p>Which Ajax framework/toolkit can you recommend for building the GUI of web applications that are using struts?</p>
| [
{
"answer_id": 963263,
"author": "Richard Clayton",
"author_id": 118885,
"author_profile": "https://Stackoverflow.com/users/118885",
"pm_score": 0,
"selected": false,
"text": "<author name=\"Boynton\">\n <book>\n <title>Barnyard Dance!</title>\n <year>1993</year>\n </book>\n <bo... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157737",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] |
157,747 | <p>I want to use VBScript to catch errors and log them (ie on error "log something") then resume the next line of the script.</p>
<p>For example,</p>
<pre>
On Error Resume Next
'Do Step 1
'Do Step 2
'Do Step 3
</pre>
<p>When an error occurs on step 1, I want it to log that error (or perform other custom functions wi... | [
{
"answer_id": 157785,
"author": "Dylan Beattie",
"author_id": 5017,
"author_profile": "https://Stackoverflow.com/users/5017",
"pm_score": 8,
"selected": true,
"text": "On Error Resume Next\n\nDoStep1\n\nIf Err.Number <> 0 Then\n WScript.Echo \"Error in DoStep1: \" & Err.Description\n ... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157747",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/6128/"
] |
157,759 | <p>I have a program which needs to behave slightly differently on Tiger than on Leopard. Does anybody know of a system call which will allow me to accurately determine which version of Mac OS X I am running. I have found a number of macro definitions to determine the OS of the build machine, but nothing really good to ... | [
{
"answer_id": 157784,
"author": "Douglas F Shearer",
"author_id": 13831,
"author_profile": "https://Stackoverflow.com/users/13831",
"pm_score": 3,
"selected": false,
"text": "system_profiler SPSoftwareDataType\n Software:\n\n System Software Overview:\n\n System Version: Mac OS ... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157759",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/7587/"
] |
157,770 | <p>I'm trying to format a column in a <code><table/></code> using a <code><col/></code> element. I can set <code>background-color</code>, <code>width</code>, etc., but can't set the <code>font-weight</code>. Why doesn't it work?</p>
<pre><code><table>
<col style="font-weight:bold; background-c... | [
{
"answer_id": 157798,
"author": "Philip Morton",
"author_id": 21709,
"author_profile": "https://Stackoverflow.com/users/21709",
"pm_score": -1,
"selected": false,
"text": "col colgroup"
},
{
"answer_id": 157836,
"author": "mwilliams",
"author_id": 23909,
"author_prof... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157770",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/15788/"
] |
157,786 | <p>I am looking for a way in LINQ to match the follow SQL Query.</p>
<pre><code>Select max(uid) as uid, Serial_Number from Table Group BY Serial_Number
</code></pre>
<p>Really looking for some help on this one. The above query gets the max uid of each Serial Number because of the <code>Group By</code> Syntax.</p>
| [
{
"answer_id": 157919,
"author": "tvanfosson",
"author_id": 12950,
"author_profile": "https://Stackoverflow.com/users/12950",
"pm_score": 8,
"selected": true,
"text": " using (DataContext dc = new DataContext())\n {\n var q = from t in dc.TableTests\n ... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157786",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/7644/"
] |
157,795 | <p>Windows Forms allows you to develop Components, non-visual elements that can have a designer. Built-in components include the BackgroundWorker, Timer, and a lot of ADO .NET objects. It's a nice way to provide easy configuration of a complicated object, and it it enables designer-assisted data binding.</p>
<p>I've... | [
{
"answer_id": 507163,
"author": "Nir",
"author_id": 3509,
"author_profile": "https://Stackoverflow.com/users/3509",
"pm_score": 1,
"selected": false,
"text": "<Window x:Class=\"MyApp.Window1\"\n xmlns:sys=\"clr-namespace:System;assembly=mscorlib\"\n xmlns=\"http://schemas.microso... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157795",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/2547/"
] |
157,807 | <p>If you have an API, and you are a UK-based developer with a highly international audience, should your API be </p>
<pre><code>setColour()
</code></pre>
<p>or</p>
<pre><code>setColor()
</code></pre>
<p>(To take one word as a simple example.)</p>
<p>UK-based engineers are often quite defensive about their 'correc... | [
{
"answer_id": 157841,
"author": "Konrad Rudolph",
"author_id": 1968,
"author_profile": "https://Stackoverflow.com/users/1968",
"pm_score": 6,
"selected": false,
"text": "en-gb en-us"
},
{
"answer_id": 157874,
"author": "Carl",
"author_id": 951280,
"author_profile": "... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157807",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/974/"
] |
157,812 | <p>I have a field on a table in MS Access, tblMyTable.SomeID, and I want to set the default value as a user preference in tblUserPref.DefaultSomeID. It doesn't appear that I can set the default value to use a query in the table definition of tblMyTable. I have a form where records are entered into tblMyTable. I've t... | [
{
"answer_id": 157849,
"author": "BIBD",
"author_id": 685,
"author_profile": "https://Stackoverflow.com/users/685",
"pm_score": 0,
"selected": false,
"text": "Private Sub Form_Current()\n If Me.NewRecord Then\n Me.f2 = \"humbug\"\n End If\nEnd Sub\n"
},
{
"answer_id"... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157812",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/2192597/"
] |
157,827 | <p>My code needs to run all networking routines in a separate NSThread.
I have got a library, which I pass a callback routine for communication:</p>
<pre><code>my thread code
library
my callback (networking)
library
my thread code
</code></pre>
<p>My callback routine must POST some data to an HTTP ser... | [
{
"answer_id": 171745,
"author": "Community",
"author_id": -1,
"author_profile": "https://Stackoverflow.com/users/-1",
"pm_score": 1,
"selected": false,
"text": "+[NSURLConnection sendSynchronousRequest:returningResponse:error:] NSURLRequest NSRunLoop"
},
{
"answer_id": 688186,
... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157827",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/8030/"
] |
157,832 | <p>This is sort of SQL newbie question, I think, but here goes.</p>
<p>I have a SQL Query (SQL Server 2005) that I've put together based on an example user-defined function:</p>
<pre><code>SELECT
CASEID,
GetNoteText(CASEID)
FROM
(
SELECT
CASEID
FROM
ATTACHMENTS
GROUP BY
... | [
{
"answer_id": 157907,
"author": "Gordon Bell",
"author_id": 16473,
"author_profile": "https://Stackoverflow.com/users/16473",
"pm_score": 3,
"selected": false,
"text": "SELECT \n c.CASEID, c.CASE_NAME,\n a.COUNT AS ATTACHMENTSCOUNT, o.COUNT as OTHERCOUNT,\n dbo.GetNoteText(c.CA... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157832",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/8151/"
] |
157,846 | <p>What is the benefit of using the servletContext as opposed the request in order to obtain a requestDispatcher?</p>
<pre><code>servletContext.getRequestDispatcher(dispatchPath)
</code></pre>
<p>and using </p>
<pre><code>argRequest.getRequestDispatcher(dispatchPath)
</code></pre>
| [
{
"answer_id": 3679333,
"author": "kalyan",
"author_id": 443714,
"author_profile": "https://Stackoverflow.com/users/443714",
"pm_score": 1,
"selected": false,
"text": "getRequestDispatcher ServletContext ServletRequest"
}
] | 2008/10/01 | [
"https://Stackoverflow.com/questions/157846",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] |
157,850 | <p>In a C# Web app, VS 2005 (I am avoiding 2008 because I find the IDE to be hard to deal with), I am getting into a layout stew.</p>
<p>I am moving from absolute positioning toward CSS relative positioning.</p>
<p>I'd like to divide the screen into four blocks: top (header band), middle left (a stacked menu), middle... | [
{
"answer_id": 159349,
"author": "roryf",
"author_id": 270,
"author_profile": "https://Stackoverflow.com/users/270",
"pm_score": 1,
"selected": false,
"text": "position: relative; UserControl aspx"
}
] | 2008/10/01 | [
"https://Stackoverflow.com/questions/157850",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/-1/"
] |
157,856 | <p>Imagine this sample java class:</p>
<pre><code>class A {
void addListener(Listener obj);
void removeListener(Listener obj);
}
class B {
private A a;
B() {
a = new A();
a.addListener(new Listener() {
void listen() {}
}
}
</code></pre>
<p>Do I need to add a final... | [
{
"answer_id": 157903,
"author": "janm",
"author_id": 7256,
"author_profile": "https://Stackoverflow.com/users/7256",
"pm_score": 4,
"selected": false,
"text": "class A {\n void addListener(Listener obj);\n void removeListener(Listener obj);\n}\n\nclass B {\n private static clas... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157856",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/3657/"
] |
157,873 | <p>I'm having a test hang in our rails app can't figure out which one (since it hangs and doesn't get to the failure report). I found this blog post <a href="http://bmorearty.wordpress.com/2008/06/18/find-tests-more-easily-in-your-testlog/" rel="noreferrer">http://bmorearty.wordpress.com/2008/06/18/find-tests-more-eas... | [
{
"answer_id": 158034,
"author": "Jean",
"author_id": 7898,
"author_profile": "https://Stackoverflow.com/users/7898",
"pm_score": 2,
"selected": false,
"text": "# File test/unit/testcase.rb, line 100\n def setup\n end\n def setup\n log_test\nend \n\nprivate \n\ndef log_test... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157873",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/3041/"
] |
157,905 | <p>The subject says it all, almost. How do I automatically fix jsp pages so that relative URLs are mapped to the context path instead of the server root? That is, given for example</p>
<pre><code><link rel="stylesheet" type="text/css" href="/css/style.css" />
</code></pre>
<p>how do I set-up things in a way tha... | [
{
"answer_id": 157909,
"author": "Community",
"author_id": -1,
"author_profile": "https://Stackoverflow.com/users/-1",
"pm_score": 4,
"selected": true,
"text": "<BASE HREF=\"\"> <BASE HREF=\"http://www.example.com/prefix\"> <a href=\"/link/1.html\"> <LINK>"
}
] | 2008/10/01 | [
"https://Stackoverflow.com/questions/157905",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/6069/"
] |
157,911 | <p>I am trying to add an unhandled exception handler in .net (c#) that should be as helpfull for the 'user' as possible. The end users are mostly programers so they just need a hint of what object are they manipulating wrong.</p>
<p>I'm developing a windows similar to the windows XP error report when an application cr... | [
{
"answer_id": 157973,
"author": "Andrew",
"author_id": 5662,
"author_profile": "https://Stackoverflow.com/users/5662",
"pm_score": 0,
"selected": false,
"text": "KeyNotFoundException Dim sKey as String = \"some-key\"\nDim sValue as String = String.Empty\n\nTry\n sValue = Dictionary(sK... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157911",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/23190/"
] |
157,923 | <p>I've started to "play around" with PowerShell and am trying to get it to "behave".</p>
<p>One of the things I'd like to do is to customize the PROMPT to be "similar" to what "$M$P$_$+$G" do on MS-Dos:</p>
<p>A quick rundown of what these do:</p>
<p><b>Character</b><b>| Description</b><br>
<b>$m </b> The remote n... | [
{
"answer_id": 157991,
"author": "EBGreen",
"author_id": 1358,
"author_profile": "https://Stackoverflow.com/users/1358",
"pm_score": 1,
"selected": false,
"text": "$(get-location -Stack).count\n"
},
{
"answer_id": 158054,
"author": "EBGreen",
"author_id": 1358,
"autho... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157923",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/12344/"
] |
157,933 | <p>I was able to implement a thread-safe Dictionary in C# by deriving from IDictionary and defining a private SyncRoot object:</p>
<pre><code>public class SafeDictionary<TKey, TValue>: IDictionary<TKey, TValue>
{
private readonly object syncRoot = new object();
private Dictionary<TKey, TValue>... | [
{
"answer_id": 158005,
"author": "fryguybob",
"author_id": 4592,
"author_profile": "https://Stackoverflow.com/users/4592",
"pm_score": 6,
"selected": true,
"text": "public class SafeDictionary<TKey, TValue>: IDictionary<TKey, TValue>\n{\n private readonly object syncRoot = new object(... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157933",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/5563/"
] |
157,938 | <p>I have got a python script which is creating an ODBC connection. The ODBC connection is generated with a connection string. In this connection string I have to include the username and password for this connection. </p>
<p>Is there an easy way to obscure this password in the file (just that nobody can read the pas... | [
{
"answer_id": 157975,
"author": "David Webb",
"author_id": 3171,
"author_profile": "https://Stackoverflow.com/users/3171",
"pm_score": 8,
"selected": true,
"text": ">>> import base64\n>>> print(base64.b64encode(\"password\".encode(\"utf-8\")))\ncGFzc3dvcmQ=\n>>> print(base64.b64decode(... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157938",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/3056/"
] |
157,944 | <p>Given an array of type <code>Element[]</code>:</p>
<pre><code>Element[] array = {new Element(1), new Element(2), new Element(3)};
</code></pre>
<p>How do I convert this array into an object of type <a href="https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/util/ArrayList.html" rel="noreferrer"><code>... | [
{
"answer_id": 157950,
"author": "Tom",
"author_id": 22850,
"author_profile": "https://Stackoverflow.com/users/22850",
"pm_score": 13,
"selected": true,
"text": "new ArrayList<>(Arrays.asList(array));\n"
},
{
"answer_id": 157956,
"author": "Bill the Lizard",
"author_id": ... | 2008/10/01 | [
"https://Stackoverflow.com/questions/157944",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/939/"
] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.