Id int64 4 8.51M | PostTypeId int64 1 7 | AcceptedAnswerId int64 7 75.5M ⌀ | ParentId int64 4 41.8M ⌀ | Score int64 -208 27.7k | ViewCount int64 11 12.4M ⌀ | Body stringlengths 0 45k | Title stringlengths 2 150 ⌀ | ContentLicense stringclasses 3
values | FavoriteCount int64 0 225 ⌀ | CreationDate stringdate 2008-07-31 21:42:52 2011-12-14 18:48:47 | LastActivityDate stringdate 2008-08-01 12:19:17 2023-03-05 04:40:26 | LastEditDate stringdate 2008-08-01 13:54:25 2023-03-05 03:12:45 ⌀ | LastEditorUserId int64 -1 21.3M ⌀ | OwnerUserId int64 -1 21.1M ⌀ | Tags listlengths 1 6 ⌀ |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
40,366 | 2 | null | 40,352 | 11 | null | > It was posted before .NET 4 became available, which apparently introduced some optimizations regarding `Type` and thus rendered the information in this answer obsolete. See [this more recent answer](https://stackoverflow.com/a/1438443/240733) for details.
According to [this blog post (from 2006) by Vance Morrison](... | null | CC BY-SA 3.0 | null | 2008-09-02T19:28:14.047 | 2017-04-25T10:23:56.610 | 2017-05-23T11:33:13.533 | -1 | 266 | null |
40,373 | 2 | null | 31,919 | 3 | null | If you using the GAC, you can at least do `iisapp.vbs /a "App Pool Name" /r` instead of `iisreset` (it's quicker to recycle a single app pool than to restart IIS).
| null | CC BY-SA 2.5 | null | 2008-09-02T19:31:37.140 | 2008-09-02T19:31:37.140 | null | null | 4,301 | null |
40,372 | 1 | 40,378 | null | 3 | 10,146 | I need to reformat my machine but I have so many user/passwords stored in FF2 that I just keep putting it off. Yes I know about backing up the entire profile and restoring it. But for some reason my profile has many issues and I want to start fresh with that as well.
Are the username and passwords stored in a text fil... | How can you export the saved username and passwords in FireFox 2? | CC BY-SA 2.5 | 0 | 2008-09-02T19:31:26.190 | 2016-03-21T22:39:38.093 | 2008-09-26T18:57:28.593 | 2,134 | 3,747 | [
"firefox"
] |
40,370 | 2 | null | 40,346 | 21 | null | The venerable [Dr. Dobbs Journal](http://www.ddj.com/) is still pretty good. It covers multiple platforms, and mixes some fairly hard-core technical articles with lighter fare (interviews with notables, a "Developer Diaries" column that profiles regular-Joe (and Jane) developers from a range of fields). If you are empl... | null | CC BY-SA 2.5 | null | 2008-09-02T19:30:40.077 | 2008-09-02T19:30:40.077 | null | null | 3,776 | null |
40,377 | 2 | null | 3,748 | 0 | null | I would go with the file system approach. No need to create or maintain a DB with images, it will save you some major headaches in the long run.
| null | CC BY-SA 2.5 | null | 2008-09-02T19:33:44.860 | 2008-09-02T19:33:44.860 | null | null | 2,140,183 | null |
40,376 | 1 | 41,157 | null | 14 | 7,618 | Is it possible to handle POSIX signals within the Java Virtual Machine?
At least [SIGINT](http://en.wikipedia.org/wiki/SIGINT_(POSIX)) and [SIGKILL](http://en.wikipedia.org/wiki/SIGKILL) should be quite platform independent.
| Handle signals in the Java Virtual Machine | CC BY-SA 2.5 | 0 | 2008-09-02T19:33:15.907 | 2012-10-30T11:47:33.970 | 2008-09-09T23:13:40.527 | -1 | 4,308 | [
"java",
"jvm",
"process",
"posix",
"signals"
] |
40,378 | 2 | null | 40,372 | 3 | null | There is a Firefox add-on called [Password Exporter](https://addons.mozilla.org/en-US/firefox/addon/2848). It can export to XML or CSV files that can be imported in another browser or computer.
| null | CC BY-SA 3.0 | null | 2008-09-02T19:34:09.850 | 2015-06-06T06:06:48.377 | 2015-06-06T06:06:48.377 | 478,656 | 720 | null |
40,379 | 2 | null | 40,372 | 2 | null | This extension will do it for you:
[https://addons.mozilla.org/en-US/firefox/addon/2848](https://addons.mozilla.org/en-US/firefox/addon/2848)
| null | CC BY-SA 2.5 | null | 2008-09-02T19:34:32.347 | 2008-09-02T19:34:32.347 | null | null | 29 | null |
40,380 | 2 | null | 40,346 | 2 | null | [Game Developer Magazine](http://www.gdmag.com/) has lots of very good articles, though as you might expect they tend to skew towards C++.
| null | CC BY-SA 2.5 | null | 2008-09-02T19:34:38.867 | 2008-09-02T19:34:38.867 | null | null | 3,114 | null |
40,382 | 2 | null | 40,346 | 1 | null | I really enjoy [IEEE Software](http://www.computer.org/portal/site/software/) because it covers broader issues regarding software engineering.
| null | CC BY-SA 2.5 | null | 2008-09-02T19:37:19.140 | 2008-09-02T19:37:19.140 | null | null | 2,820 | null |
40,381 | 2 | null | 40,242 | 0 | null | The best way is to print out the code, crumple it up, and throw it out. Don't even recycle the paper.
You've got an application that is written in 1,000+ line long JSPs. It probably has a god-awful Domain Model (if it even has one at all) and doesn't just MIX presentation with business logic, it BLENDS it and sits the... | null | CC BY-SA 2.5 | null | 2008-09-02T19:35:12.373 | 2008-09-02T19:35:12.373 | null | null | 543 | null |
40,367 | 2 | null | 39,847 | 2 | null | Launching a Python interpreter instance just to select the right binary to run would be much heavier than you need. I'd distribute a shell .rc file which provides aliases.
In /shared/bin, you put the various binaries: /shared/bin/toolname-mac, /shared/bin/toolname-debian-x86, /shared/bin/toolname-netbsd-dreamcast, et... | null | CC BY-SA 2.5 | null | 2008-09-02T19:29:07.193 | 2008-09-02T19:29:07.193 | null | null | 3,286 | null |
40,388 | 2 | null | 39,758 | 1 | null | Personally, I'm hoping it has less of an impact on web developers and more of an impact on browser developers. Some of the features are really nice, and while the process-oriented approach to separation of tabs will probably make it hefty compared to other browsers, I like the ideas behind it.
My guess is it's going ... | null | CC BY-SA 2.5 | null | 2008-09-02T19:39:24.113 | 2008-09-02T19:39:24.113 | null | null | 2,547 | null |
40,389 | 2 | null | 40,368 | 11 | null | No. Inode limits are per-filesystem, and decided at filesystem creation time. You could be hitting another limit, or maybe 'ls' just doesn't perform that well.
Try this:
```
tune2fs -l /dev/DEVICE | grep -i inode
```
It should tell you all sorts of inode related info.
| null | CC BY-SA 2.5 | null | 2008-09-02T19:39:29.603 | 2008-09-02T19:39:29.603 | null | null | 4,272 | null |
40,385 | 2 | null | 40,368 | 0 | null | Can you get a real count of the number of files? Does it fall very near a 2^n boundry? Could you simply be running out of RAM to hold all the file names?
I know that in windows at least file system performance would drop dramatically as the number of files in the folder went up, but I thought that linux didn't suffe... | null | CC BY-SA 2.5 | null | 2008-09-02T19:38:54.673 | 2008-09-02T19:38:54.673 | null | null | 3,043 | null |
40,374 | 2 | null | 40,346 | 1 | null | I subscribe to MSDN magazine, it's a bit thinner now than in years past, but for .NET it covers a variety of topics, it's a good way to keep abreast of new Microsoft offerings.
All the content is available online on MSDN, and of course online resources/blogs are a lot more up to date, but sometimes it's nice to have a... | null | CC BY-SA 2.5 | null | 2008-09-02T19:31:56.890 | 2008-09-02T19:31:56.890 | null | null | 2,194 | null |
40,390 | 2 | null | 40,376 | 4 | null | Perhaps [Runtime#addShutdownHook](http://java.sun.com/j2se/1.5.0/docs/api/java/lang/Runtime.html#addShutdownHook%28java.lang.Thread%29) ?
| null | CC BY-SA 2.5 | null | 2008-09-02T19:39:45.717 | 2008-09-02T19:39:45.717 | null | null | 3,295 | null |
40,364 | 2 | null | 40,264 | 16 | null | In your case, stick with the constructor. The information belongs in Customer and 4 fields are fine.
In the case you have many required and optional fields the constructor is not the best solution. As @boojiboy said, it's hard to read and it's also hard to write client code.
@contagious suggested using the default p... | null | CC BY-SA 2.5 | null | 2008-09-02T19:26:11.210 | 2008-09-02T19:26:11.210 | null | null | 4,213 | null |
40,398 | 2 | null | 40,259 | 0 | null | Maybe tcl/tk would provide what you want [http://www.tcl.tk/](http://www.tcl.tk/)
Here's the page on interfacing with curses. There is a claim there of integration with ncurses.
[http://www2.tcl.tk/2372](http://www2.tcl.tk/2372)
| null | CC BY-SA 3.0 | null | 2008-09-02T19:43:22.323 | 2012-02-17T16:52:28.393 | 2012-02-17T16:52:28.393 | 3,275 | 3,275 | null |
40,402 | 1 | 40,427 | null | 218 | 537,397 | I need to empty an LDF file before sending to a colleague. How do I force SQL Server to truncate the log?
| What is the command to truncate a SQL Server log file? | CC BY-SA 2.5 | 0 | 2008-09-02T19:44:50.463 | 2020-04-16T20:25:50.563 | 2008-09-03T16:13:06.767 | -1 | 1,042 | [
"sql-server",
"truncate",
"logging"
] |
40,371 | 2 | null | 40,264 | 4 | null | I'd encapsulate similar fields into an object of its own with its own construction/validation logic.
Say for example, if you've got
- - - -
I'd make a class that stores phone and address together with a tag specifying wether its a "home" or a "business" phone/address. And then reduce the 4 fields to merely an array... | null | CC BY-SA 2.5 | null | 2008-09-02T19:31:20.700 | 2008-09-02T19:38:27.110 | 2008-09-02T19:38:27.110 | 3,055 | 3,055 | null |
40,413 | 1 | 40,419 | null | 1 | 2,497 | Moving through the maze forward is pretty easy, but I can't seem to figure out how to back up through the maze to try a new route once you hit a dead end without going back too far?
| How to traverse a maze programmatically when you've hit a dead end | CC BY-SA 3.0 | null | 2008-09-02T19:47:38.163 | 2017-10-11T03:12:21.847 | 2017-10-11T03:12:21.847 | 1,033,581 | 4,298 | [
"c#",
"artificial-intelligence",
"maze"
] |
40,419 | 2 | null | 40,413 | 4 | null | Use [backtracking](http://www.cs.bu.edu/teaching/alg/maze/) by keeping a stack of previous direction decisions.
| null | CC BY-SA 2.5 | null | 2008-09-02T19:50:36.800 | 2008-09-02T19:50:36.800 | null | null | 3,560 | null |
40,392 | 2 | null | 40,368 | 0 | null | Unless you are getting an error message, ls is working but very slowly. You can try looking at just the first ten files like this:
`ls -f | head -10`
If you're going to need to look at the file details for a while, you can put them in a file first. You probably want to send the output to a different directory than th... | null | CC BY-SA 3.0 | null | 2008-09-02T19:40:28.790 | 2012-05-16T15:54:59.697 | 2012-05-16T15:54:59.697 | 1,392,398 | 3,275 | null |
40,417 | 2 | null | 17,955 | 1 | null | PowerBuilder in particular has a nice trick you can do to incorporate the build number from an ini file into the compiled application.
Details here: [http://www.pbdr.com/pbtips/ex/autorev.htm](http://www.pbdr.com/pbtips/ex/autorev.htm)
We have ini file inside source control that stores the build number and its value ... | null | CC BY-SA 2.5 | null | 2008-09-02T19:50:15.130 | 2008-09-02T19:50:15.130 | null | null | 4,311 | null |
40,410 | 2 | null | 34,519 | 7 | null | A semaphore is an object containing a natural number (i.e. a integer greater or equal to zero) on which two modifying operations are defined. One operation, `V`, adds 1 to the natural. The other operation, `P`, decreases the natural number by 1. Both activities are atomic (i.e. no other operation can be executed at the... | null | CC BY-SA 2.5 | null | 2008-09-02T19:46:32.580 | 2008-09-02T19:46:32.580 | null | null | 4,285 | null |
40,421 | 2 | null | 40,402 | 3 | null | backup log logname with truncate_only followed by a dbcc shrinkfile command
| null | CC BY-SA 2.5 | null | 2008-09-02T19:51:59.323 | 2008-09-02T19:51:59.323 | null | null | 740 | null |
40,384 | 2 | null | 40,161 | 2 | null | Here's something I cooked up for something similar.
It handles the following types of ranges:
```
1 single number
1-5 range
-5 range from (firstpage) up to 5
5- range from 5 up to (lastpage)
.. can use .. instead of -
;, can use both semicolon, comma, and space, as separators
```
... | null | CC BY-SA 2.5 | null | 2008-09-02T19:37:43.837 | 2008-09-02T19:37:43.837 | null | null | 267 | null |
40,427 | 2 | null | 40,402 | 135 | null | if I remember well... in query analyzer or equivalent:
```
BACKUP LOG databasename WITH TRUNCATE_ONLY
DBCC SHRINKFILE ( databasename_Log, 1)
```
| null | CC BY-SA 2.5 | null | 2008-09-02T19:53:31.410 | 2008-09-02T19:53:31.410 | null | null | 1,178 | null |
40,412 | 2 | null | 39,281 | 3 | null | If indeed an audit trail is all you need, I'd lean toward the audit table solution (complete with denormalized copies of the important column on other tables, e.g., `UserName`). Keep in mind, though, that bitter experience indicates that a single audit table will be a huge bottleneck down the road; it's probably worth... | null | CC BY-SA 2.5 | null | 2008-09-02T19:47:02.440 | 2008-09-02T19:47:02.440 | null | null | 4,203 | null |
40,422 | 1 | 339,033 | null | -1 | 1,586 | Ok, so I want an autocomplete dropdown with linkbuttons as selections. So, the user puts the cursor in the "text box" and is greated with a list of options. They can either start typing to narrow down the list, or select one of the options on the list. As soon as they click (or press enter) the dataset this is linked t... | Autocomplete Dropdown with Linkbuttons - or "AJAX gone wild" | CC BY-SA 2.5 | null | 2008-09-02T19:52:24.143 | 2008-12-04T08:10:00.157 | null | null | 4,140 | [
"ajax",
".net-3.5"
] |
40,429 | 2 | null | 40,230 | 0 | null | @Simon,
You raise very good points. I was already thinking about the "temporary" "human-readable" numbers i'd generate while offline, that i'd recreate on sync. But i wanted to avoid doing with with foreign keys, etc.
| null | CC BY-SA 2.5 | null | 2008-09-02T19:54:19.613 | 2008-09-02T19:54:19.613 | null | null | 3,314 | null |
40,434 | 2 | null | 24,470 | 167 | null | Remember that the MAX aggregate function will work on text as well as numbers. This query will only require the table to be scanned once.
```
SELECT Action,
MAX( CASE data WHEN 'View' THEN data ELSE '' END ) ViewCol,
MAX( CASE data WHEN 'Edit' THEN data ELSE '' END ) EditCol
FROM t
GROUP BY Action
``... | null | CC BY-SA 2.5 | null | 2008-09-02T19:55:19.270 | 2008-09-02T19:55:19.270 | null | null | 4,286 | null |
40,420 | 2 | null | 40,402 | 335 | null | In management studio:
- - `Properties``Options`- - - `Tasks``Shrink``Files`- -
Alternatively, the SQL to do it:
```
ALTER DATABASE mydatabase SET RECOVERY SIMPLE
DBCC SHRINKFILE (mydatabase_Log, 1)
```
Ref: [http://msdn.microsoft.com/en-us/library/ms189493.aspx](http://msdn.microsoft.com/en-us/library/ms189493.a... | null | CC BY-SA 3.0 | null | 2008-09-02T19:51:12.087 | 2018-01-22T17:59:37.657 | 2018-01-22T17:59:37.657 | 968,244 | 369 | null |
40,433 | 2 | null | 40,193 | 0 | null | You should provide information about what operating system and the type of filesystem you are using. On certain flavours of UNIX and certain filesystems you might be able to use the commands [ff](http://www.unix.com/man-page/all/0/ff) and [ncheck](http://www.unix.com/man-page/all/0/ncheck) as alternatives.
| null | CC BY-SA 3.0 | null | 2008-09-02T19:55:17.443 | 2017-10-12T02:56:11.153 | 2017-10-12T02:56:11.153 | 446,106 | 4,071 | null |
40,439 | 2 | null | 40,372 | 2 | null | You can use the [Foxmarks](https://addons.mozilla.org/en-US/firefox/addon/2410) plugin. This exports to XML or CSV format. I used it a week ago and it works really fine.
| null | CC BY-SA 2.5 | null | 2008-09-02T19:56:10.233 | 2008-09-02T19:56:10.233 | null | null | 4,313 | null |
40,442 | 2 | null | 39,119 | 0 | null | [MultiSelectTreeView](http://www.codeproject.com/KB/tree/Multiselect_Treeview.aspx):
> Why doesn't .NET have a multiselect treeview? There are so many uses for one and turning on checkboxes in the treeview is a pretty lousy alternative.
| null | CC BY-SA 2.5 | null | 2008-09-02T19:59:24.720 | 2008-09-02T19:59:24.720 | null | null | 3,583 | null |
40,424 | 2 | null | 40,413 | 2 | null | The simplest (to implement) algorithm would be to just keep a stack of locations you've been at, and the route you took from each, unless backtracking gives you that information.
To go back, just pop off old locations from the stack and check for more exits from that location until you find an old location with an unt... | null | CC BY-SA 2.5 | null | 2008-09-02T19:53:01.130 | 2008-09-02T19:53:01.130 | null | null | 267 | null |
40,441 | 2 | null | 40,368 | 58 | null | `df -i` should tell you the number of inodes used and free on the file system.
| null | CC BY-SA 3.0 | null | 2008-09-02T19:57:08.687 | 2012-07-11T13:50:08.600 | 2012-07-11T13:50:08.600 | 142,162 | 4,071 | null |
40,438 | 2 | null | 40,372 | 0 | null | Alas, this won't solve the re-importing problem, but check out [http://wejn.org/stuff/moz-export.html](http://wejn.org/stuff/moz-export.html)
They have a single html page with a small javascript section that exports your passwords. Save the html to your desktop, read through to make sure it's not evil, open the page i... | null | CC BY-SA 2.5 | null | 2008-09-02T19:55:56.787 | 2008-09-02T19:55:56.787 | null | null | 4,301 | null |
40,450 | 2 | null | 40,413 | 1 | null | Eric Lippert did a series of articles on creating a [C# implemention of A*](http://blogs.msdn.com/ericlippert/archive/tags/AStar/default.aspx), which might be more efficient.
| null | CC BY-SA 2.5 | null | 2008-09-02T20:03:39.623 | 2008-09-02T20:03:39.623 | null | null | 3,043 | null |
40,443 | 2 | null | 40,361 | 3 | null | Short answer: no. Such a function was considered and explicitly rejected for version 2 of the XPath spec (see the non-normative [Illustrative User-written Functions section](http://www.w3.org/TR/xpath-functions/#examples)).
| null | CC BY-SA 2.5 | null | 2008-09-02T20:01:25.993 | 2008-12-27T16:17:17.520 | 2008-09-02T20:39:35.277 | 4,203 | 4,203 | null |
40,456 | 1 | 40,619 | null | 4 | 4,333 | If I select from a table group by the month, day, year,
it only returns rows with records and leaves out combinations without any records, making it appear at a glance that every day or month has activity, you have to look at the date column actively for gaps. How can I get a row for every day/month/year, even when no... | sql missing rows when grouped by DAY, MONTH, YEAR | CC BY-SA 2.5 | 0 | 2008-09-02T20:06:25.343 | 2009-04-03T17:19:13.027 | null | null | 2,477 | [
"tsql",
"date",
"grouping"
] |
40,459 | 2 | null | 40,230 | 0 | null | First thought that comes to mind: Hasn't MS designed the DataSet and DataAdapter model to support scenarios like this?
I believe I read that MS changed their ADO recordset model to the current DataSet model so it works great offline too. And there's also this [Sync Services for ADO.NET](http://msdn.microsoft.com/en-us... | null | CC BY-SA 2.5 | null | 2008-09-02T20:06:43.047 | 2008-09-02T20:06:43.047 | null | null | 3,055 | null |
40,458 | 2 | null | 38,875 | 0 | null | @pek - That won't work, as your array keys are 0 and 1, not 'home' and 'page'.
This code should do the trick, I believe:
```
<?php
$whitelist = array(
'home',
'page',
);
if(in_array($_GET['page'], $whitelist)) {
include($_GET['page'] . '.php');
} else {
include('home.php');
}
?>
```
As you've a whitelist... | null | CC BY-SA 2.5 | null | 2008-09-02T20:06:36.230 | 2008-09-02T20:06:36.230 | null | null | 1,902,010 | null |
40,452 | 1 | 40,479 | null | 5 | 3,600 | I have to POST some parameters to a URL outside my network, and the developers on the other side asked me to not use HTTP Parameters: instead I have to post my key-values in .
The fact is that I don't really understand what they mean: I tried to use a ajax-like post, with XmlHttp objects, and also I tried to write in ... | HTTP POST - I'm stuck | CC BY-SA 3.0 | 0 | 2008-09-02T20:04:28.920 | 2012-06-13T20:43:25.863 | 2012-06-13T20:43:25.863 | 457,162 | 1,178 | [
"asp.net",
"forms",
"http",
"post"
] |
40,464 | 2 | null | 39,758 | 2 | null | Google Chrome looks promising. It is of course in an early beta so it's missing a lot of the things people would need or at least feel they need, like plugins, cross-machine synchronization of data (could be done with plugins), cross-platform support (ie. Linux and Mac versions).
So far it renders Gmail like a bat out... | null | CC BY-SA 2.5 | null | 2008-09-02T20:08:00.080 | 2008-09-02T20:08:00.080 | null | null | 267 | null |
40,462 | 2 | null | 40,456 | 5 | null | Create a calendar table and outer join on that table
| null | CC BY-SA 2.5 | null | 2008-09-02T20:07:20.300 | 2008-09-02T20:07:20.300 | null | null | 740 | null |
40,467 | 2 | null | 40,452 | 0 | null | I think they mean they don't want you to use URL parameters (GET). If you use http headers, it's not really querying through POST any more.
| null | CC BY-SA 2.5 | null | 2008-09-02T20:10:06.847 | 2008-09-02T20:10:06.847 | null | null | 3,043 | null |
40,423 | 1 | 40,616 | null | 10 | 3,266 | Actually, this question seems to have two parts:
- - [send and receive](http://erlang.org/doc/reference_manual/expressions.html#6.9)
For the pattern matching part, I've been looking into various projects like [App](http://members.cox.net/nelan/app.html) and [Prop](http://www.cs.nyu.edu/leunga/papers/research/prop/pro... | How would you implement Erlang-like send and receive in C++? | CC BY-SA 2.5 | 0 | 2008-09-02T19:52:33.660 | 2014-04-17T08:09:02.620 | 2008-11-07T12:05:23.393 | null | null | [
"c++",
"erlang"
] |
40,465 | 1 | 40,497 | null | 4 | 6,054 | I have a List of Foo.
Foo has a string property named Bar.
I'd like to use to get a string[] of values for Foo.Bar in List of Foo.
How can I do this?
| How to get an array of distinct property values from in memory lists? | CC BY-SA 3.0 | 0 | 2008-09-02T20:08:51.607 | 2018-06-11T15:45:48.087 | 2015-05-08T17:18:38.483 | 1,362,287 | 1,946 | [
"c#",
".net",
"performance",
"linq",
"filtering"
] |
40,445 | 2 | null | 40,230 | 0 | null | i would start to look at SQL Server Compact Edition for this! It helps with all of your issues.
[Data Storage Architecture with SQL Server 2005 Compact Edition](http://msdn.microsoft.com/en-us/library/bb380177.aspx)
It specifically designed for
> Field force applications (FFAs). FFAs
usually share one or more o... | null | CC BY-SA 2.5 | null | 2008-09-02T20:01:57.863 | 2008-09-02T20:01:57.863 | null | null | null | null |
40,466 | 2 | null | 40,372 | 5 | null | I've had luck just copying `signons2.txt` and `key3.db` over from one profile to another. See also [the documentation on MozillaZine](http://kb.mozillazine.org/Signons.txt).
| null | CC BY-SA 2.5 | null | 2008-09-02T20:09:33.510 | 2008-09-02T20:09:33.510 | null | null | null | null |
40,455 | 2 | null | 40,452 | 0 | null | You should post more information.
For instance, is this C#? It looks like it, but I might be wrong.
Also, you say you get an exception, what is the exception type and message?
In any case, you can't redirect to a page for POST, you need to submit it from the browser, not from the server redirect, so if you want to a... | null | CC BY-SA 2.5 | null | 2008-09-02T20:06:19.740 | 2008-09-02T20:06:19.740 | null | null | 267 | null |
40,468 | 2 | null | 40,452 | 0 | null | What language/framework?
Using Python and httplib2, you should be able to do something like:
```
http = httplib2.Http()
http.request(url, 'POST', headers={'key': 'value'}, body=urllib.urlencode(''))
```
| null | CC BY-SA 2.5 | null | 2008-09-02T20:10:10.963 | 2008-09-02T20:10:10.963 | null | null | 4,203 | null |
40,472 | 2 | null | 38,779 | 3 | null | By default (i.e. out of the box) net.tcp services are unsecured and don't perform any authentication at all. So you won't need (and in fact can't) set a service principal name.
If you need to authenticate, then check the [net.tcp security](http://msdn.microsoft.com/en-us/library/system.servicemodel.nettcpsecurity.asp... | null | CC BY-SA 2.5 | null | 2008-09-02T20:12:02.473 | 2008-09-02T20:12:02.473 | null | null | 3,546 | null |
40,475 | 2 | null | 40,452 | 0 | null | I believe that the Request object would only accept a certain set of predefined headers.
There's an enumeration that lists all the supported HTTP Headers too.
But I can't remember it at the moment... I'll look it up in a sec...
| null | CC BY-SA 2.5 | null | 2008-09-02T20:13:17.743 | 2008-09-02T20:13:17.743 | null | null | 3,055 | null |
40,477 | 2 | null | 40,465 | 2 | null | Try this:
```
var distinctFooBars = (from foo in foos
select foo.Bar).Distinct().ToArray();
```
| null | CC BY-SA 2.5 | null | 2008-09-02T20:13:41.470 | 2008-09-02T20:13:41.470 | null | null | 267 | null |
40,479 | 2 | null | 40,452 | 1 | null | Like @lassevk said, a redirect won't work.
You should use the WebRequest class to do an HTTP POST from your page or application. There's an example [here](http://msdn.microsoft.com/en-us/library/debx8sh9.aspx).
| null | CC BY-SA 2.5 | null | 2008-09-02T20:14:11.157 | 2008-09-03T20:31:05.337 | 2008-09-03T20:31:05.353 | 1,219 | 3,880 | null |
40,471 | 1 | 40,878 | null | 4,247 | 1,711,610 | What are the differences between a [HashMap](https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/util/HashMap.html) and a [Hashtable](https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/util/Hashtable.html) in Java?
Which is more efficient for non-threaded applications?
| What are the differences between a HashMap and a Hashtable in Java? | CC BY-SA 4.0 | 0 | 2008-09-02T20:12:00.117 | 2023-02-07T13:26:15.613 | 2020-08-01T11:19:23.890 | 1,063,716 | 4,316 | [
"java",
"collections",
"hashmap",
"hashtable"
] |
40,480 | 1 | null | null | 7,645 | 2,574,861 | I always thought Java uses . However, I read [a blog post](http://javadude.com/articles/passbyvalue.htm) which claims that Java uses . I don't think I understand the distinction the author is making.
What is the explanation?
| Is Java "pass-by-reference" or "pass-by-value"? | CC BY-SA 4.0 | 0 | 2008-09-02T20:14:29.270 | 2023-02-14T20:31:14.480 | 2023-02-14T20:31:14.480 | 5,323,892 | 4,315 | [
"java",
"methods",
"parameter-passing",
"pass-by-reference",
"pass-by-value"
] |
40,483 | 2 | null | 40,471 | 33 | null | Based on the info [here](http://www.jguru.com/faq/view.jsp?EID=430247), I'd recommend going with HashMap. I think the biggest advantage is that Java will prevent you from modifying it while you are iterating over it, unless you do it through the iterator.
| null | CC BY-SA 2.5 | null | 2008-09-02T20:14:53.840 | 2008-09-02T20:14:53.840 | null | null | 4,257 | null |
40,481 | 2 | null | 40,456 | 0 | null | Look into using a [numbers table](http://andre-silva-cardoso.blogspot.com/2007/11/sql-trickspatterns-1-numbers-table.html). While it can be hackish, it's the best method I've come by to quickly query missing data, or show all dates, or anything where you want to examine values within a range, regardless of whether all... | null | CC BY-SA 2.5 | null | 2008-09-02T20:14:29.707 | 2008-09-02T20:14:29.707 | null | null | 2,314 | null |
40,473 | 2 | null | 34,519 | 438 | null | Think of semaphores as bouncers at a nightclub. There are a dedicated number of people that are allowed in the club at once. If the club is full no one is allowed to enter, but as soon as one person leaves another person might enter.
It's simply a way to limit the number of consumers for a specific resource. For examp... | null | CC BY-SA 3.0 | null | 2008-09-02T20:13:07.713 | 2012-01-27T03:44:11.717 | 2012-01-27T03:44:11.717 | 366,904 | 936 | null |
40,488 | 2 | null | 40,465 | 3 | null | This should work if you want to use the fluent pattern:
```
string[] arrayStrings = fooList.Select(a => a.Bar).Distinct().ToArray();
```
| null | CC BY-SA 2.5 | null | 2008-09-02T20:16:09.343 | 2008-09-02T23:46:29.150 | 2008-09-02T23:46:29.150 | 1,463 | 1,463 | null |
40,486 | 2 | null | 40,452 | 3 | null | Have you tried the WebClient class? An example might look like:
```
WebClient client = new WebClient();
NameValueCollection data = new NameValueCollection();
data["var1"] = "var1";
client.UploadValues("http://somewhere.com/api", "POST", data);
```
| null | CC BY-SA 2.5 | null | 2008-09-02T20:15:33.260 | 2008-09-02T20:15:33.260 | null | null | 2,696 | null |
40,476 | 2 | null | 13,540 | 5 | null | If you are not doing a merge in SQL 2008 you must change it to:
if @@rowcount = 0 and @@error=0
otherwise if the update fails for some reason then it will try and to an insert afterwards because the rowcount on a failed statement is 0
| null | CC BY-SA 2.5 | null | 2008-09-02T20:13:39.647 | 2008-09-02T20:13:39.647 | null | null | 3,893 | null |
40,495 | 1 | 40,562 | null | 36 | 50,344 | I know I can do most of this by hacking Trac and using Git hooks, but I was wondering if someone has / knows of something ready.
Commenting on (and closing) tickets from commit messages would be nice, specially if the diff appears inline with the comment/closing remark.
sha1 hashes should be auto-linked to gitweb/cig... | Bug tracker setup with Git integration? | CC BY-SA 2.5 | 0 | 2008-09-02T20:17:11.963 | 2015-11-25T19:27:54.057 | 2008-09-02T22:54:47.747 | 305 | 4,272 | [
"git",
"integration",
"version-control",
"bug-tracking"
] |
40,478 | 2 | null | 40,452 | 1 | null | Take a look at HttpWebRequest. You should be able to construct a request to the URL in question using HttpWebRequest.Method = "POST".
| null | CC BY-SA 2.5 | null | 2008-09-02T20:13:56.120 | 2008-09-02T20:13:56.120 | null | null | 1,865 | null |
40,498 | 2 | null | 40,465 | 0 | null | Shouldn't you be able to do something like:
```
var strings = (from a in fooList select a.Bar).Distinct();
string[] array = strings.ToArray();
```
| null | CC BY-SA 4.0 | null | 2008-09-02T20:18:43.597 | 2018-06-11T15:45:48.087 | 2018-06-11T15:45:48.087 | 4,636,715 | null | null |
40,501 | 2 | null | 40,480 | 388 | null | Java passes references by value.
So you can't change the reference that gets passed in.
| null | CC BY-SA 2.5 | null | 2008-09-02T20:20:08.710 | 2008-09-02T20:20:08.710 | null | null | 1,310 | null |
40,496 | 2 | null | 40,193 | 2 | null | If a process "doesn't come back", I recommend [strace](http://linux.die.net/man/1/strace) to analyze how a process is interacting with the operating system.
In case of ls:
```
$strace ls
```
you would have seen that it reads all directory entries ([getdents(2)](http://linux.die.net/man/2/getdents)) before it actual... | null | CC BY-SA 2.5 | null | 2008-09-02T20:17:46.500 | 2008-09-02T20:17:46.500 | null | null | 4,308 | null |
40,497 | 2 | null | 40,465 | 5 | null | I'd go lambdas... wayyy nicer
```
var bars = Foos.Select(f => f.Bar).Distinct().ToArray();
```
works the same as what @lassevk posted.
I'd also add that you might want to keep from converting to an array until the last minute.
LINQ does some optimizations behind the scenes, queries stay in its query form until ex... | null | CC BY-SA 2.5 | null | 2008-09-02T20:18:09.713 | 2008-09-02T20:25:04.440 | 2008-09-02T20:25:04.453 | 3,055 | 3,055 | null |
40,504 | 2 | null | 40,422 | 0 | null | You'll have to handle the OnSelectedIndexChanged event of your drop down list to rebind your dataset based on the users selection. If you want the filtering to happen in an asynch postback, wrap the dataset (or datagrid I'm assuming) and your drop down in an UpdatePanel. That is one way to do it anyhow.
| null | CC BY-SA 2.5 | null | 2008-09-02T20:20:25.137 | 2008-09-02T20:20:25.137 | null | null | 1,865 | null |
40,508 | 2 | null | 40,485 | 0 | null | Don't exactly know how this can be done, but I remember some of my friends had to represent this game's grid with a Quadtree for a assignment. I'm guess it's real good for optimizing the space of the grid since you basically only represent the occupied cells. I don't know about execution speed though.
| null | CC BY-SA 2.5 | null | 2008-09-02T20:21:12.810 | 2008-09-02T20:21:12.810 | null | null | 2,907 | null |
40,502 | 2 | null | 40,456 | 0 | null | Building on what SQLMenace said, you can use a CROSS JOIN to quickly populate the table or efficiently create it in memory.
[http://www.sitepoint.com/forums/showthread.php?t=562806](http://www.sitepoint.com/forums/showthread.php?t=562806)
| null | CC BY-SA 2.5 | null | 2008-09-02T20:20:22.983 | 2008-09-02T20:20:22.983 | null | null | 3,043 | null |
40,485 | 1 | null | null | 44 | 45,303 | To experiment, I've (long ago) implemented Conway's [Game of Life](http://en.wikipedia.org/wiki/Conway's_Game_of_Life) (and I'm aware of [this](https://stackoverflow.com/questions/1823/writing-a-conways-game-of-life-program) related question!).
My implementation worked by keeping 2 arrays of booleans, representing the... | Optimizing Conway's 'Game of Life' | CC BY-SA 2.5 | 0 | 2008-09-02T20:15:13.527 | 2021-11-26T13:56:41.710 | 2017-05-23T11:54:26.267 | -1 | 2,638 | [
"algorithm",
"performance",
"language-agnostic",
"conways-game-of-life"
] |
40,507 | 2 | null | 40,480 | 232 | null | Basically, reassigning Object parameters doesn't affect the argument, e.g.,
```
private static void foo(Object bar) {
bar = null;
}
public static void main(String[] args) {
String baz = "Hah!";
foo(baz);
System.out.println(baz);
}
```
will print out `"Hah!"` instead of `null`. The reason this works is... | null | CC BY-SA 4.0 | null | 2008-09-02T20:21:04.683 | 2022-03-07T07:47:40.997 | 2022-03-07T07:47:40.997 | 9,575,631 | 4,203 | null |
40,520 | 2 | null | 40,485 | 0 | null | There are table-driven solutions for this that resolve multiple cells in each table lookup. A google query should give you some examples.
| null | CC BY-SA 2.5 | null | 2008-09-02T20:25:18.043 | 2008-09-02T20:25:18.043 | null | null | 267 | null |
40,510 | 2 | null | 34,194 | -2 | null | I have a detailed step by step guide, but it requires that you use isapi_rewrite. View it at: [http://biasecurities.com/blog/2008/how-to-enable-pretty-urls-with-asp-net-mvc-and-iis6/](http://biasecurities.com/blog/2008/how-to-enable-pretty-urls-with-asp-net-mvc-and-iis6/)
| null | CC BY-SA 2.5 | null | 2008-09-02T20:21:40.173 | 2008-09-02T20:21:40.173 | null | null | 3,085 | null |
40,499 | 2 | null | 40,480 | 842 | null | Java is always pass by value, with no exceptions, .
So how is it that anyone can be at all confused by this, and believe that Java is pass by reference, or think they have an example of Java acting as pass by reference? The key point is that Java provides direct access to the values of , in circumstances. The only a... | null | CC BY-SA 3.0 | null | 2008-09-02T20:19:21.847 | 2016-01-22T03:37:07.313 | 2016-01-22T03:37:07.313 | 18,091 | 1,666 | null |
40,512 | 2 | null | 40,471 | 51 | null | `Hashtable` is synchronized, whereas `HashMap` isn't. That makes `Hashtable` slower than `Hashmap`.
For single thread applications, use `HashMap` since they are otherwise the same in terms of functionality.
| null | CC BY-SA 4.0 | null | 2008-09-02T20:22:34.023 | 2020-09-15T20:28:43.900 | 2020-09-15T20:28:43.900 | 1,173,112 | 974 | null |
40,519 | 2 | null | 38,934 | 14 | null | Two interesting options I have seen, but yet to use professionally, are the screencapture utility and a MacFuse demo.
The screencapture utility has been around since 10.2, according to the man page, and could be linked to a Cocoa application by use of NSTask.
The MacFuse demo worked by creating a new screenshot each ... | null | CC BY-SA 2.5 | null | 2008-09-02T20:25:08.417 | 2008-09-02T20:25:08.417 | null | null | 4,314 | null |
40,511 | 1 | null | null | 1 | 4,266 | As the title already states, I'm trying to declare a nested function and return a pointer to that function. I want this function 'not' to return a new function pointer which will return the negation of whatever the original function was.
Here is what I have:
```
someType not( someType original ) {
int isNot( List... | Return function pointer to a nested function in C | CC BY-SA 2.5 | null | 2008-09-02T20:22:25.273 | 2009-04-14T08:44:13.957 | 2008-09-09T21:13:49.643 | -1 | 402 | [
"c",
"pointers",
"nested"
] |
40,525 | 1 | 40,617 | null | 2 | 34,687 | I'm trying to call a function after I load some XML into Actionscript, and I'm just wondering how I call that function. Example:
```
//Function Declarations
function parentFunction()
{
function callMe()
{
textField.text = "lawl";
}
}
```
Now, in a different part of the code, like an onRelease funct... | Call Functions within Function - Flash Actionscript 2.0 | CC BY-SA 2.5 | null | 2008-09-02T20:25:54.780 | 2010-07-13T13:07:12.303 | null | null | 557 | [
"flash",
"actionscript",
"actionscript-2"
] |
40,522 | 2 | null | 40,471 | 57 | null | `Hashtable` is similar to the `HashMap` and has a similar interface. It is recommended that you use `HashMap`, unless you require support for legacy applications or you need synchronisation, as the `Hashtables` methods are synchronised. So in your case as you are not multi-threading, `HashMaps` are your best bet.
| null | CC BY-SA 3.0 | null | 2008-09-02T20:25:30.117 | 2015-03-02T08:55:23.043 | 2015-03-02T08:55:23.043 | 3,924,118 | 3,898 | null |
40,531 | 1 | null | null | 8 | 9,957 | Extreme Programming, Scrum and Test Driven Development definitely seem to be the most popular Agile methods at the moment. But someone recently suggested that I take a look at Feature Driven Development.
Have you ever used this method with any success? What are the advantages of using it?
| Why should I use Feature Driven Development? | CC BY-SA 2.5 | 0 | 2008-09-02T20:26:49.240 | 2017-09-04T06:34:18.463 | 2015-02-17T12:14:53.083 | 2,594,742 | 2,342,930 | [
"agile",
"feature-driven"
] |
40,509 | 2 | null | 40,485 | 0 | null | It's a two dimensional automaton, so you can probably look up optimization techniques. Your notion seems to be about compressing the number of cells you need to check at each step. Since you only ever need to check cells that are occupied or adjacent to an occupied cell, perhaps you could keep a buffer of all such cell... | null | CC BY-SA 2.5 | null | 2008-09-02T20:21:28.347 | 2008-09-02T20:21:28.347 | null | null | 3,275 | null |
40,521 | 2 | null | 16,727 | 5 | null | GWT has good support for internationalization. See this [link](http://code.google.com/docreader/#p=google-web-toolkit-doc-1-5&s=google-web-toolkit-doc-1-5&t=DevGuideInternationalization). The [i18nCreator](http://code.google.com/docreader/#p=google-web-toolkit-doc-1-5&s=google-web-toolkit-doc-1-5&t=DevGuideI18nCreator)... | null | CC BY-SA 2.5 | null | 2008-09-02T20:25:26.623 | 2008-09-02T20:25:26.623 | null | null | 4,229 | null |
40,537 | 2 | null | 40,511 | 0 | null | I'm using GCC.
You can turn on nested functions by using the flag:
```
-fnested-functions
```
when you compile.
| null | CC BY-SA 2.5 | null | 2008-09-02T20:28:00.407 | 2008-09-02T20:28:00.407 | null | null | 402 | null |
40,529 | 2 | null | 40,485 | 39 | null | I am going to quote my answer from the other question, because the chapters I mention have some very interesting and fine-tuned solutions. Some of the implementation details are in c and/or assembly, yes, but for the most part the algorithms can work in any language:
> Chapters [17](http://www.jagregory.com/abrash-bla... | null | CC BY-SA 3.0 | null | 2008-09-02T20:26:32.843 | 2017-06-22T05:25:35.807 | 2020-06-20T09:12:55.060 | -1 | 96 | null |
40,545 | 1 | null | null | 8 | 10,614 | Is there is any way to change the datasource location for a report and all of it's subreports without having to open each of them manually?
| Replace a database connection for report and all subreports | CC BY-SA 2.5 | 0 | 2008-09-02T20:29:40.513 | 2008-12-16T10:52:01.010 | null | null | 4,286 | [
"crystal-reports"
] |
40,535 | 1 | 2,745,475 | null | 11 | 3,696 | I need to determine if I'm on a particular view. My use case is that I'd like to decorate navigation elements with an "on" class for the current view. Is there a built in way of doing this?
| Asp.Net MVC: How to determine if you're currently on a specific view | CC BY-SA 2.5 | 0 | 2008-09-02T20:27:28.287 | 2010-04-30T15:05:08.063 | null | null | 3,085 | [
"c#",
"asp.net-mvc"
] |
40,514 | 2 | null | 40,480 | 210 | null | Java passes references to objects by value.
| null | CC BY-SA 2.5 | null | 2008-09-02T20:23:30.340 | 2008-09-02T20:23:30.340 | null | null | 3,305 | null |
40,554 | 2 | null | 40,259 | 1 | null | There's [Cursed GTK](http://zemljanka.sourceforge.net/cursed/), but it seems a bit dated. I found some references to a port of Qt to ncurses called Qt Console, but it seems to have disappeared.
| null | CC BY-SA 2.5 | null | 2008-09-02T20:31:22.833 | 2008-09-02T20:31:22.833 | null | null | null | null |
40,548 | 2 | null | 40,471 | 74 | null | In addition to what izb said, `HashMap` allows null values, whereas the `Hashtable` does not.
Also note that `Hashtable` extends the `Dictionary` class, which as the [Javadocs](http://java.sun.com/j2se/1.4.2/docs/api/java/util/Dictionary.html) state, is obsolete and has been replaced by the `Map` interface.
| null | CC BY-SA 2.5 | null | 2008-09-02T20:30:00.200 | 2008-09-02T20:30:00.200 | null | null | 4,249 | null |
40,555 | 2 | null | 40,244 | -1 | null | I doubt sh/bash can do it.
ZSH would be a better bet, with its MULTIOS and coproc features.
| null | CC BY-SA 2.5 | null | 2008-09-02T20:31:44.220 | 2008-09-02T20:31:44.220 | null | null | 4,118 | null |
40,564 | 2 | null | 40,485 | 5 | null | As mentioned in Arbash's Black Book, one of the most simple and straight forward ways to get a huge speedup is to keep a change list.
Instead of iterating through the entire cell grid each time, keep a copy of all the cells that you change.
This will narrow down the work you have to do on each iteration.
| null | CC BY-SA 2.5 | null | 2008-09-02T20:34:36.693 | 2008-09-02T20:34:36.693 | null | null | 4,319 | null |
40,571 | 2 | null | 40,568 | 1 | null | Best to URL encode those, as they are clearly not supported in all web servers. Sometimes, even when there is a standard, not everyone follows it.
| null | CC BY-SA 2.5 | null | 2008-09-02T20:36:36.113 | 2008-09-02T20:36:36.113 | null | null | 3,381 | null |
40,523 | 2 | null | 40,480 | 6,895 | null | The terms "pass-by-value" and "pass-by-reference" have special, [precisely defined](https://en.wikipedia.org/w/index.php?title=Pass-by-value) meanings in computer science. These meanings differ from the intuition many people have when first hearing the terms. Much of the confusion in this discussion seems to come from ... | null | CC BY-SA 4.0 | null | 2008-09-02T20:25:37.433 | 2022-09-05T08:37:57.840 | 2022-09-05T08:37:57.840 | 912,829 | 4,192 | null |