text
stringlengths
0
30.5k
title
stringclasses
1 value
embeddings
listlengths
768
768
functionality based on the name it's called as (think gzip and gunzip on some platforms). --- 1 That is, to resolve symlinks such that when the user executes `foo.sh` which is actually a symlink to `bar.sh`, you wish to use the resolved name `bar.sh` rather than `foo.sh`.
[ 0.17391136288642883, 0.02425435557961464, 0.43571868538856506, -0.25391554832458496, -0.011287194676697254, -0.21030907332897186, 0.10682344436645508, -0.22021083533763885, -0.18231211602687836, -0.4034445583820343, -0.41517242789268494, 0.5092642307281494, -0.4814148545265198, -0.02927477...
What I am looking for is a way to call a method after another method has been invoked but before it is entered. Example: ``` public class Test { public void Tracer ( ... ) { } public int SomeFunction( string str ) { return 0; } public void TestFun() { SomeFunction( "" ); } } ``` In the ...
[ 0.5922898650169373, 0.06347768753767014, 0.02188861183822155, -0.33284124732017517, 0.10243508964776993, -0.24050919711589813, 0.22738893330097198, -0.23411276936531067, 0.17185325920581818, -0.5007169246673584, -0.011017256416380405, 0.482742577791214, -0.2501748204231262, 0.0310336686670...
something interesting in everyone's answers. The **best answer to the question** is to use Castle's DynamicProxy; however, this is not that I'm going to use to solve my problem because it requires adding a library to my project. I have only a few methods that I need to "trace" so I've chosen to go with a modified "core...
[ -0.004573801998049021, -0.2279893308877945, 0.343539297580719, 0.10146786272525787, -0.060161590576171875, -0.13620400428771973, 0.32613199949264526, 0.11666444689035416, -0.25552600622177124, -0.5547700524330139, 0.21222390234470367, 0.3156459629535675, -0.22425059974193573, 0.08125480264...
proxy ([Castle's DynamicProxy](http://www.castleproject.org/dynamicproxy/index.html) for example) to intercept the call, run whatever code you wish, and then either invoke your method or not, depending on your needs.
[ -0.08081619441509247, -0.23259621858596802, 0.417310506105423, 0.14206725358963013, 0.13320089876651764, 0.03317680582404137, 0.43753179907798767, -0.01633051224052906, -0.08206071704626083, -0.21376293897628784, -0.4242384433746338, 0.16689392924308777, -0.4322035014629364, 0.402524471282...
I would like to use Pylons with Elixir, however, I am not sure what is the best way to get about doing this. There are several blog posts ([cleverdevil](http://cleverdevil.org/computing/68/ "cleverdevil's technique"), [beachcoder](http://beachcoder.wordpress.com/2007/05/11/using-elixir-with-pylons/ "beachcoder's techni...
[ 0.2974107265472412, 0.11292202770709991, 0.28553271293640137, 0.3808004856109619, -0.13609302043914795, -0.1057068258523941, -0.22258925437927246, -0.3999749422073364, -0.13184423744678497, -0.21147304773330688, 0.22923791408538818, 0.18380439281463623, -0.03757214918732643, -0.21356154978...
a dynamic proxy ([Castle's DynamicProxy](http://www.castleproject.org/dynamicproxy/index.html) for example) to intercept the call, run whatever code you wish, and then either invoke your method or not, depending on your needs.
[ -0.11604880541563034, -0.40508517622947693, 0.5075544714927673, 0.13328129053115845, 0.10676287114620209, -0.010710256174206734, 0.3475942015647888, -0.051036734133958817, -0.13959605991840363, -0.12082237005233765, -0.4877152740955353, 0.18822696805000305, -0.519819974899292, 0.4303782880...
I have TortoiseSVN set up to use KDiff3 as the conflict resolution tool (I find it shows more information useful to the merge than the built-in TortoiseMerge does). When I open a file with Tortoise's "Edit Conflicts" command it shows me the three files and I have to select "Merge->Merge Current File" manually. The pro...
[ -0.2359190732240677, 0.03175928443670273, 0.4346098005771637, -0.3896307349205017, -0.062215838581323624, 0.1257721185684204, 0.40951934456825256, -0.427103191614151, -0.46264952421188354, -0.5686900615692139, 0.10784744471311569, 0.9350646138191223, -0.23785637319087982, 0.044488437473773...
but it's about an ancillary process common enough to programmers that it should be useful here. I couldn't find the answer to this elsewhere. Mine is a bit longer: ``` "C:\Program Files\KDiff3\kdiff3.exe" %base %mine %theirs -o %merged --L1 Base --L2 Mine --L3 Theirs ```
[ 0.300515741109848, 0.4314767122268677, 0.30562227964401245, -0.16398578882217407, 0.4280281960964203, 0.24439290165901184, -0.08239375799894333, 0.1173381507396698, -0.046713687479496, -0.38161197304725647, 0.011070960201323032, 0.23567523062229156, 0.24789105355739594, 0.14246833324432373...
How would you begin improving on a really bad system? Let me explain what I mean before you recommend creating unit tests and refactoring. I could use those techniques but that would be pointless in this case. Actually the system is so broken it doesn't do what it needs to do. For example the system should count how...
[ 0.5459832549095154, 0.34125205874443054, -0.10131676495075226, 0.2330998033285141, -0.09010118246078491, 0.06524088978767395, 0.6218838095664978, -0.2735712230205536, -0.4298749268054962, -0.5740275979042053, 0.3681979775428772, 0.5446507334709167, -0.017731141299009323, 0.2780676484107971...
as a whole would become worse than it is currently. The solution could be to modify all the modules and remove their own corrections, but with 150+ modules that would require so much coordination that I can not afford it. Even worse, there are some problems that has workarounds not in the system itself, but in people'...
[ 0.2901795506477356, 0.2510586977005005, 0.248355433344841, 0.07521525770425797, 0.11933186650276184, 0.22776669263839722, 0.4803496301174164, -0.25851166248321533, -0.8202357888221741, -0.5628204345703125, 0.0003869346110150218, 0.27345794439315796, -0.32359230518341064, 0.2103136330842971...
the message groups and multiply it by 5/4 to get the correct number of the messages. There is absolutely no documentation about these deviations and nobody knows how many such things are present in the system now. So how would you begin working on improving this system? What strategy would you follow? A few additiona...
[ 0.536146879196167, 0.06071466952562332, 0.24143046140670776, 0.12250490486621857, -0.12182127684354782, 0.20659588277339935, 0.5730248689651489, -0.0709831565618515, -0.5792202949523926, -0.4998953640460968, 0.10557831078767776, 0.1581321507692337, -0.19515423476696014, -0.0367840006947517...
myself in a couple of years. Some technical details: the system is written in Java and PHP but I don't think that really matters. There are two databases behind it, an Oracle and a PostgreSQL one. Besides the flaws mentioned before the code itself is smells too, it is really badly written and documented. Additional i...
[ 0.5554223656654358, 0.3630691468715668, 0.15092171728610992, 0.024399014189839363, 0.029669906944036484, -0.15063658356666565, 0.415444016456604, -0.013142498210072517, 0.000052623658120865, -0.2907545566558838, 0.30015820264816284, 0.39545124769210815, -0.15204453468322754, -0.01610162295...
aspect for the modules that need it, making impossible to forget it later. I have no problems with fixing things like this, but if I would make this change I would break over 10 other modules. Update: I accepted Greg D's answer. Even if I like Adam Bellaire's more, it wouldn't help me to know what would be ideal to k...
[ 0.5826240181922913, -0.02142718806862831, 0.24432668089866638, 0.11800660192966461, -0.13771186769008636, -0.056202925741672516, 0.3697064518928528, -0.21325194835662842, -0.5441349148750305, -0.72867351770401, -0.2951350510120392, 0.7070333361625671, -0.016752256080508232, -0.185134187340...
improve it going forward. This is your sales technique targeted at whomever you're reporting to. 2. **Pick some low-hanging fruit.** I assume you're relatively new to this particular software and that you were re-tasked to deal with it. Find some apparently easy problems in a related subsystem of the code that shouldn'...
[ 0.47587084770202637, 0.08741604536771774, -0.10125474631786346, 0.0565645657479763, 0.13496313989162445, -0.008514213375747204, 0.3342107832431793, 0.3672223389148712, -0.03612503409385681, -0.7852197289466858, -0.1788189560174942, 0.784935712814331, 0.1551097333431244, -0.3959733247756958...
who worked on my system before me always post-fixed his comments with four punctuation marks instead of one, which made it very easy to distinguish who wrote the particular segment of code.), but you'll develop insight into the author's weaknesses so you know what to look out for. Extensive, tight coupling with global ...
[ 0.5167157053947449, 0.017108596861362457, 0.03783359006047249, 0.12319070100784302, -0.33845531940460205, 0.1318587213754654, 0.7787291407585144, -0.055788006633520126, -0.27771636843681335, -0.6550583839416504, -0.10230723023414612, 0.3861490786075592, -0.14239981770515442, 0.077250771224...
With the experience you've gained understanding the component and knowledge about what the original author likely did wrong (and thus, what you need to watch out for), you can start envisioning a better model for this subset of the system. Don't worry if you still have to maintain some messy interfaces to maintain func...
[ 0.546771228313446, -0.020295927301049232, 0.23391678929328918, 0.4491826891899109, 0.23167477548122406, 0.10897376388311386, 0.4325428307056427, -0.16023658215999603, -0.19400392472743988, -0.8648555278778076, 0.37749212980270386, 0.7071346044540405, -0.0664498582482338, 0.0519469641149044...
them in a future iteration. Addressing the particular issues you mention: When you run into a situation that users are working around manually, *talk with the users* about changing it. Verify that they'll accept the change if you provide it before sinking the time into it. If they don't want the change, your job is t...
[ 0.5265316367149353, 0.08745779097080231, 0.2745914161205292, 0.3880731761455536, 0.14532966911792755, 0.3856828510761261, 0.4320794343948364, -0.1922796070575714, -0.33025816082954407, -0.7426199316978455, -0.030028490349650383, 0.7238109707832336, -0.2529991567134857, 0.025714211165905, ...
component into the codebase. When you touch external components that work around the broken one, try to replace the old component with the new one. Similar interfaces ease porting of the code, and the old component is still around if the new one fails. Don't remove the old component until you can.
[ 0.2326851487159729, -0.023796776309609413, 0.3307553827762604, 0.2914452850818634, -0.06239178776741028, -0.20990929007530212, 0.19763509929180145, -0.11082230508327484, -0.20749807357788086, -0.8380836844444275, -0.00995479803532362, 0.5711187124252319, -0.30739179253578186, 0.16469787061...
What's the best way to connect to a Informix database from .Net? I'm developing a client-server application based on a legacy Informix DB which used to be connected by JDBC. I need it, from the most important to the least: 1. To be fast 2. DB server changes not needed 3. No ODBC and no dependencies, other than de .N...
[ 0.5031640529632568, -0.0009752645855769515, 0.15474088490009308, 0.3637795150279999, -0.0740918442606926, -0.21363675594329834, 0.032990988343954086, 0.05184981971979141, -0.14413097500801086, -0.9835067987442017, 0.1246248111128807, 0.3658248484134674, -0.35052353143692017, 0.112846672534...
I have a SVN repository for my project; it keeps code, docs, graphs, etc. Everything related to the project is there and versioned. However, I am trying to get some kind of intelligent stats for my code. The stat program I am using is StatSVN - they seem to be best of breed as far as I can tell. However, I am getting r...
[ 0.59487384557724, 0.17405647039413452, 0.16745537519454956, 0.37595370411872864, -0.2580544948577881, -0.08518139272928238, 0.09353318810462952, 0.18516147136688232, -0.43573233485221863, -0.6874915361404419, 0.3286525011062622, 0.29536834359169006, 0.16410277783870697, 0.03862945362925529...
but I'm fearing that might be the best idea at the moment... I built StatSVN and currently maintain it :) You can use exclude based on filenames and folders. Take a look at our [wiki](http://wiki.statsvn.org/User%20Manual.ashx)!
[ 0.7027138471603394, 0.05523207038640976, 0.07789916545152664, 0.17534279823303223, -0.21665427088737488, -0.5664745569229126, 0.418751060962677, 0.12663228809833527, -0.3647884130477905, -0.4159734547138214, 0.020321838557720184, 0.022542055696249008, -0.06752083450555801, 0.01143726520240...
I've been researching memory mapped files for a project and would appreciate any thoughts from people who have either used them before, or decided against using them, and why? In particular, I am concerned about the following, in order of importance: * concurrency * random access * performance * ease of use * portabi...
[ 0.3167729377746582, 0.2289646416902542, -0.024509049952030182, 0.19392214715480804, -0.06889461725950241, -0.4490702152252197, -0.03133304417133331, 0.10791230201721191, -0.426040917634964, -0.7470142245292664, -0.19622305035591125, 0.7342188954353333, -0.059271275997161865, 0.176865577697...
typically involves the kernel copying the data from its own buffers into user space. This extra copying not only takes time, but decreases the effectiveness of the CPU's caches by accessing this extra copy of the data. If the data actually have to be read from the disc (as in physical I/O), then the OS still has to re...
[ -0.04315892234444618, -0.015735464170575142, 0.08253467828035355, 0.34277796745300293, 0.24360813200473785, 0.1508435308933258, 0.18767309188842773, 0.13916854560375214, -0.2688727378845215, -0.6352867484092712, -0.5126266479492188, 0.7189074158668518, -0.09159219264984131, 0.1015339791774...
you attempt to access a page which isn't mapped in, it generates a page fault then makes the thread wait for the I/O. --- The obvious disadvantage to memory mapped files is on a 32-bit OS - you can easily run out of address space.
[ -0.19443131983280182, 0.08140423148870468, -0.0015396681847050786, 0.27625590562820435, -0.045371320098638535, -0.21113404631614685, 0.4207281172275543, 0.1514669805765152, -0.3381306529045105, -0.6665909886360168, -0.24162577092647552, 0.22345438599586487, -0.1699872463941574, 0.246492326...
I have a controller method that returns a list for a drop down that gets rendered in a partial, but depending on where the partial is being used, the RJS template needs to be different. Can I pass a parameter to the controller that will determine which RJS gets used? Here is the controller method, it is very simple: ...
[ 0.15589018166065216, -0.15053606033325195, 0.6959604024887085, 0.00523690041154623, 0.027317117899656296, 0.2739001512527466, 0.059656962752342224, -0.38975241780281067, -0.187782421708107, -0.7305094003677368, 0.11239704489707947, 0.2753606140613556, -0.1894494742155075, 0.413909465074539...
here is the rjs template the gets rendered automatically ``` page.replace_html 'select_service', :partial => 'hospital/services' page.replace_html 'select_condition', :partial => 'hospital/conditions' page.replace_html 'select_procedure', :partial => 'hospital/procedures' page << 'if ($("chosenType") != null) {' pa...
[ -0.17803628742694855, -0.06953874975442886, 0.9045408964157104, -0.22074683010578156, -0.006451989524066448, 0.2636074423789978, 0.42824310064315796, -0.567150354385376, -0.14750991761684418, -0.9870136380195618, -0.2579364478588104, 0.6907830238342285, -0.09913524985313416, 0.164554581046...
I am a college student at a school that teaches mainly in Java. One of the strong points of Java, which I quite enjoy, is the large collection of libraries. What makes these libraries especially useful is the extensive documentation and organization presented via JavaDoc. Are there any library collections for Common Li...
[ 0.2671049237251282, 0.4514114558696747, -0.23631151020526886, 0.013254407793283463, -0.013176528736948967, -0.44865110516548157, 0.1872251182794571, 0.28353074193000793, -0.32865485548973083, -0.5764561891555786, 0.031147250905632973, 0.4436393976211548, -0.03923803195357323, -0.0503972359...
you're interested in helping the Lisp community, this may well be the thing to attack first. Also, while there are [various JavaDoc equivalents](http://www.cliki.net/Documentation%20tool), there is no widely accepted quasi-standard as for Java.
[ 0.318257600069046, -0.20825788378715515, -0.0931057259440422, 0.07339175045490265, -0.19164025783538818, -0.4345777928829193, 0.12874630093574524, 0.09817172586917877, -0.318584680557251, -0.17415449023246765, -0.10306594520807266, 0.5947105288505554, -0.4286755621433258, -0.44356575608253...
Take this non-compiling code for instance: ``` public string GetPath(string basefolder, string[] extraFolders) { string version = Versioner.GetBuildAndDotNetVersions(); string callingModule = StackCrawler.GetCallingModuleName(); return AppendFolders(basefolder, version, callingModule, extraFolders); } priv...
[ 0.005899072624742985, -0.29024210572242737, 0.6017387509346008, -0.2760019302368164, -0.02079550176858902, 0.2583271861076355, 0.44233042001724243, -0.623741090297699, -0.511474072933197, -0.43405991792678833, -0.3213379383087158, 0.698298990726471, -0.5878333449363708, 0.00416076369583606...
version of testing code I am using. Please, I am only interested in solutions having directly to do with the param keyword. I know how lists and other similar things work. Is there a way to "explode" the extraFolders array so that it's contents can be passed into AppendFolders along with other parameters? One option i...
[ 0.46928876638412476, 0.0214912798255682, 0.2218141406774521, 0.27220848202705383, -0.06958287209272385, 0.1768922060728073, 0.32564207911491394, -0.5024359226226807, -0.2872307002544403, -0.3627953827381134, 0.08271567523479462, 0.47364869713783264, -0.6165019869804382, -0.0247257966548204...
,(f is string[]) ? appendFolders((object[])f)
[ -0.33180779218673706, 0.07325173914432526, 0.4803731441497803, -0.1332024335861206, -0.1175878643989563, 0.345348596572876, 0.10600041598081589, -0.4093099534511566, -0.29364389181137085, -0.033240366727113724, -0.43632790446281433, 0.47906917333602905, -0.5108084678649902, -0.146882444620...
: ((string)f).TrimStart('\\'))); } ``` If you want something more strongly-typed, another option is to create a custom union type with implicit conversion operators: ``` static string appendFolders(params StringOrArray[] folders) { return folders.SelectMany(x=>x.AsEnumerable()) .Aggregat...
[ -0.014886577613651752, -0.3828269839286804, 0.2728269398212433, -0.0843268409371376, 0.05935061350464821, 0.37891194224357605, 0.20288170874118805, -0.39732322096824646, -0.38313204050064087, -0.4421844482421875, -0.2805042862892151, 0.5970490574836731, -0.5759276747703552, 0.1877765655517...
{ string[] array; public IEnumerable<string> AsEnumerable() { return soa.array;} public static implicit operator StringOrArray(string s) { return new StringOrArray{array=new[]{s}};} public static implicit operator StringOrArray(string[] s) { return new StringOrArra...
[ -0.06933262199163437, -0.27461424469947815, 0.5235388875007629, -0.38767674565315247, 0.058022160083055496, 0.17957650125026703, 0.31959936022758484, -0.5971395969390869, -0.29227378964424133, -0.40902575850486755, -0.49219340085983276, 0.6334125995635986, -0.38872194290161133, 0.139620020...
In [@mmalc's](https://stackoverflow.com/users/23233/mmalc) [response](https://stackoverflow.com/questions/155964/what-are-best-practices-that-you-use-when-writing-objective-c-and-cocoa#156288) to [this question](https://stackoverflow.com/questions/155964/what-are-best-practices-that-you-use-when-writing-objective-c-and...
[ 0.36834049224853516, 0.2695591151714325, 0.13504546880722046, 0.045732829719781876, -0.19725748896598816, -0.5573175549507141, 0.09807009249925613, -0.3605591356754303, -0.31653520464897156, -0.3221731185913086, -0.26592957973480225, 0.580392062664032, -0.3192829489707947, -0.1345427185297...
of nasty issues. The catch is that there is no reason init has to setup the default state of a property. For a number of reasons I have been moving to accessors that self initialize, like the simple example below: ``` - (NSMutableDictionary *) myMutableDict { if (!myMutableDict) { myMutableDict = [[NSMutab...
[ -0.02096678875386715, 0.26321372389793396, 0.000325118366163224, -0.04589424654841423, -0.0995703861117363, -0.45565661787986755, 0.5148343443870544, -0.0840250626206398, -0.042021285742521286, -0.5106449723243713, -0.2270786613225937, 0.48947179317474365, -0.23449522256851196, 0.332065761...
the properties state, and it is completely safe (even necessary) for one to use the accessors in the init method. Admittedly this does impose additional restrictions on your code, for instance, subclasses with custom accessors for a property in the superclass must call the superclasses accessor, but those restrictions...
[ 0.12618760764598846, -0.07985009253025055, 0.046655524522066116, 0.284086674451828, -0.09829176962375641, -0.3902304172515869, 0.4563670754432678, -0.08612258732318878, -0.2704199552536011, -0.40720197558403015, -0.2512253522872925, 0.43245112895965576, -0.18014730513095856, 0.254205793142...
I'm wondering if there is a website that collects (and hopefully updates) information on available web services. Edit: Thanks for all the info; many good answers. I can only accept 1 as the "accepted answer" at this time, so I picked my favorite one. How about <http://www.programmableweb.com/apis>? It has a fairly la...
[ 0.6996465921401978, -0.10733126103878021, 0.20697535574436188, 0.34052878618240356, -0.04715438559651375, -0.06371566653251648, 0.16265548765659332, 0.2836103141307831, -0.36655569076538086, -0.4614062011241913, -0.04052777960896492, 0.2845262587070465, 0.13387241959571838, 0.2658301293849...
I have just started learning Erlang and am trying out some Project Euler problems to get started. However, I seem to be able to do any operations on large sequences without crashing the erlang shell. Ie.,even this: ``` list:seq(1,64000000). ``` crashes erlang, with the error: eheap\_alloc: Cannot allocate 46707856...
[ 0.07536283880472183, 0.0585453063249588, 0.28775352239608765, 0.08863560110330582, 0.222736656665802, -0.09165451675653458, 0.1608739048242569, -0.060933299362659454, -0.534630537033081, -0.41604191064834595, 0.1818849891424179, 0.6190086603164673, -0.2396073192358017, 0.027354106307029724...
the size of a user process. On Linux you can change this with ulimit. You probably want to iterate over these 64000000 numbers without needing them all in memory at once. Lazy lists let you write code similar in style to the list-all-at-once code: ``` -module(lazy). -export([seq/2]). seq(M, N) when M =< N -> fun...
[ -0.15487365424633026, -0.09290767461061478, 0.21414312720298767, -0.07379384338855743, -0.23649349808692932, 0.15424823760986328, 0.055166274309158325, -0.39547213912010193, -0.7340841889381409, -0.7441923022270203, -0.0751444399356842, 0.4920388162136078, -0.37107691168785095, 0.145323410...
What's proper way to connect ODBC datasources and execute some SQL statements? TQuery and other BDE components can do it, but if I understood correctly they are now deprecated? You can use the ADO components: 1) Drag a TAdoConnection from the dbGo tab. 2) Right click and choose Edit connection string. 3) Click buil...
[ 0.1834888756275177, -0.03314880654215813, 0.5861878395080566, 0.2725614607334137, -0.009447279386222363, -0.33430030941963196, 0.21395500004291534, -0.2524508833885193, 0.14798976480960846, -0.5289863348007202, 0.19985972344875336, 0.5536782145500183, -0.347353994846344, 0.2598639130592346...
Is there a [ZeroConf](http://en.wikipedia.org/wiki/ZeroConf) client extension for Firefox/XULRunner to be used in a zeroConf environment based on either [mDNS](http://files.multicastdns.org/draft-cheshire-dnsext-multicastdns.txt) or [SLP](http://en.wikipedia.org/wiki/Service_Location_Protocol)? I know of an extension ...
[ 0.416390597820282, 0.1717551201581955, 0.06789733469486237, 0.025029011070728302, -0.011765613220632076, -0.0035976360086351633, -0.010157018899917603, 0.045154325664043427, -0.09006457030773163, -0.26008549332618713, 0.01984163373708725, 0.37150487303733826, -0.16263985633850098, -0.21867...
to pay for domains by making a credit to your account, then buying the domain from there. I don't think there are any limits on how small this initial deposit can be.
[ 1.0023224353790283, 0.11388759315013885, 0.2562224566936493, 0.32754069566726685, 0.28700077533721924, -0.1520577222108841, 0.06502558290958405, 0.2815445065498352, -0.1661738008260727, -0.05052300915122032, 0.42082589864730835, 0.32461419701576233, 0.29057252407073975, 0.2098103016614914,...
I have a home-grown automated build script in the form of a DOS batch file. In part of that script, I check out (with "svn checkout") a section of our SVN repository that includes a bunch of third-party stuff that's used in our projects. This batch file performed pretty well for a long time, but now people have checked...
[ 0.7480661869049072, 0.4959069490432739, -0.09804859012365341, 0.002129731699824333, 0.2510972023010254, -0.10000678896903992, -0.05795145407319069, 0.07172651588916779, 0.08022771030664444, -0.7665415406227112, 0.18769267201423645, 0.5180259346961975, 0.07953528314828873, 0.024922182783484...
our case. So, my question is this: what's the best way to check out an SVN repository filtered by file extension? I didn't see any obvious way to do this in the svn help. I have a .NET utility library that wraps svn.exe in some ways, and I was thinking of extending this to retrieve only content that matched my extensi...
[ 0.39713913202285767, -0.045652855187654495, 0.12760062515735626, 0.19274376332759857, 0.15222716331481934, -0.16359084844589233, -0.041319601237773895, -0.16859343647956848, -0.032078541815280914, -0.564254105091095, 0.061541952192783356, 0.6915382146835327, -0.14381009340286255, -0.044193...
like: 1. `svn checkout svn://path/to/repos/directory --depth empty` 2. `svn list --recursive svn://path/to/repos/directory` 3. Pipe that result through a filter that removes the forbidden file extensions, e.g. `grep` 4. Iterate over this new filtered list and `svn update --parents` each file That would give your desi...
[ 0.46895885467529297, -0.1514931172132492, 0.2569867968559265, 0.03718074411153793, 0.02444593422114849, -0.3261639475822449, 0.2555086016654968, -0.1804596483707428, -0.17605161666870117, -0.632861316204071, -0.2468414008617401, 0.4983832538127899, -0.45028331875801086, 0.13278722763061523...
Is it possible to get the machine name, or IP, or MAC address (basically client network information) from javascript running Internet Explorer? I found the following code that seems to accomplish this: ``` function Button1_onclick() { var locator = new ActiveXObject("WbemScripting.SWbemLocator"); var service = lo...
[ -0.3307904005050659, -0.21926817297935486, 0.7844066023826599, -0.1609787791967392, 0.33634713292121887, -0.002356023760512471, 0.34557396173477173, -0.31842041015625, -0.40673184394836426, -1.0251544713974, -0.3831104338169098, 0.5056182146072388, -0.3804906904697418, 0.21739201247692108,...
+ "</td>"); document.write("<td>" + p.IPFilterSecurityEnabled + "</td>"); document.write("<td>" + p.IPPortSecurityEnabled + "</td>"); document.write("<td>" + p.IPXAddress + "</td>"); document.write("<td>" + p.IPXEnabled + "</td>"); document.write("<td>" + p.IPXNetworkNumber + "</...
[ -0.22501157224178314, -0.012179515324532986, 0.6092061400413513, 0.04457227513194084, -0.06805313378572464, 0.09092763066291809, 0.32683518528938293, -0.7807753682136536, -0.09390092641115189, -0.7704495191574097, -0.5179852843284607, 0.5918395519256592, -0.46055200695991516, 0.06618388742...
document.write("</tr>"); } document.write("</table>"); ``` } So it's using an ActiveX Object that seems to be installed with the OS to accomplish this. Is something similar like this possible to do from a terminal service session? To get the terminal service client network information? (Not the terminal server n...
[ 0.13894736766815186, 0.07346789538860321, 0.4879832863807678, 0.10406368225812912, 0.07237625122070312, -0.1569441854953766, 0.13047905266284943, -0.07726495712995529, -0.24118271470069885, -0.9554893374443054, 0.020089782774448395, 0.6062481999397278, -0.36283671855926514, 0.1720669120550...
object. * Use WMI, the `MetaFrame_ICA_Client` class in `root\Citrix` looks promising. Mayor drawback of both solutions is, that they require more user permissions than you might be willing to give. From what I read, at least "Account View" permissions are required within Citrix, but I have no way to test it right now....
[ -0.057450998574495316, -0.009614953771233559, 0.5224261283874512, -0.01674175076186657, 0.20037733018398285, -0.041717469692230225, 0.3674544394016266, -0.25802192091941833, -0.2790565490722656, -0.7753595113754272, -0.23865264654159546, 0.7314286231994629, -0.45957469940185547, 0.24643088...
I'm developing a webapp where the user is given the chance to upload his resume in pdf format. I'm using NHibernate as a data mapper and MS SQL SERVER 2005. I want to be able to save the .pdf file to a given table... any ideas? Thank you very much! We are doing exactly that with the "original" Java Hibernate3. You ju...
[ -0.04788212850689888, -0.17810773849487305, 0.6632140874862671, 0.0030283459927886724, -0.20583198964595795, -0.10563937574625015, 0.14179298281669617, -0.25671595335006714, -0.09375594556331635, -0.7123246788978577, 0.18694710731506348, 0.8110944032669067, -0.38954320549964905, -0.0776295...
public Integer getPdfDocumentId() { return this.pdfDocumentId; } public void setPdfDocumentId(Integer pdfDocumentId) { this.pdfDocumentId = pdfDocumentId; } public byte[] getDocument() { return this.document; }
[ -0.12232933938503265, -0.2470501959323883, 0.8422098159790039, 0.031352318823337555, 0.03594844788312912, 0.057449329644441605, 0.03968879580497742, -0.4715522229671478, -0.07312767207622528, -0.49017539620399475, -0.543644905090332, 0.8300888538360596, -0.29975321888923645, -0.04950282722...
public void setDocument(byte[] document) { this.document = document; } } ``` Hibernate Mapping: ``` <hibernate-mapping> <class name="com.hibernate.pdf.sample.TPDFDocument" table="T_PDFDocument"> <id name="pdfDocumentId" type="integer"> <column name="pdfDocumentId" /> ...
[ 0.12848345935344696, -0.23646192252635956, 0.44815030694007874, 0.1268673539161682, 0.26632922887802124, -0.08745871484279633, -0.06251662969589233, -0.3690018951892853, -0.08361987769603729, -0.5734313726425171, -0.4907602071762085, 0.752455472946167, -0.4084445536136627, 0.07036586105823...
<column name="document" not-null="true" /> </property> </class> </hibernate-mapping> ``` Table creation: ``` CREATE TABLE [dbo].[T_PDFDocument]( [pdfDocumentId] [int] IDENTITY(1,1) NOT NULL, [document] [image] NOT NULL, CONSTRAINT [PK_PDFDocument] PRIMARY KEY CLUSTERED ( [pdfDocumentId] ASC ...
[ -0.1747329980134964, 0.20991304516792297, 0.6917601823806763, 0.019504910334944725, 0.12476431578397751, -0.08925936371088028, 0.06886676698923111, -0.44802919030189514, -0.3666682243347168, -0.7438123822212219, -0.4756404459476471, 0.424191951751709, -0.13345949351787567, 0.04107371717691...
guess with NHibernate implementation and C# the solution will look very similar.
[ -0.017145274206995964, -0.021814614534378052, 0.21145455539226532, -0.25093644857406616, -0.013718965463340282, 0.09325391054153442, -0.055405549705028534, -0.39282408356666565, 0.19911129772663116, -0.6970525979995728, 0.26433125138282776, 0.29537609219551086, -0.24471299350261688, 0.1265...
Visual Studio 2008 SP1 (although IIRC, the behavior was present in 2005 as well) keeps resizing a couple of grid controls (Janus.GridEx to be precise) I use. I can resize them back to normal, save, and compile just fine. When it does compile, these two controls will expand to ridiculous values. More Information: This...
[ -0.41828951239585876, -0.20610275864601135, 0.32836419343948364, -0.10498447716236115, -0.3690040707588196, -0.057945214211940765, 0.1975143551826477, -0.26341572403907776, -0.297247052192688, -0.3703261613845825, 0.13428588211536407, 0.6727437973022461, -0.3983193337917328, -0.25833722949...
the Anchor property is set before the Size property. Manually editing (I know, shame on me) the file to put the Size property first doesn't help as when the Designer file gets compiled, it seems to be rewritten from scratch as well. So I guess my real question is how to make VS form designer respect my initial size de...
[ 0.27997079491615295, 0.09619094431400299, 0.46449893712997437, -0.04725600406527519, 0.0244666188955307, -0.23398037254810333, 0.1300216168165207, -0.4838227331638336, 0.14842650294303894, -0.5604577660560608, -0.01349396351724863, 0.9509441256523132, 0.16263824701309204, 0.124129064381122...
I have some nested tables that I want to hide/show upon a click on one of the top-level rows. The markup is, in a nutshell, this: ``` <table> <tr> <td>stuff</td> .... more tds here </tr> <tr> <td colspan=some_number> <table> </table> </td> </tr> </table> `...
[ 0.311098575592041, -0.05983290821313858, 0.18457534909248352, 0.036311790347099304, -0.4287847578525543, -0.17878882586956024, 0.03829178586602211, -0.11852356791496277, -0.17305229604244232, -0.7451162934303284, 0.022249119356274605, 0.3958805203437805, -0.46700361371040344, 0.01518548652...
table row. When that link is clicked, it pulls some data down, formats it as a bunch of table rows, and appends it to the table inside. Then it applies the .show() to the table. (this is all done via id/class targeting. I left them out of the sample for brevity). This works beautifully in firefox. Click the link, data...
[ -0.08533962070941925, 0.046170081943273544, 0.7559689879417419, -0.14263340830802917, -0.04439401626586914, -0.16845683753490448, -0.11506011337041855, 0.08179512619972229, -0.6045375466346741, -0.8417810797691345, -0.09121840447187424, 0.305277943611145, -0.35305413603782654, 0.1622471511...
that the .show() does not appear to be doing anything useful. To make matters more annoying, I've got a page that has this functionality that is working splendidly in both -- the only difference being two things: In the one that is working, the inner table is wrapped in a div. I've even tried wrapping my table in this...
[ 0.4512391686439514, 0.2186499685049057, 0.2801502048969269, 0.21349327266216278, -0.20671559870243073, -0.13917790353298187, 0.08514929562807083, 0.040809810161590576, -0.32640349864959717, -0.49069297313690186, -0.08176782727241516, 0.4373272955417633, -0.3016114830970764, -0.054260533303...
the .show to the parent tr, parent td, and the table itself with no success. I must be missing something incredibly simple, because as near as I can tell this should work. Has anyone come across something like this before? Keep in mind that the innerHTML of a <table> element is *read-only* in IE(6 for sure, not sure a...
[ 0.32335373759269714, 0.003801808226853609, 0.3663216531276703, 0.06031383201479912, -0.06007518619298935, -0.16414059698581696, 0.246381476521492, 0.02199546992778778, -0.0013432271080091596, -0.8866197466850281, -0.09701574593782425, 0.6102486252784729, -0.37667766213417053, 0.12687402963...
(sort-of) about this: [PRB: Error Setting table.innerHTML in Internet Explorer](http://support.microsoft.com/kb/239832) Note: it says this is "by design".
[ 0.06508667767047882, 0.2415439933538437, 0.06634940952062607, 0.0808863490819931, 0.139010488986969, -0.46187201142311096, 0.38617417216300964, 0.2281937450170517, -0.07584593445062637, -0.31950971484184265, -0.21908818185329437, -0.051170699298381805, -0.21275468170642853, 0.1973630189895...
I have a MSSQL2005 DB with about 140 tables. I want to create either an accessible diagram or a printable API type document with the table structure. Is there a program that offers this kind of db visualization? I find the diagramming built into SQL Server to be very clunky and very inaccessible for my DB size. Take a...
[ 0.11888936907052994, 0.1478281021118164, 0.40174922347068787, -0.22085945308208466, -0.30434101819992065, 0.05503450334072113, 0.15381969511508942, -0.37889111042022705, -0.044878821820020676, -0.8362966179847717, 0.3596632182598114, 0.3647860884666443, -0.30808451771736145, 0.144748285412...
I am trying to build a homebrew web brower to get more proficient at Cocoa. I need a good way to validate whether the user has entered a valid URL. I have tried some regular expressions but NSString has some interesting quirks and doesn't like some of the back-quoting that most regular expressions I've seen use. You co...
[ 0.3046824634075165, 0.37462010979652405, 0.259137362241745, 0.01292060874402523, -0.29512813687324524, -0.10518550872802734, 0.2433272749185562, -0.1630035787820816, -0.09558040648698807, -0.6084203124046326, -0.13090164959430695, 0.40134820342063904, -0.3111271858215332, 0.251698225736618...
evaluate in whatever way you see fit.
[ 0.45669981837272644, 0.5445297360420227, -0.6026466488838196, -0.03406742587685585, -0.2780359089374542, -0.16039010882377625, 0.0727606788277626, 0.4717773497104645, 0.37273579835891724, -0.6888363361358643, -0.08867224305868149, 0.6688516139984131, 0.1331126093864441, -0.2835414111614227...
I am working on a process to allow people to upload PDF files and manage the document (page order) via a web based interface. The pages of the PDF file need to be cropped to a particular size for printing and currently we run them through a Photoshop action that takes care of this. What I want to do is upload the PDF...
[ 0.5447713732719421, 0.2327287495136261, 0.665291428565979, 0.12166924774646759, -0.01931679993867874, -0.0528356097638607, -0.11154893785715103, -0.2387162148952484, -0.4383793771266937, -0.6903773546218872, 0.09081048518419266, 0.37666818499565125, -0.07610184699296951, -0.060768045485019...
to keep the user informed on how long their files are taking to process. Additionally what are some good techniques for queueing/tracking jobs/processes in general (with an emphasis on web based technologies)? For your second question: you need the [Douglas-Peucker Generalization Algorithm](http://everything2.com/inde...
[ 0.07077436149120331, -0.29491567611694336, 0.13519755005836487, 0.2780897319316864, 0.3594740927219391, -0.22834233939647675, 0.09765979647636414, -0.07530630379915237, -0.5925686359405518, -0.29287189245224, -0.15367741882801056, 0.16519148647785187, -0.31025028228759766, 0.08211314678192...
I've recently created these two (unrelated) methods to replace lots of boiler-plate code in my winforms application. As far as I can tell, they work ok, but I need some reassurance/advice on whether there are some problems I might be missing. (from memory) ``` static class SafeInvoker { //Utility to avoid boiler-...
[ -0.014922289177775383, -0.18288542330265045, 0.2778734862804413, -0.13586962223052979, 0.2991994321346283, -0.027942264452576637, 0.6430981755256653, -0.4179009199142456, 0.024264520034193993, -0.580734133720398, -0.3098752498626709, 0.9347624182701111, -0.29979583621025085, 0.135765835642...
else cmd(); } //Replaces OnMyEventRaised boiler-plate code //Usage: SafeInvoker.RaiseEvent(this, MyEventRaised) public static void RaiseEvent(object sender, EventHandler evnt) { var handler = evnt; if (handler != null) handler(sender, EventArgs.Empty); } ...
[ 0.06314194947481155, -0.12564882636070251, 0.3861803412437439, 0.008253305219113827, 0.220077246427536, -0.05322834104299545, 0.3597034811973572, -0.5529035329818726, -0.3212193250656128, -0.12637145817279816, -0.20727558434009552, 0.5964027047157288, -0.2784915566444397, 0.315812140703201...
question](https://stackoverflow.com/questions/2055960/control-invoke-getting-stuck-in-hidden-showdialog)), I have switched from Invoke to BeginInvoke (see an explanation [here](https://stackoverflow.com/questions/229554/whats-the-difference-between-invoke-and-begininvoke/229558#229558)). **Another Update** Regarding ...
[ 0.05270887538790703, 0.008277429267764091, 0.3188241720199585, -0.18093106150627136, -0.13173848390579224, -0.08853445947170258, 0.03035261109471321, -0.38855597376823425, -0.29478248953819275, -0.458658367395401, -0.2792211174964905, 0.4306904375553131, -0.10677900165319443, 0.37161040306...
if (eventHandler != null) eventHandler(sender, EventArgs.Empty); } ``` Now on your events you can call: myEvent.Raise(this);
[ -0.2350746989250183, -0.04103256016969681, 0.2992148995399475, -0.36863961815834045, 0.11395429819822311, -0.13160961866378784, 0.15219534933567047, -0.11834600567817688, -0.42431679368019104, -0.5442886352539062, -0.26051852107048035, 0.6276625394821167, -0.45061999559402466, 0.1520671546...
Languages like C and even C# (which technically doesn't have a preprocessor) allow you to write code like: ``` #DEFINE DEBUG ... string returnedStr = this.SomeFoo(); #if DEBUG Debug.WriteLine("returned string =" + returnedStr); #endif ``` This is something I like to use in my code as a form of scaffolding, and ...
[ 0.41121357679367065, -0.04412398114800453, -0.05740222707390785, -0.08547472208738327, -0.31269681453704834, -0.5172591805458069, 0.3937148451805115, 0.256633460521698, -0.2040310502052307, -0.42237865924835205, -0.0693458691239357, 0.22674071788787842, -0.40809166431427, -0.01752819120883...
definitely whip up something quickly (and perhaps a regex parse to strip it out later if you wanted). i'd do it as such: ``` define('DEBUG', true); ... if (DEBUG): $debug->writeLine("stuff"); endif; ``` of course you'd have to write your own debug module to handle all that. if you wanted to make life easier on reg...
[ 0.3709152042865753, -0.2700866162776947, -0.22764992713928223, -0.08901479840278625, -0.2597855031490326, -0.23366907238960266, 0.5419343113899231, 0.20985788106918335, -0.37087130546569824, -0.3750402331352234, -0.0847344622015953, 0.6230920553207397, -0.20054545998573303, 0.1871257722377...
I have been scouring the web for a code sample that shows how to use pbuffer with GLUT but I could not find anything... I am puzzled with the context switching between pbuffer and the rendering window. I guess that I will have to use glutSetWindow to switch between the two rendering surface but I am not too sure abou...
[ 0.2720441222190857, 0.1659986525774002, 0.3285154402256012, 0.08459805697202682, -0.4168468117713928, -0.034425750374794006, 0.2391844242811203, 0.29574793577194214, -0.05453094467520714, -0.7763523459434509, -0.03502616286277771, 0.5896088480949402, -0.25505152344703674, 0.185717180371284...
access them. How you switch between rendering surfaces depends on your platform; on Windows you'd use wglMakeCurrent() and the like. The meta-answer is that you should avoid pbuffers if at all possible - [FBO](http://opengl.org/registry/specs/ARB/framebuffer_object.txt)s provide similar functionality but without this ...
[ 0.0945378839969635, -0.05965227633714676, 0.7081965208053589, 0.268989235162735, -0.14125816524028778, 0.08562888950109482, 0.06276176869869232, -0.14559300243854523, -0.4170640707015991, -1.0740529298782349, -0.142640620470047, 0.5038148760795593, -0.20748566091060638, -0.2426504194736480...
SQL Server (2005/2008) Each of the below statements have the same result. Does anyone know if one outperforms the other? ``` insert into SOMETABLE values ('FieldOneValue','FieldTwoValue',3,4.55,'10/10/2008 16:42:00.000') insert into SOMETABLE select 'FieldOneValue','FieldTwoValue',3,4.55,'10/10/2008 16:42:00.0...
[ -0.27899253368377686, 0.08309566229581833, 0.35970935225486755, -0.1953892856836319, -0.1963396519422531, -0.01900765486061573, 0.0987413078546524, -0.19222582876682281, 0.11411628127098083, -0.21099461615085602, 0.44996440410614014, 0.5129082798957825, -0.0503685362637043, -0.068325534462...
with 1GB. Result: They appear to be the same. The query plans for these are the same, and the performance differential is statistically insignificant.
[ 0.002672901377081871, -0.05385015159845352, 0.30617234110832214, 0.23414888978004456, -0.15416471660137177, 0.22885073721408844, 0.08500675857067108, -0.39655303955078125, -0.35418975353240967, -0.5505427718162537, 0.033853478729724884, 0.46289151906967163, -0.19860543310642242, -0.0334930...
Java process control is notoriously bad - primarily due to inadequate support by the Java VM/JDK classes (e.g. java.lang.Process). I am wondering, are there any good open source libraries out there that are reliable. The requirements would be: 1. OSS 2. Start/Stop processes 3. Manage STDIN and STDOUT 4. cross platfo...
[ -0.06655516475439072, -0.003224397310987115, 0.25005388259887695, 0.13565631210803986, 0.008397672325372696, -0.28236061334609985, 0.15716712176799774, -0.046144064515829086, -0.08945309370756149, -0.535609245300293, -0.10032489150762558, 0.3033406138420105, -0.25662124156951904, 0.2357227...
products (Jira, Bamboo, etc), so it's battle tested.
[ 0.4023394286632538, 0.05265779793262482, 0.025275643914937973, 0.1618378609418869, -0.1272292584180832, 0.15007257461547852, 0.07273948937654495, -0.24525761604309082, -0.1325071007013321, -0.28662487864494324, -0.07219277322292328, 0.06960800290107727, 0.30982083082199097, 0.0200964566320...
My automated deployment system updates a latest version of my site trough subversion. Instead of having my live site point to the trunk (which is always almost a work in progress version), I have my live site point to a tag. E.g. I work on trunk and when my v1.0 is finished I create a tag called 1.0 and do a checkout ...
[ 0.5779210329055786, 0.0031512987334281206, 0.5015572309494019, -0.15567664802074432, 0.007125154137611389, -0.07223407179117203, 0.3644672632217407, 0.04028138145804405, -0.2745342552661896, -0.8978412747383118, -0.01690707355737686, 0.4688156545162201, -0.3344227373600006, -0.028462439775...
tag. I could wipe the current live site and do a checkout of this 2.0 tag. Which sounds easy enough, however. My site is about 1GB is size because it has all kinds of PDF documents and video in it. I can safely say that most of the time I do updates it will be copy changes or bug fixes. This means that maybe only 1% o...
[ 0.5164887309074402, 0.09004797041416168, 0.6127821207046509, 0.06974008679389954, 0.018060412257909775, -0.4469507932662964, 0.3201146721839905, -0.06168428435921669, -0.3959061801433563, -0.712516725063324, -0.0667315199971199, 0.7165846824645996, -0.3016722798347473, 0.08752617239952087,...
and over again. Is there an easy way to switch between tags and have subversion only update the differences between those tags? There actually is a switch function that does just that. I use TortiseSVN which is a windows shell/gui for Subversion, so I'm not familiar with how to do it manually, but this looks like it s...
[ 0.4761981666088104, -0.19001902639865875, 0.3391146957874298, -0.003834653412923217, -0.13528358936309814, -0.17724086344242096, 0.2814117968082428, 0.12819555401802063, -0.41088151931762695, -0.5094486474990845, 0.2836741805076599, 0.7206517457962036, -0.22003284096717834, -0.075865998864...
What is the best way to **display** and **print** XPS files in a Windows Forms application? I think the easiest way is to use WPF, you can host a WPF control inside a WinForms application - you don't have to rewrite your GUI in WPF or anything like that. more information here : <http://msdn.microsoft.com/en-us/library...
[ 0.29027730226516724, -0.10497730225324631, 0.40020692348480225, 0.3430883586406708, -0.008882694877684116, -0.22564400732517242, 0.11692679673433304, -0.1474343091249466, -0.2170300930738449, -0.7692103981971741, 0.10902135819196701, 0.4790400564670563, -0.045152656733989716, -0.1973572969...
Just wondering if it's possible to screen grab a page you are viewing with a PHP script or javascript? For example, load up a page in an iframe and then save that view as a JPEG? I'm sure it's possible somehow, but are there any known implementations/libraries that help out? <http://html2canvas.hertzen.com/> might do ...
[ 0.5100961923599243, -0.17218828201293945, 0.011557291261851788, 0.2893926501274109, -0.15443956851959229, -0.05928618833422661, 0.150960773229599, 0.39579036831855774, -0.40123504400253296, -0.47432228922843933, 0.11493171751499176, 0.31391483545303345, 0.17102903127670288, 0.0394231602549...
Assuming a Read Committed Snapshot transaction isolation setting, is the following statement "atomic" in the sense that you won't ever "lose" a concurrent increment? ``` update mytable set counter = counter + 1 ``` I would assume that in the general case, where this update statement is part of a larger transaction, ...
[ 0.28219959139823914, 0.14202697575092316, 0.23625382781028748, 0.04541550204157829, 0.19759167730808258, -0.24112194776535034, 0.27057603001594543, -0.190481498837471, -0.3919495940208435, -0.3313900828361511, 0.0165413785725832, 0.45483720302581787, -0.4319027364253998, 0.2788198590278625...
that is the only statement in a transaction? How does a site like stackoverflow handle this for its question view counter? Or is the possibility of "losing" some increments just considered acceptable? Read Committed Snapshot only deals with locks on selecting data from tables. In t1 and t2 however, you're UPDATEing t...
[ 0.06814054399728775, -0.09386046230792999, 0.26572591066360474, 0.11484291404485703, -0.15352247655391693, -0.11532793194055557, 0.02664593607187271, -0.46360868215560913, -0.569756031036377, -0.1114196851849556, -0.15921717882156372, 0.6401007771492004, -0.4225984513759613, 0.109067067503...
to your timeline). Only one of the transactions will get to update the counter, therefore both will update the counter correctly given the code presented. (tested) * counter = 0 * t1 update counter (counter => 1) * t2 update counter (blocked) * t1 commit (counter = 1) * t2 unblocked (can now update counter) (counter =...
[ 0.19150175154209137, -0.18126799166202545, 0.2949259877204895, 0.03411641716957092, 0.27528849244117737, -0.03183763846755028, 0.4917137920856476, -0.333910197019577, -0.45386722683906555, -0.38182076811790466, -0.03440142050385475, 0.4963291585445404, -0.32118239998817444, 0.2571482956409...
can either use a repeatable read lock, or if you only sometimes will update the counter, you can do it yourself using an optimistic locking technique. e.g. a timestamp column with the counter table, or a conditional update. ``` DECLARE @CounterInitialValue INT DECLARE @NewCounterValue INT SELECT @CounterInitialValue =...
[ 0.26525211334228516, -0.17437110841274261, 0.5545900464057922, -0.031241757795214653, 0.24762088060379028, -0.12759089469909668, 0.4310265779495239, -0.4248012602329254, -0.12487410008907318, -0.5336522459983826, -0.11754535138607025, 0.6184470057487488, -0.2021281123161316, 0.218187958002...
rollback if the update affected no rows IF( @@ROWCOUNT = 0 ) ROLLBACK ``` This [devx](http://www.devx.com/codemag/Article/21570) article is informative, although it talks about the features while they were still in beta, so it may not be completely accurate. --- update: As Justice indicates, if t2 is a nested t...
[ -0.07750611752271652, -0.21539029479026794, 0.3511592149734497, -0.14675113558769226, -0.1777723729610443, 0.0012650176649913192, 0.15037523210048676, -0.5428157448768616, -0.31770309805870056, -0.5126128196716309, -0.22246286273002625, 0.5582391619682312, -0.4816761612892151, 0.0669518560...
=> 2) * t2 commit * t1 commit (counter = 2) With a nested transaction, if t1 issues ROLLBACK after t1 COMMIT, counter returns to it's original value because it also undoes t2's commit.
[ 0.06435084342956543, -0.32130447030067444, 0.042437970638275146, -0.31526681780815125, -0.05246838927268982, 0.08849437534809113, 0.38526734709739685, -0.6724080443382263, -0.3253059387207031, -0.33846259117126465, -0.2650532126426697, 0.2805136740207672, -0.5356393456459045, 0.12227802723...
We're currently running an `svnserve` instance as NT service. While this works, it's needlessly cumbersome to administer, and I'd like to move on to the much simpler VisualSVN Server. (Bonus side benefits include Windows-integrated authentication and, thanks to HTTP/WebDAV, browsing of the latest revision.) That said,...
[ 0.0831977128982544, 0.3026829957962036, 0.6555730104446411, -0.023278875276446342, -0.3427712023258209, -0.08878650516271591, 0.36258602142333984, 0.11340124905109406, -0.3380822539329529, -0.7719847559928894, -0.12334567308425903, 0.6014743447303772, -0.005261017940938473, 0.4574677646160...
repository (and no real need for more), so the repository name in `/Repos` shouldn't be there either — we could turn this off with `svnserve`, so there should be a way to do it now, too. * Is it possible to configure VisualSVN Server to drop the `/svn`? (Why is it there to begin with?) * Given that there is only one r...
[ 0.27145493030548096, -0.14839385449886322, 0.36607882380485535, 0.4345132112503052, -0.11895326524972916, -0.1041259765625, 0.2356574833393097, 0.14831310510635376, -0.4503476917743683, -0.4692801535129547, -0.28925588726997375, 0.49430257081985474, -0.005112818442285061, 0.214581578969955...
the counter you escalate to a write lock (on the row), preventing the other update from occurring. t2 could read, but t2 will block on its UPDATE until t1 is done, and t2 won't be able to commit before t1 (which is contrary to your timeline). Only one of the transactions will get to update the counter, therefore both w...
[ 0.10021289438009262, -0.1514989286661148, 0.45023369789123535, 0.0809415653347969, 0.0469960942864418, -0.004397167824208736, 0.3248729109764099, -0.6677083373069763, -0.5127297043800354, -0.36294957995414734, 0.03681652992963791, 0.5388334393501282, -0.37625277042388916, 0.199859321117401...
means you can only read committed values, but it doesn't mean you have Repeatable Reads. Thus, if you use and depend on the counter variable, and intend to update it later, you're might be running the transactions at the wrong isolation level. You can either use a repeatable read lock, or if you only sometimes will u...
[ 0.3185693025588989, -0.12239741533994675, 0.23464591801166534, -0.05673876777291298, 0.3701421916484833, -0.14878520369529724, 0.377533495426178, -0.3696592450141907, -0.2849057614803314, -0.4089405834674835, 0.0745118036866188, 0.6250537037849426, -0.40821772813796997, 0.21248865127563477...
value UPDATE MyTable SET counter = counter + 1 WHERE MyID = 1234 AND counter = @CounterInitialValue -- prevents the update if counter changed. -- the value of counter must not change in this scenario. -- so we rollback if the update affected no rows IF( @@ROWCOUNT = 0 ) ROLLBACK ``` This [devx](htt...
[ 0.11227907985448837, 0.12308425456285477, 0.767670214176178, -0.10905957967042923, -0.009613430127501488, -0.10315301269292831, 0.24314860999584198, -0.4525826871395111, -0.13264328241348267, -0.4236125648021698, 0.017758822068572044, 0.5502210259437561, -0.23815950751304626, 0.12091469764...
counter correctly (+2) because from t2's perspective inside t1, counter was already updated once. The nested t2 has no access to what counter was before t1 updated it. * counter = 0 * t1 update counter (counter => 1) * t2 update counter (nested transaction) (counter => 2) * t2 commit * t1 commit (counter = 2) With a ...
[ -0.09148450195789337, -0.18835806846618652, 0.29480791091918945, -0.2860413193702698, -0.043652452528476715, 0.03314376249909401, 0.42821505665779114, -0.8474531769752502, -0.26482218503952026, -0.2570400834083557, -0.15332593023777008, 0.4682452380657196, -0.41681158542633057, 0.066757790...
I'd like to create a tree structure from JSON, but with multiple columns that can be sorted. I've seen lots of implementations of trees and grids but never one mixed. Does anyone know of a plugin or feature for any Javascript toolkit that can make this happen so I don't have to re-invent the wheel here? This seems pre...
[ 0.55450838804245, 0.00110585056245327, 0.2055722326040268, 0.05331872031092644, -0.27157875895500183, 0.18226546049118042, 0.25126591324806213, -0.016083689406514168, -0.17449983954429626, -0.4647616147994995, 0.16554518043994904, 0.33981096744537354, -0.4868982136249542, 0.080969691276550...
Is it possible to break at runtime when a particular file has been modified? ie. monitor the file and break into a debugger once a change has been made to it. This is for a windows app...is this possible in visual studio or windbg? edit: i should have mentioned that this is for a Win32 app.. you can use the System....
[ 0.2146947681903839, -0.10286827385425568, 0.3662686049938202, -0.01680747978389263, 0.27872443199157715, -0.2204967886209488, 0.5132714509963989, -0.3209529519081116, -0.550829291343689, -0.6992611885070801, -0.4184766113758087, 0.5931729674339294, -0.6776889562606812, 0.007266240194439888...
is modified, you get an alert (you can use both a Debug class or Trace class to output data). Moreover the FileSystemWatcher class has more events (Renamed, Deleted, Created).
[ 0.1766003668308258, -0.547616183757782, 0.31273153424263, 0.2240942418575287, 0.13300666213035583, -0.3162892758846283, 0.10620416700839996, -0.040166474878787994, -0.530900239944458, -0.5113995671272278, -0.29267463088035583, 0.3963773846626282, -0.4192191958427429, 0.35960495471954346, ...
As I recall `BOOST_MPL_ASSERT` was once preferred. Is this still true? Anyone know why? *[Answering my own question]* It depends. This is an apples to oranges comparison. Although similar, these macros are NOT interchangeable. Here's a summary of how each works: `BOOST_STATIC_ASSERT( P )` generates a compilation erro...
[ 0.08746421337127686, -0.020056139677762985, 0.07972712069749832, -0.1468248963356018, -0.20426857471466064, 0.014082967303693295, 0.3067939281463623, -0.1895648092031479, -0.30810144543647766, -0.10744837671518326, -0.008783773519098759, 0.938653290271759, -0.2517831027507782, -0.264768183...
these macros: ``` #include <boost/static_assert.hpp> #include <boost/mpl/assert.hpp> #include <type_traits> using namespace ::boost::mpl; using namespace ::std::tr1; struct A {}; struct Z {}; int main() { // boolean predicates BOOST_STATIC_ASSERT( true ); // OK BOOST_STATIC_ASSERT( false ); ...
[ -0.26593413949012756, -0.06168672442436218, 0.4361587464809418, -0.37577056884765625, -0.1226821169257164, 0.3006228506565094, 0.19790926575660706, -0.5376082062721252, -0.14547976851463318, -0.032153427600860596, -0.6824031472206116, 0.6122678518295288, -0.39881178736686707, -0.1062879785...