text
stringlengths
0
30.5k
title
stringclasses
1 value
embeddings
listlengths
768
768
code (It's a simple C# function). You can just change the connections and it will work. Of course I only had 3 fields so I hard-coded them. You can do the same for your db schema. ``` protected void btnProcess_Click(object sender, EventArgs e) { //Open the connections to the access and SQL databases string sql...
[ 0.1707373410463333, 0.16308839619159698, 0.5935584902763367, -0.06289010494947433, 0.13437160849571228, 0.04595586284995079, 0.4631975591182709, -0.401269793510437, -0.2505456805229187, -0.7041982412338257, -0.23012542724609375, 0.6860577464103699, -0.6649606823921204, 0.293719083070755, ...
= new SqlCommand("DELETE tablename", cnnSql); cmSql.ExecuteNonQuery(); //Retrieve the data from the Access Database OleDbCommand cmdAcc = new OleDbCommand("SELECT * FROM tablename", cnnAcc); OleDbDataReader drAcc = cmdAcc.ExecuteReader(); using (drAcc) { if (drAcc.HasRows) { ...
[ 0.046366866677999496, -0.012129850685596466, 0.37441286444664, -0.35391029715538025, 0.22245684266090393, 0.04952634125947952, 0.3159756362438202, -0.46512600779533386, -0.5041515231132507, -0.3270432949066162, -0.2831692695617676, 0.48963308334350586, -0.3933265507221222, 0.37241393327713...
{ SqlCommand cmdSql = new SqlCommand("INSERT INTO tablename(Category, Head, Val) VALUES(@cat,@head,@val)",cnnSql); SqlParameter parCat = new SqlParameter("cat",System.Data.SqlDbType.VarChar,150); SqlParameter parHead = new SqlParameter("head",System.Data.SqlDbType.VarCha...
[ -0.473270982503891, -0.07097962498664856, 0.8597657680511475, 0.07027938216924667, -0.34366318583488464, 0.34393009543418884, 0.05000193789601326, -0.25640344619750977, -0.09810557961463928, -0.3768499493598938, -0.08554799109697342, 0.38275542855262756, -0.24553053081035614, 0.39973208308...
parCat.Value = drAcc["Category"].ToString(); parHead.Value = drAcc["Head"].ToString(); parVal.Value = drAcc["Val"].ToString(); cmdSql.Parameters.Add(parCat); cmdSql.Parameters.Add(parHead); cmdSql.Parameters.Add(parVal);
[ -0.5278043150901794, -0.10318821668624878, 0.7323839068412781, -0.08850251138210297, -0.1714542806148529, 0.2530563771724701, -0.005553996190428734, -0.2987080514431, -0.20581236481666565, -0.007056486327201128, -0.5113483667373657, 0.771517276763916, -0.36306503415107727, 0.35607120394706...
cmdSql.ExecuteNonQuery(); } } } lblMsg.Text = "<p /> All Done Kapitone!"; } ```
[ -0.11393671482801437, -0.07411017268896103, 0.43211960792541504, 0.0002589262439869344, 0.2859789729118347, -0.09140641242265701, 0.489388644695282, -0.2977869212627411, -0.3011031150817871, -0.5294415354728699, -0.5293065309524536, 0.430552214384079, -0.15552280843257904, 0.00635427003726...
So I'm learning java, and I have a question. It seems that the types `int`, `boolean` and `string` will be good for just about everything I'll ever need in terms of variables, except perhaps `float` could be used when decimal numbers are needed in a number. My question is, are the other types such as `long`, `double`,...
[ 0.6040357947349548, 0.22486212849617004, -0.32686662673950195, 0.19837364554405212, -0.19923707842826843, 0.05522214248776436, 0.052256207913160324, 0.16346760094165802, -0.2370658963918686, -0.2810301184654236, 0.2553482949733734, 0.5378656983375549, 0.08096925169229507, -0.12819002568721...
for courses: * Use an **int** when you don't need fractional numbers and you've no reason to use anything else; on most processors/OS configurations, this is the size of number that the machine can deal with most efficiently; * Use a **double** when you need fractional numbers and you've no reason to use anything else...
[ -0.013391189277172089, 0.05347718670964241, 0.05958070978522301, 0.12232094258069992, -0.05755217745900154, 0.2893957495689392, 0.21235449612140656, 0.05486442521214485, -0.26611819863319397, -0.48576104640960693, -0.4003872573375702, 0.4242875277996063, 0.19677069783210754, -0.38580751419...
**boolean** when you need a simple "yes/no" flag; * Use a **long** for those occasions where you need a whole number, but where the magnitude could exceed 2 billion (file sizes, time measurements in milliseconds/nanoseconds, in advanced uses for compacting several pieces of data into a single number); * Use a **float**...
[ 0.1951652467250824, -0.10172893106937408, -0.0353781022131443, 0.10738995671272278, -0.23601055145263672, -0.09218619018793106, 0.24500608444213867, -0.29224029183387756, -0.2583271265029907, -0.275491327047348, -0.38367435336112976, -0.043870218098163605, 0.07431922852993011, -0.009169278...
as fast -- it's worth testing this on your processor, though, to find that it's actually the case! [\*] * Use a **short** if you really need 2-byte signed arithmetic. There aren't so many cases... [\*] For example, in Hotspot on Pentium architectures, f[loat and double operations generally take exactly the same time](...
[ 0.04599062725901604, -0.0710245668888092, 0.024648118764162064, 0.11946123093366623, 0.14778545498847961, 0.24578478932380676, 0.08400774002075195, 0.007759890519082546, -0.5817969441413879, -0.5694252848625183, -0.20614352822303772, 0.3257896602153778, -0.14979957044124603, -0.31470161676...
object with a long or double field; * when passing parameters to a method, **every type takes up 4 or 8 bytes on the stack**: you won't save anything by changing a method parameter from, say, an int to a short! (I've seen people do this...) Obviously, there are certain API calls (e.g. various calls for non-CPU intensi...
[ 0.130604088306427, -0.236385315656662, -0.00042888527968898416, 0.08546420186758041, -0.23128408193588257, -0.060033246874809265, 0.34394386410713196, -0.07246772199869156, -0.34854036569595337, -0.4386524260044098, 0.1420263946056366, 0.349566251039505, -0.3012787699699402, 0.146459817886...
I often make a collection field unmodifiable before returning it from a getter method: ``` private List<X> _xs; .... List<X> getXs(){ return Collections.unmodifiableList(_xs); } ``` But I can't think of a convenient way of doing that if the X above is itself a List: ``` private List<List<Y>> _yLists; ..... List<L...
[ 0.060548555105924606, 0.08309297263622284, 0.4026734232902527, 0.0646953359246254, -0.21552293002605438, -0.16129763424396515, 0.1300259679555893, -0.2689669728279114, -0.3831886649131775, -0.6588547229766846, -0.4393931031227112, 0.6848543882369995, -0.4092349410057068, 0.1406096816062927...
@Override protected List<List<T>> delegate() { return Collections.unmodifiableList(input); } @Override public List<T> get(int index) { return Collections.unmodifiableList(delegate().get(index)); } }); } ```
[ 0.1952860802412033, -0.3478630781173706, 0.12118659913539886, 0.22158490121364594, 0.1898089498281479, -0.264390766620636, 0.273799329996109, -0.4609219431877136, -0.2882494330406189, -0.4047921597957611, -0.4607417583465576, 0.7023512721061707, -0.4724137485027313, 0.2998494505882263, -...
Quoting from the [MSDN Link for ValueType Class](http://msdn.microsoft.com/en-us/library/system.valuetype.aspx) > In cases where it is necessary for a value type to behave like an object, a wrapper that makes the value type look like a reference object is allocated on the heap, and the value type's value is copied int...
[ 0.07307349145412445, -0.06243346258997917, 0.384071946144104, 0.012660389766097069, 0.004498232156038284, 0.12268553674221039, 0.054585136473178864, -0.22821660339832306, -0.17792673408985138, -0.5652925968170166, -0.08014100044965744, 0.38113999366760254, -0.32552626729011536, 0.137770563...
> Is the Garbage Collection different for such object? If yes, how? Thanks in advance. The wrapper is a "box"; re garbage collection of boxes - there is **no** difference as far as the grabage collector is concerned. A box is collected with exactly the same rules and treatment as any other object. however, if a value...
[ 0.2592931091785431, -0.40307536721229553, 0.14496739208698273, 0.30508124828338623, -0.2472715973854065, -0.16190996766090393, 0.041377127170562744, -0.4063882827758789, -0.08096495270729065, -0.5106350183486938, -0.3280443847179413, 0.4251658022403717, -0.43290281295776367, -0.18842303752...
for the C#: ``` static int GetInteger() {return 123;} static string TestToString() { int i = GetInteger(); // to prove no cheating return i.ToString(); } static Type TestGetType() { int i = GetInteger(); // to prove no cheating return i.GetType(); } ``` We have the IL: ``` .method private hidebysig ...
[ 0.296102911233902, -0.23494037985801697, 0.23513101041316986, -0.09031770378351212, 0.04639657214283943, 0.0358428992331028, 0.22322049736976624, -0.5352343320846558, 0.033703893423080444, -0.5578171610832214, -0.07070282101631165, 0.6451672315597534, -0.44721701741218567, 0.13703359663486...
L_0008: call instance string [mscorlib]System.Int32::ToString() L_000d: ret } .method private hidebysig static class [mscorlib]System.Type TestGetType() cil managed { .maxstack 1 .locals init ( [0] int32 i) L_0000: call int32 Program::GetInteger() L_0005: stloc.0 L_0006: ldloc.0 ...
[ -0.37619802355766296, -0.20187273621559143, 0.6201637387275696, -0.12771306931972504, 0.09691835194826126, 0.15748383104801178, 0.31584641337394714, -0.41911065578460693, -0.37569183111190796, -0.4756717085838318, -0.32885971665382385, 0.481839120388031, -0.5193897485733032, 0.100445747375...
I am having lot of CPU and IO intensive code in shutdown hook. Some times I see they are not getting executed properly. So Is there any limitation like we should not have lot of code in shutdown hook. Thanks D. L. Kumar Simply No. [Read carefully API](http://java.sun.com/j2se/1.4.2/docs/api/java/lang/Runtime.html#add...
[ 0.6022385358810425, 0.16045330464839935, 0.2197192907333374, -0.001977532636374235, -0.0564531572163105, -0.27133607864379883, 0.1806606501340866, -0.11586286872625351, -0.48784229159355164, -0.6066859364509583, -0.22283315658569336, 0.4716103971004486, -0.2106168270111084, 0.0862614661455...
I've only heard about what UIProgressHUD class do, but i cannot find the implementation of this class or any documentation. Reference to this class can be found in "The iPhone Developer's Cookbook 1st Edition" book, and other articles on the internet: > <http://www.cocoadev.com/index.pl?UIProgressHUD> > > > <http://...
[ 0.23529180884361267, 0.2614394724369049, 0.23456232249736786, 0.12919819355010986, -0.13237953186035156, -0.011392420157790184, 0.3189505934715271, 0.061220504343509674, -0.2876000702381134, -0.5677769184112549, 0.12698280811309814, 0.3490891456604004, 0.2166718989610672, 0.068601205945014...
you're lucky, Apple will approve your app, then change or remove the API in an OS update, angering your customers. If you're unlucky, Apple will reject your app. On the Mac, you can get away with it (at least temporarily). On the iPhone, don't use private APIs, **EVER**. Edit: And since this answer was originally wri...
[ 0.25132861733436584, 0.10362029075622559, 0.38391855359077454, 0.28393810987472534, 0.2774099111557007, 0.0676717683672905, 0.4094143509864807, 0.27872413396835327, -0.269387423992157, -0.3290921747684479, -0.43237945437431335, 0.5257430076599121, -0.42030665278434753, -0.12013915926218033...
"Everything is an object" was one of the first things I learned about Ruby, but in Peter Cooper's *Beginning Ruby: From Novice to Professional*, it is mentioned that "***almost*** everything in Ruby is an object". Can you give me some **examples of *things* that are not objects in Ruby?** The most obvious one that jum...
[ 0.26473820209503174, -0.13636715710163116, -0.09103965014219284, -0.11031749844551086, -0.29414626955986023, -0.34819793701171875, 0.5937193632125854, 0.020751722157001495, -0.40245354175567627, -0.22037911415100098, -0.3776097893714905, 0.1796473115682602, -0.5010640621185303, -0.06255103...
example are operators.
[ 0.11846109479665756, 0.1338157057762146, -0.3325365483760834, 0.08260238915681839, -0.13135400414466858, -0.15916819870471954, 0.09685424715280533, -0.0636834129691124, -0.14909987151622772, -0.6097590327262878, -0.47006356716156006, 0.2780016362667084, -0.34356656670570374, 0.085420131683...
I want to develop a web application (no frameworks) mixing java with groovy. I am using the IDE Netbeans with the plugin. If I start a new Java SE project and add a groovy class, it works with no problems.. but when I create a new java EE project and add a groovy class it can't compile and shows me the following error...
[ -0.02976379543542862, 0.44389164447784424, 0.37259000539779663, -0.22844988107681274, -0.07443594932556152, 0.29195380210876465, 0.36468327045440674, -0.381271630525589, -0.08461606502532959, -0.9201721549034119, 0.04185257479548454, 0.2975790500640869, -0.3536135256290436, 0.1836684793233...
Hroovy h = new Hroovy(); 2 errors /home/webcodei/NetBeansProjects/testeGroovyWeb/nbproject/build-impl.xml:383: The following error occurred while executing this line: /home/webcodei/NetBeansProjects/testeGroovyWeb/nbproject/build-impl.xml:211: Compile failed; see the compiler error output for details. FALHA...
[ -0.05627267807722092, 0.5329874753952026, 0.5727570056915283, -0.0043585230596363544, 0.017027059569954872, 0.09475764632225037, 0.5871960520744324, -0.26691296696662903, -0.19725802540779114, -0.500148594379425, 0.15876518189907074, 0.7067806124687195, -0.1358383297920227, 0.1640298962593...
This has been on my to-do list for a while. What are you generating, anyway?
[ 0.5659981369972229, -0.045817241072654724, 0.008860908448696136, 0.1512182503938675, 0.12077599763870239, -0.20230357348918915, -0.2263665497303009, 0.2150365263223648, -0.155142679810524, 0.06812045723199844, 0.5014345049858093, 0.17164194583892822, 0.005047708749771118, 0.019919687882065...
When developing web parts in SharePoint can I inherit from the existing web parts and override their methods? Or do I always need to start from scratch. Many Thanks If they are not sealed, you can inherit from them. In practise, It might work or not depending on how the web part you want to extend.
[ 0.6787694096565247, 0.13876810669898987, -0.269150048494339, 0.23103411495685577, 0.1704978346824646, -0.24278168380260468, -0.0334104523062706, -0.06906283646821976, 0.21408411860466003, -0.6559984683990479, 0.07018188387155533, 0.4263388216495514, 0.11310257762670517, 0.2038186639547348,...
I am writing a high performance parser, and it seems to me that `Int32.Parse` can be too slow. I wrote a simple version that assumes correct input, and it's performing much better. So should I create my own version instead? Or is there another faster method already available? My method is like this: ``` // parse simp...
[ -0.2004925012588501, 0.09482727944850922, 0.16445229947566986, -0.3377997577190399, -0.14136697351932526, 0.038649868220090866, 0.5681208968162537, -0.3193983733654022, 0.2310515195131302, -0.48331403732299805, -0.27716773748397827, 0.7323541045188904, -0.5124965906143188, -0.1946641206741...
if (str[0] == '-') { sign = -1; index = 1; } else if (str[0] == '+') { index = 1; } int result = 0; for (; index < str.Length; ++index) { result = 10 * result + (str[index] - '0'); } if (result < 0) throw new OverflowException(str + " is too large for Int32"); return result * sign; } ...
[ -0.295390248298645, -0.0044265263713896275, 0.578883707523346, -0.4044683873653412, 0.13324934244155884, 0.15597832202911377, 0.34208887815475464, -0.5877094268798828, -0.018736641854047775, -0.4462275207042694, -0.14713528752326965, 0.6431798934936523, -0.1709936261177063, -0.034807670861...
took 8.2775453 seconds ParseInt32Simply took 0.6511523 seconds Int32.Parse took 6.7625807 seconds ParseInt32Simply took 0.4677390 seconds ``` (Running 25 million iterations on my machine; a P4 3 GHz, running VS 2008 SP1) So, should I use my version? Or is there another method available that I can use? If your p...
[ -0.2958414852619171, 0.068523108959198, 0.3574009835720062, -0.17049367725849152, -0.31982600688934326, 0.4487714469432831, 0.7736281156539917, -0.3825322985649109, -0.45062747597694397, -0.596336841583252, 0.3151049017906189, 0.47888413071632385, 0.00355522776953876, -0.3188408315181732, ...
created a quick implementation of this, ``` public static Int32 ParseValidNumberAsInt32(string str) { if (str == null) throw new ArgumentNullException("str"); if (str.Length == 0) throw new ArgumentException("str is empty"); Int32 result = 0; Int32 currentPower = 1; Boolean isNega...
[ -0.4030657410621643, -0.37105855345726013, 0.6969085931777954, -0.18791460990905762, 0.26195600628852844, 0.02180449478328228, 0.32013607025146484, -0.6102573275566101, -0.09958049654960632, -0.1874019354581833, -0.20340368151664734, 0.6344562768936157, -0.3151427209377289, 0.1500353366136...
'0') * currentPower; currentPower *= 10; } return isNegative ? -1 * result : result + ((str[0] - '0') * currentPower); } ``` If you really want speed, you can write a unsafe implementation.. If your parsing a big file, you could read the files as raw bytes and work with those. That will make it a lot...
[ -0.09829738736152649, -0.26693013310432434, 0.475946843624115, 0.0024487110786139965, 0.019655602052807808, -0.049776557832956314, 0.41618812084198, -0.34359604120254517, -0.15721040964126587, -0.6330482363700867, -0.17153871059417725, 0.4876596927642822, -0.29715585708618164, -0.044361736...
In Java, the idiomatic way to declare critical sections in the code is the following: ``` private void doSomething() { // thread-safe code synchronized(this) { // thread-unsafe code } // thread-safe code } ``` Almost all blocks synchronize on `this`, but is there a particular reason for this? Are there o...
[ 0.29355546832084656, 0.1183076873421669, -0.2187259942293167, -0.24362781643867493, -0.1687711477279663, -0.39439529180526733, 0.2679691016674042, -0.2783987522125244, -0.23647795617580414, -0.3230619728565216, -0.33973363041877747, 0.11210484802722931, -0.6733604669570923, -0.055620864033...
} } ``` and: ``` public synchronized void foo() { // do something thread-safe } ``` do **exactly the same thing**. No preference for either one of them except for code readability and style. When you do synchronize methods or blocks of code, it's important to know **why** you are doing such a thing, and **wha...
[ 0.5411353707313538, -0.11017926037311554, 0.17204102873802185, 0.11899124830961227, -0.054451487958431244, -0.2088492214679718, -0.07276219129562378, 0.011093541979789734, -0.3144421875476837, -0.4313599467277527, 0.032379161566495895, 0.70499587059021, -0.6578683257102966, -0.011538064107...
getSomeGlobalVector(); synchronized (v) { // some thread-safe operation on the vector } ``` I suggest you get more knowledge about concurrent programming, it will serve you a great deal once you know exactly what's happening behind the scenes. You should check out [Concurrent Programming in Java](https://rads.sta...
[ 0.29524362087249756, -0.09760747849941254, 0.3661857545375824, 0.2539684772491455, -0.04746586084365845, -0.440837562084198, 0.25938624143600464, 0.11292526870965958, -0.7990732789039612, -0.557369589805603, 0.19344906508922577, 0.5654703378677368, -0.3488423526287079, 0.05439908802509308,...
A developer I know just showed me [FubuMVC](http://mvc.fubu-project.org/) and there was some question whether or not we should attempt to use it on a real live project or not. The current design choice so far has been ASP.NET MVC. What I'm interested in finding out is: What are the core differences between ASP.NET M...
[ 0.45001906156539917, -0.22960051894187927, 0.5546537637710571, -0.0942496582865715, -0.20788003504276276, -0.2740479111671448, -0.10946539044380188, -0.15413889288902283, -0.11337278038263321, -0.620902955532074, 0.0033340321388095617, 0.7047378420829773, -0.306134432554245, 0.080158561468...
better or worse than the other overall, they are different and each have significant strengths and weaknesses that you should consider. At this point, ASP.NET MVC is more mature and has had more testers and eyeballs looking at it. So if you are doing any sort of serious project (i.e. you're getting paid for it), I wou...
[ 0.334849089384079, -0.2126045525074005, 0.8589367866516113, -0.17487859725952148, -0.28441447019577026, -0.28938430547714233, 0.09845708310604095, 0.037644609808921814, -0.14905136823654175, -0.4816884696483612, -0.25428223609924316, 0.8405476212501526, -0.17502014338970184, -0.16683207452...
on FubuMVC. While the documentation is still lacking somewhat, the quality of the framework is now well established as production-worthy) If you're starting a hobby project (i.e. personal blog, personal/family photo album, etc) then I'd invite you to pick up FubuMVC and start playing with it. Keep in mind that this po...
[ 0.8827046751976013, -0.10826940089464188, 0.4043639600276947, 0.06531921029090881, 0.03347837179899216, -0.7138830423355103, -0.14496472477912903, 0.4009146988391876, -0.022020405158400536, -0.3785562813282013, 0.22217786312103271, 0.7828588485717773, -0.30033937096595764, 0.19374236464500...
the first milestone then announce it to the wide, wide world, contributions will ramp up. In the end, using either will likely encourage better development practices over, say, ASP.NET WebForms and getting familiar with the one will make it easier for you to pick up the other one rather quickly. It really comes down ...
[ 0.4954962432384491, 0.08940780162811279, 0.076060950756073, 0.2289184182882309, -0.062042225152254105, -0.06334103643894196, -0.11973501741886139, 0.08108817785978317, -0.05048564076423645, -0.965570330619812, 0.040449000895023346, 0.4753670394420624, 0.36950263381004333, -0.18598975241184...
I need to build SSIS packages on a build machine, and do not want the overhead of installing SQL Server Management Studio on this machine. A SQL Server 2008 SDK would be ideal, but I could not find where to download it. The dlls I require are (for example): * Microsoft.SQLServer.ManagedDTS * Microsoft.SqlServer.Pipel...
[ 0.43206551671028137, 0.02989555522799492, 0.1114049032330513, -0.007499445229768753, -0.3038966655731201, -0.18341904878616333, 0.43734875321388245, -0.1369902789592743, 0.00195641559548676, -0.9056598544120789, -0.08881744742393494, 0.4102334678173065, -0.2199264019727707, 0.0896341577172...
in particular the "Search using LDIFDE" section.
[ -0.1712246835231781, -0.24481241405010223, -0.2429257333278656, 0.1613776832818985, -0.23035849630832672, -0.8774559497833252, 0.08940223604440689, -0.08507148176431656, -0.15062077343463898, -0.4549608528614044, -0.5501441955566406, 0.45653584599494934, -0.3669114410877228, 0.060718856751...
This is perhaps similar to previous posts, but I want to be specific about the use of locking on a network, rather than locally. I want to write a file to a shared location, so it may well go on a network (certainly a Windows network, maybe Mac). I want to prevent other people from reading any part of this file whilst ...
[ 0.49801450967788696, 0.06922225654125214, 0.31705692410469055, 0.1283656656742096, 0.004071950446814299, -0.4742800295352936, 0.5729530453681946, -0.1115930825471878, -0.17429131269454956, -0.444695383310318, -0.10516350716352463, 0.25242510437965393, -0.15439529716968536, 0.23256023228168...
and what is not. I want to lock the entire file, rather than portions of it. Can I use `FileChannel.tryLock()`, and it is safe on a network, or does it depend on the type of network? Will it work on a standard Windows network (if there is such a thing). If this does not work, is the best thing to create a zero byte ...
[ 0.49137669801712036, -0.10543911159038544, -0.056253038346767426, 0.336504191160202, 0.5167698860168457, -0.34917575120925903, 0.0360785610973835, -0.040244124829769135, -0.315514475107193, -0.3808879256248474, 0.07952352613210678, 0.545383870601654, -0.28772127628326416, 0.048719659447669...
ideal. This can't be reliably done on a network file system. As long as your application is the only application that accesses the file, it's best to implement some kind of cooperative locking process (perhaps writing a lock file to the network filesystem when you open the file). The reason that is not recommended, how...
[ 0.10837854444980621, 0.07076214998960495, 0.11477592587471008, 0.24963495135307312, 0.2799016535282135, -0.6559538841247559, 0.32795172929763794, -0.05697251111268997, -0.22859005630016327, -0.7516635656356812, -0.08844485133886337, 0.7181559205055237, -0.30439791083335876, 0.3622882068157...
I wish to store URLs in a database (MySQL in this case) and process it in Python. Though the database and programming language are probably not this relevant to my question. In my setup I receive unicode strings when querying a text field in the database. But is a URL actually text? Is encoding from and decoding to un...
[ 0.19151191413402557, 0.34195730090141296, 0.22415810823440552, 0.11530736088752747, -0.28432708978652954, 0.0666666105389595, -0.068477101624012, -0.0340866893529892, -0.026056505739688873, -0.6757223010063171, 0.11431189626455307, 0.30008289217948914, -0.1832927018404007, 0.25383409857749...
the distiction that unicode represents text and byte strings represent a way to encode this text into a sequence of bytes. In Python (prior to 3.0) this distinction is between the unicode and the str types. In MySQL it is TEXT to BLOBS. So the concepts seem to correspond between programming language and database. But w...
[ 0.0045412760227918625, 0.351970911026001, 0.31154629588127136, -0.14782246947288513, -0.35306316614151, 0.07808440178632736, -0.11210174858570099, 0.2051532119512558, -0.1210501492023468, -0.41326361894607544, -0.3206722140312195, -0.03228718787431717, -0.302051305770874, 0.191833883523941...
it is useful to distinguish between a "character" (as a distinguishable semantic entity) and an "octet" (an 8-bit byte). There are two mappings, one from URI characters to octets, and a second from octets to original characters: URI character sequence->octet sequence->original character sequence A URI is represented ...
[ -0.2105499655008316, 0.028040645644068718, 0.36049705743789673, 0.40037795901298523, -0.005615630652755499, 0.24318426847457886, -0.18688754737377167, 0.172294020652771, -0.09332536906003952, -0.6579642295837402, -0.349025696516037, -0.40717124938964844, -0.09190250933170319, 0.56201142072...
Today I came across a problem where someone had accidentally committed a proj.user file to the SVN repository. When i came to update, it obviously caused issues. It got me wondering if there was any way that you can block certain file extensions to be committed to the repository. I do realise there is an ignore list...
[ 0.5195703506469727, 0.13373906910419464, 0.3588734567165375, -0.11173244565725327, 0.0032613046932965517, -0.22018563747406006, 0.24299213290214539, -0.0040960172191262245, -0.65093594789505, -0.2515219748020172, 0.12811720371246338, 0.3871532380580902, -0.2348702996969223, 0.4836739897727...
are two ways. Either create commit-hooks (which is probably not what you want to do), or, more easily, add the svn:ignore property to your directory. Since properties are maintained along with the project, this will effect everyone. For instance, to ignore `*.user` files, you could add this to the directory where they ...
[ 0.35558560490608215, -0.11632255464792252, 0.5896518230438232, -0.05769696459174156, 0.008815431036055088, -0.1498282104730606, 0.300479918718338, -0.2097514122724533, -0.5283135175704956, -0.6031164526939392, -0.16703401505947113, 0.6662895083427429, -0.36014804244041443, 0.38254684209823...
field, however. It does not automatically act recursively on your project tree. If, for any reason, you do want to update an ignored file, you would pass the `--no-ignores` flag to the command.
[ 0.32551923394203186, -0.18832609057426453, -0.03241800516843796, 0.1486421376466751, -0.01208480354398489, -0.4245019257068634, 0.23266299068927765, 0.26400938630104065, -0.4337553083896637, -0.09764962643384933, -0.3350805640220642, 0.3873177170753479, -0.4156624972820282, 0.0349934287369...
I really need help with interfaces in general... Any resources that you guys would recommend me? ### Related: * [How are Java interfaces actually used?](https://stackoverflow.com/questions/504904/how-are-java-interfaces-actually-used) * [Java interface and inheritance](https://stackoverflow.com/questions/1215437/jav...
[ 0.050356242805719376, 0.005141798872500658, 0.2421400099992752, 0.27879393100738525, -0.24721994996070862, -0.235700786113739, 0.2937712073326111, -0.01617301255464554, -0.23867453634738922, -0.6213943362236023, 0.015721773728728294, 0.5321742296218872, 0.031589340418577194, -0.12784661352...
I have a bash script that runs a simulation program written in Fortran 90, and all output is redirected to a file. If the program finishes without problems, I set a success parameter. The code looks something like this: ``` #!/bin/bash ... echo -n "Running program..." ./sim_program >& file && success="true" if [ $suc...
[ 0.1482193022966385, 0.37745043635368347, 0.31777259707450867, -0.29618749022483826, 0.2519703507423401, -0.21445877850055695, 0.4385024607181549, -0.42423996329307556, -0.2537408471107483, -0.43465861678123474, -0.3562049865722656, 0.6612863540649414, -0.21357904374599457, 0.09766780585050...
then look something like this: ``` :~>execute_script Running program.../path/to/script: line 232: 15350 Floating Point Exception ./sim_program >& file && success="true" NOT OK ``` How can I suppress the error output due to the SIGFPE or SIGSEGV such that I get ``` :~>execute_script Running program... NOT OK ``` ...
[ 0.01657254621386528, 0.36144760251045227, 0.4462277591228485, 0.0012062778696417809, 0.0002546501928009093, -0.1858401596546173, 0.36388492584228516, -0.31966254115104675, -0.3695398271083832, -0.7253793478012085, -0.21066804230213165, 0.5418432354927063, -0.2741813063621521, 0.03247977420...
rather than your terminal.
[ 0.14302048087120056, -0.11405792832374573, 0.19125306606292725, 0.21486052870750427, 0.19529061019420624, 0.16526256501674652, -0.22609204053878784, 0.3835754692554474, -0.4478599429130554, -0.3121795356273651, 0.11084572225809097, 0.3408171832561493, 0.07401534914970398, 0.241584151983261...
Is there a better way of doing this ? ``` SELECT (SELECT count(*) FROM `tbl` WHERE `status` = 0) as 'text1', (SELECT count(*) FROM `tbl` WHERE `status` > 0) as 'text2' ``` text1 and text2 are headers. How about ``` select sum(if(status=0,1,0)) as zeros, sum(if(status>0,1,0)) as greater from tbl; ``` ...
[ 0.1362658441066742, -0.13328956067562103, 0.13273440301418304, -0.0560385026037693, -0.23719362914562225, -0.04235976189374924, 0.3608745038509369, -0.2979961335659027, -0.17089833319187164, -0.38090062141418457, -0.009628325700759888, 0.5630220174789429, -0.22804176807403564, -0.223663389...
Given Wikipedia's discussion of [Double Factorial](http://en.wikipedia.org/wiki/Factorial#Double_factorial)s, can anyone suggest where I might find a bignum version of this for Perl, or else suggest how it might be written? Perl will handle whatever your C compiler can handle, for anything bigger you should be using [M...
[ 0.18477071821689606, -0.17147567868232727, 0.35836586356163025, -0.23607386648654938, -0.3034692704677582, -0.0028234694618731737, -0.17091143131256104, -0.258663147687912, -0.47963473200798035, -0.16830070316791534, -0.07890699058771133, 0.5051771402359009, -0.4626208543777466, -0.1099755...
If I use an URL like <http://mysite/myfolder/myfile.dll>, I get a dialog "Do you want to open or save this file". Of course, I don't want people to be able to download and disassembly our dll's. How can I deny people accessing such files directly ? Denying all dll's is drastic in an asp.net site, as Silverlight etc use...
[ 0.5085532665252686, 0.24591229856014252, 0.14644525945186615, 0.05864184722304344, -0.1798262894153595, -0.423947811126709, 0.2569652795791626, 0.18183156847953796, -0.20699352025985718, -0.5725059509277344, -0.1684461534023285, 0.2654534876346588, -0.11557391285896301, 0.7102315425872803,...
I have a simulation that reads large binary data files that we create (10s to 100s of GB). We use binary for speed reasons. These files are system dependent, converted from text files on each system that we run, so I'm not concerned about portability. The files currently are many instances of a POD struct, written with...
[ 0.22729898989200592, 0.15775199234485626, 0.2692832052707672, 0.0601450651884079, 0.3297659158706665, 0.07975929230451584, -0.25253015756607056, 0.1989208310842514, -0.11163485050201416, -0.9059288501739502, -0.11173279583454132, 0.2532714307308197, -0.13027441501617432, 0.3052944839000702...
thinking of the size of the struct, byte order, and maybe the svn version number of the code that created the binary file. Is there anything else that would be useful to add? In my experience, second-guessing the data you'll need is invariably wasted time. What's important is to structure your *metadata* in a way that ...
[ 0.5501105785369873, 0.16574931144714355, -0.006483032368123531, 0.27431705594062805, -0.046944744884967804, -0.3335516154766083, -0.03310130909085274, -0.19098934531211853, -0.24761269986629486, -0.5077866911888123, -0.10098588466644287, 0.44809794425964355, -0.0490281768143177, 0.22485685...
existing files without impacting their reading code. The simplest metadata footer I use looks something like this: ``` struct MetadataFooter{ char[40] creatorVersion; char[40] creatorApplication; .. or whatever } struct FileFooter { int64 metadataFooterSize; // = sizeof(MetadataFooter) char[10] magicStr...
[ 0.2322397083044052, 0.07325177639722824, 0.8105396628379822, 0.19757960736751556, 0.2535558342933655, -0.12513041496276855, -0.06135210022330284, -0.34140926599502563, -0.15337379276752472, -0.7520946264266968, -0.021995704621076584, 0.7514086961746216, 0.0036267440300434828, 0.22615389525...
use default values for missing fields. As [KeithB](https://stackoverflow.com/users/2298/keithb) points out, you could even use this technique to store the metadata as an XML string, giving the advantages of both totally extensible metadata, with the compactness and speed of binary data.
[ 0.26576149463653564, -0.043507516384124756, 0.23864585161209106, 0.19001026451587677, 0.2533826231956482, -0.46314990520477295, 0.023852158337831497, -0.34178951382637024, -0.4043565094470978, -0.25870653986930847, -0.48854485154151917, 0.5157442092895508, -0.06387192010879517, -0.01600359...
Is there a way to test if a regular expression "contains" another regular expression? For example: ``` RegEX1 = "a.*b"; RegEx2 = "a1.*b"; ``` RegEX1 "contains" RegEX2. As far as I know - this can't be done, am I wrong? --- OK, joel.neely has shown that it can be done (haven't read it yet...) academically. ...
[ 0.20152750611305237, 0.217473566532135, -0.3610547184944153, -0.045638322830200195, -0.2896580994129181, 0.14529113471508026, 0.3976232409477234, -0.32188713550567627, 0.05940353125333786, -0.28520533442497253, -0.07873061299324036, 0.3416367769241333, -0.06455253809690475, -0.371142864227...
I have a .mbm file that I copy to my device using this line in the .pkg file ``` "$(EPOCROOT)epoc32\data\z\resource\apps\MyApp.mbm" -"!:\resource\apps\MyApp.mbm" ``` Then in the draw function of my container I do this.. ``` _LIT(KMBMFile , "\\resource\\apps\\MyApp.mbm" ); CFbsBitmap* iBitmap; iBitmap->Load(KMBMFil...
[ -0.09100618958473206, 0.27192315459251404, 0.7330503463745117, 0.04213941842317581, 0.40438857674598694, -0.19889797270298004, 0.5710901618003845, -0.09670999646186829, -0.42658624053001404, -0.6931574940681458, -0.2906844913959503, 0.5706466436386108, -0.3840559124946594, 0.30289557576179...
, "\\resource\\apps\\MyApp.mbm" ); CFbsBitmap* iBitmap; iBitmap = iEikonEnv->CreateBitmapL( KMBMFile, 0 ); gc.BitBlt( Rect().iTl, iBitmap ); ```
[ -0.21271812915802002, 0.04081030562520027, 0.6250543594360352, -0.15164810419082642, 0.39814794063568115, 0.11757105588912964, 0.28892630338668823, -0.05423116683959961, -0.21937605738639832, -0.545478105545044, -0.5655946731567383, 0.5171735286712646, -0.6182000041007996, 0.08948848396539...
What's the best way to keep a collection-object (List in example) in a Key/Value situation, where the key is a ID and the value is a collection of a type T? Is this the only option or is there a better solution/another collection for this in .NET 3.5? ``` var x = new Dictionary<int, List<type>>(); ``` This is a good...
[ 0.1067582443356514, -0.11703018099069595, 0.2080221027135849, 0.2505054473876953, 0.11389220505952835, 0.013703255914151669, 0.03655056282877922, -0.3134182095527649, -0.31506919860839844, -0.5491324663162231, -0.028540009632706642, 0.6353338360786438, -0.2776317596435547, 0.02894876524806...
be able to use it. This will be a very efficent and compact solution to your apparent problem.
[ 0.2869003415107727, 0.10171275585889816, 0.042460035532712936, 0.5096198320388794, 0.3788338899612427, 0.0030388825107365847, -0.06914542615413666, 0.12470865994691849, 0.17812277376651764, -0.7164410352706909, 0.19358760118484497, 0.5153129696846008, 0.3025447130203247, -0.173453465104103...
I am trying to define a WCF contract that returns an interface, something like below: ``` [ServiceContract] public interface IMyContracts { [OperationContract] IMyInterface GetData(string request); } ``` To get this to work I think my interface (`IMyInterface`) would have to implement `ISerializable` to ensu...
[ 0.013274461962282658, 0.06717337667942047, 0.3534255623817444, -0.15021772682666779, -0.15123380720615387, -0.24416999518871307, 0.38687238097190857, -0.2929322421550751, 0.006197269540280104, -0.9758453369140625, -0.018797386437654495, 0.7045725584030151, -0.5598270297050476, 0.3960695862...
I confusing myself and missing something obvious? How have other people returned interfaces using WCF and avoided this problem? Thanks very much. AFAIK, the problem is not with serialization but with the fact that you're returning abstract entity (an interface). Abstraction is an OO concept, not SOA concept. So, your ...
[ 0.12523417174816132, -0.01698131114244461, 0.34380853176116943, 0.34368613362312317, -0.2679097652435303, -0.10512959212064743, 0.03238178417086601, -0.06740326434373856, -0.32307782769203186, -0.8276753425598145, 0.07125185430049896, 0.5653409957885742, -0.15374985337257385, 0.46688282489...
your contract, via [KnownTypeAttribute](http://msdn.microsoft.com/en-us/library/system.runtime.serialization.knowntypeattribute.aspx). You may also use [ServiceKnownTypeAttribute](http://msdn.microsoft.com/en-us/library/system.servicemodel.serviceknowntypeattribute.aspx) class that seems to be more flexible. Still, re...
[ 0.45999738574028015, -0.2976720631122589, 0.5204176306724548, -0.057932086288928986, 0.15953613817691803, -0.3250219523906708, 0.3793119490146637, 0.042808111757040024, -0.11087723821401596, -0.6377905607223511, -0.2994150221347809, 0.4545702040195465, -0.021776586771011353, 0.263130068778...
I want to know if it is possible to end a for loop in C++ when an ending condition (different from the reacheing right number of iterations) is verified. For instance: ``` for (int i = 0; i < maxi; ++i) for (int j = 0; j < maxj; ++j) // But if i == 4 < maxi AND j == 3 < maxj, // then jump out of t...
[ 0.5322319269180298, -0.18507717549800873, 0.12621717154979706, -0.01761302910745144, 0.17775915563106537, -0.12499874085187912, 0.44458892941474915, -0.22278758883476257, -0.17722898721694946, -0.3652207851409912, -0.1204444095492363, 0.6288742423057556, -0.29996228218078613, -0.0217240266...
or last LABEL calls and labeled blocks, is it possible to do it in C++ or I should use a while loop? Thank you. You can use the `return` keyword: move the nested loop into a subroutine, invoke the subroutine to run the nested loops, and 'return' from the subroutine to exit [all] the loops.
[ 0.0481589250266552, -0.1254977434873581, 0.2621314823627472, 0.07370463013648987, -0.040727753192186356, -0.11188831925392151, 0.27724528312683105, 0.07008195668458939, -0.1375148892402649, -0.29965725541114807, -0.3330771327018738, 0.5996102690696716, -0.16406086087226868, -0.041342627257...
I have six string variables say str11, str12, str13, str21, str21 and str23. I need to compare combination of these variables. The combinations I have to check is str11 -- str12 -- str13 as one group and str21 -- str22 -- str23 as other group. I have to compare these two groups. Now I'm in confusion which method sho...
[ 0.015455445274710655, 0.13440066576004028, 0.19529786705970764, -0.12569625675678253, -0.6181036829948425, 0.6927599906921387, 0.446659654378891, -0.7767021656036377, -0.20524238049983978, -0.6200791597366333, 0.13516737520694733, 0.3584883511066437, -0.4055423140525818, 0.1417040824890136...
if( str12 equals str22 ) { if( str13 equals str23 ) { } } } ``` What is performance factor which costs me because of string length when I do string comparison? Lets us assume all strings are of same( approx ) length. I’d test individually. Is “AB” “CD” “EF” equal to “ABC” “DE” “F”? Me thinks...
[ 0.2826760411262512, 0.17313244938850403, 0.05841025710105896, -0.07142334431409836, -0.18703733384609222, 0.25415441393852234, 0.305753231048584, -0.41216227412223816, -0.18647468090057373, -0.5702204704284668, 0.03264480456709862, 0.711633026599884, -0.10905735194683075, 0.108703330159187...
I know that if an IP falls outside the Subnet Mask + Local IP rules, it will be only reachable through an Gateway. The problem is that I don't know how to obtain the local IP address, neither the local subnet mask, programatically using .NET. Any of you can help me? I will use this information to squeeze the maximum p...
[ 0.33787885308265686, 0.11657849699258804, 0.13243944942951202, 0.32583996653556824, -0.0016100411303341389, -0.0877750813961029, 0.24902310967445374, 0.11508254706859589, -0.2656859755516052, -1.0263159275054932, 0.23375636339187622, 0.41320377588272095, 0.09191437810659409, 0.291557192802...
(introduced in .NET 2.0): ``` NetworkInterface[] interfaces = NetworkInterface.GetAllNetworkInterfaces(); foreach (NetworkInterface iface in interfaces) { IPInterfaceProperties properties = iface.GetIPProperties(); foreach (UnicastIPAddressInformation address in proper...
[ -0.284159392118454, -0.38626009225845337, 0.932481050491333, -0.01961618661880493, -0.007087756413966417, -0.008678738959133625, 0.3416697084903717, -0.26497146487236023, -0.16983166337013245, -1.1772210597991943, -0.17180998623371124, 0.49801886081695557, -0.36064696311950684, 0.235962882...
"{0} (Mask: {1})", address.Address, address.IPv4Mask ); } } ```
[ -0.3164197504520416, 0.018413463607430458, 0.2960147261619568, -0.2672775983810425, 0.2821623384952545, 0.003323485841974616, 0.22891005873680115, -0.022953391075134277, -0.020277781412005424, -0.47433146834373474, -0.6001418232917786, 0.5608716607093811, -0.46730902791023254, 0.3053357303...
I usually do not use Sql Server Management Studio, I usually use Linqpad to run all my db queries. Anyhow.... My boss seems to think that stored procs are "a lot faster than linq". So to test this, I want to run a simple stored proc and display the time it takes to run against an equal linq statement. Any good idea...
[ 0.2915268838405609, 0.15962658822536469, 0.011591650545597076, 0.03959747403860092, -0.1383175402879715, -0.07504026591777802, 0.18593309819698334, 0.10877010226249695, -0.10227252542972565, -0.5941457152366638, 0.40482911467552185, 0.6393173933029175, -0.04766207933425903, -0.049401782453...
boss says "linq" I can only assume she is talking about Linq-to-Sql. Second, I am willing to try every way possible to test out this theory. Your boss is right in the sense that stored procedures are like compiled code whereas LINQ (which uses SQL) is more like interpreted code. BUT... you lose flexibility with stored...
[ 0.28030648827552795, 0.10068341344594955, 0.08458261936903, 0.28831541538238525, -0.07983601838350296, -0.14841397106647491, -0.027154918760061264, -0.20385733246803284, -0.47492820024490356, -0.3337003290653229, 0.2708110809326172, 0.5410006046295166, -0.11481225490570068, -0.014166242443...
things like indexes before I'd worry about making everything stored procs.
[ -0.05465437471866608, 0.0706034004688263, -0.010112038813531399, 0.3695005476474762, -0.14181053638458252, -0.11839026212692261, 0.14482742547988892, 0.22261536121368408, -0.2154276967048645, -0.44311001896858215, 0.23793812096118927, 0.4776906371116638, 0.153215229511261, -0.1685400009155...
In RPC semantics where Erlang has hope for the best, SUN RPC with at-least once and Java RMI with at-most-once but no one has exactly once semantics. Why does it seem infeasible to have exactly once semantics? For example if the client keeps resending a uniquely tagged request until a reply is received and a server...
[ 0.13433121144771576, 0.04336543381214142, 0.2426036298274994, 0.003314111614599824, -0.2503149211406708, -0.19734936952590942, 0.06993062794208527, -0.3991500437259674, -0.5545250177383423, -0.5975412726402283, 0.13371722400188446, 0.4232881963253021, -0.42613884806632996, -0.1458514630794...
the request, then carrying it out. if you get a crash between the two, then you've (erroneously) recorded it as carried out, so you won't do it again. Hence at-most-once Bizarrely, this one (with timeouts) is patented: <http://www.freepatentsonline.com/7162512.html>. Except as I argue above, it doesn't guarantee exact...
[ 0.739189624786377, -0.21393924951553345, 0.6029191613197327, 0.3006463348865509, 0.20364589989185333, -0.3346017599105835, 0.11887200176715851, -0.4287016689777374, -0.5341578722000122, -0.1960802972316742, -0.06704632192850113, 0.28162723779678345, -0.16635684669017792, 0.0502274781465530...
I am trying to start a new MVC project with tests and I thought the best way to go would have 2 databases. 1 for testing against and 1 for when I run the app and use it (also test really as it's not production yet). For the test database I was thinking of putting create table scripts and fill data scripts within the t...
[ 0.5892388820648193, 0.3456099033355713, 0.06213981658220291, 0.10351066291332245, -0.05774613469839096, -0.0073173996061086655, 0.06783981621265411, -0.16579942405223846, -0.1285696178674698, -0.4149332642555237, 0.3076554834842682, 0.5521692633628845, -0.31907644867897034, 0.0553936287760...
go the ADO route if I want to do it this way? Or should I just use a mock object and store data as an array or something?. Any tips on best practices? How did Jeff go about doing this for StackOveflow? I checked out the link from tvanfosson and RikMigrations and after playing about with them I prefer the mocking dat...
[ 0.2645834982395172, 0.32282617688179016, 0.3665466904640198, 0.022217217832803726, -0.30293193459510803, -0.28222256898880005, 0.27704524993896484, -0.18294239044189453, -0.06517110019922256, -0.3796948492527008, 0.21189568936824799, 0.37698033452033997, -0.1696697473526001, -0.32548949122...
for the help.
[ -0.10884491354227066, 0.3440167009830475, -0.09788019955158234, 0.1286982148885727, -0.3073306679725647, 0.21357572078704834, 0.22794833779335022, 0.0943012461066246, -0.01390940323472023, -0.2856914699077606, -0.007908185012638569, 0.31655025482177734, 0.15413333475589752, -0.067175880074...
I'm looking for a way to (preferably) strongly type a master page from a user control which is found in a content page that uses the master page. Sadly, you can't use this in a user control: ``` <%@ MasterType VirtualPath="~/Masters/Whatever.master" %> ``` I'm trying to access a property of the master page from the...
[ 0.35932883620262146, 0.17727696895599365, 0.36852216720581055, 0.0181345846503973, -0.0804477259516716, -0.29021328687667847, 0.28192225098609924, -0.24831674993038177, -0.14189329743385315, -0.9794789552688599, -0.09731775522232056, 0.5454321503639221, -0.31248435378074646, 0.407865077257...
statements to the top of your file, or qualify the Master page type inline. One potential gotcha is if this control is used by a different page whose master page is NOT the same type. This would only get caught at runtime.
[ 0.37219762802124023, -0.05059775710105896, 0.04750355705618858, 0.3320571482181549, -0.23241202533245087, -0.3835451602935791, 0.4870665371417999, 0.0115675562992692, -0.2264752835035324, -0.3407447934150696, -0.16502751410007477, 0.37990012764930725, -0.36038339138031006, 0.17721611261367...
What is the difference between the three functions and when to use them?? WinMain is used for an application (ending .exe) to indicate the process is starting. It will provide command line arguments for the process and serves as the user code entry point for a process. WinMain (or a different version of main) is also a...
[ 0.10495569556951523, -0.49099478125572205, 0.5172445178031921, 0.15330028533935547, 0.1805703341960907, -0.09533204883337021, 0.02506626769900322, -0.06116267666220665, -0.0931161418557167, -0.42948246002197266, -0.29304248094558716, 0.4935416877269745, -0.3388559818267822, 0.3759097754955...
The DLL is unloaded from the process: DLL\_PROCESS\_DETACH 3. A thread is started in the process: DLL\_THREAD\_ATTACH 4. A thread is ended in the process: DLL\_THREAD\_DETACH DllMain is an optional construct and has a lot of implicit contracts associated with it. For instance, you should not be calling code that will ...
[ -0.1933673471212387, -0.3103371560573578, 0.68294358253479, -0.06616676598787308, -0.017548151314258575, -0.17471954226493835, 0.06941363960504532, -0.12072861939668655, -0.1286129206418991, -0.4926474690437317, -0.30154162645339966, 0.41856080293655396, -0.3793542981147766, 0.513689458370...
I have two tables, tblEntities and tblScheduling. tblEntities: ``` EntityID ShortName Active 1 Dirtville 1 2 Goldtown 1 3 Blackston 0 4 Cornfelt 1 5
[ 0.26835447549819946, 0.20751948654651642, 0.48476162552833557, 0.021911215037107468, 0.08699868619441986, 0.14233070611953735, 0.011572013609111309, 0.11259888857603073, 0.13252709805965424, -0.44209879636764526, 0.41254550218582153, 0.5696987509727478, -0.4454399645328522, 0.2377034872770...
Vick 1 ``` tblScheduling: ``` ScheduleID EntityID SchedulingYearID 1 1 20 2 1 21 3 2 20 4 3 19 5
[ -0.35658615827560425, 0.036472830921411514, 0.59319669008255, 0.06486716121435165, 0.28920334577560425, -0.39777660369873047, 0.1854752153158188, -0.12173022329807281, -0.22405920922756195, -0.5644553899765015, -0.05180972442030907, 0.5521460175514221, -0.2889232635498047, 0.34854435920715...
5 20 ``` I need a query that will show **ALL ACTIVE** Entities and their schedule information for a particular ScheduleYearID. Output should look like (the desired SchedulingYearID in this case is 20): ``` EntityID ScheduleID 1 1 2 3 4 NULL 5 5 ``` The query that I have written ...
[ 0.11558389663696289, -0.12642993032932281, 0.4417957365512848, -0.15162761509418488, 0.22287338972091675, 0.0260919239372015, -0.04796590283513069, -0.07472776621580124, -0.1237344965338707, -0.8698029518127441, 0.1477852314710617, 0.49401265382766724, -0.47280117869377136, -0.036274995654...
OUTER JOIN tblEntities ON tblScheduling.EntityID = tblEntities.EntityID WHERE (tblScheduling.SchedulingYearID = @SchedulingYearID) AND (tblEntities.Active = 1) ORDER BY tblEntities.EntityID ``` My problem is that using this query it will not include active entities without schedule informat...
[ -0.030558129772543907, -0.10217946767807007, 0.5113130807876587, -0.1371748000383377, 0.1388271152973175, -0.12409956008195877, 0.42467179894447327, -0.3501909673213959, -0.2829815745353699, -0.6999247074127197, 0.33142203092575073, 0.7277048230171204, -0.7229189872741699, 0.23812749981880...
obviously missing without having to resort to subqueries, cursors, etc.? If not it's not a big deal, I just feel like I am missing something simple here. Try this... Join conditions are evaluated to produce the intermediate Join result set, and then, (for an outer join), all the rows from the "Outer" side are added bac...
[ -0.11347121000289917, -0.038057684898376465, 0.10874799638986588, -0.10263849049806595, 0.2822546064853668, -0.14069919288158417, 0.0698581114411354, -0.09179870039224625, -0.01077977940440178, -0.6614582538604736, -0.16385257244110107, 0.38637733459472656, -0.5038535594940186, 0.252071231...
And S.SchedulingYearID = @SchedulingYearID WHERE E.Active = 1 ORDER BY E.EntityID ``` I change your join order cause I prefer left joins... but it doesn't matter
[ 0.03145425021648407, -0.13020388782024384, 0.623884379863739, -0.1482810527086258, 0.16721168160438538, -0.09465604275465012, 0.2635580897331238, 0.027458133175969124, -0.3599039614200592, -0.7069845199584961, -0.2220473438501358, 0.457306444644928, -0.4767453074455261, 0.1897677332162857,...
I'm using Zend\_Form to output a set group of checkboxes: ``` <label style="white-space: nowrap;"><input type="checkbox" name="user_group[]" id="user_group-20" value="20">This Group</label> ``` With a normal HTTP Post these values are passed as an array, but when I'm somewhat stumped on how to grab all the values us...
[ 0.05007835105061531, -0.21345491707324982, 0.24268384277820587, -0.16561612486839294, -0.3228558599948883, -0.05544424057006836, 0.08452057093381882, -0.5454738140106201, -0.17985877394676208, -0.7512736916542053, -0.1379159390926361, 0.3517265021800995, -0.3213476538658142, -0.17157599329...
you can either create a collection of those values or do something to the collection: ``` var values = new Array(); $.each($("input[name='user_group[]']:checked"), function() { values.push($(this).val()); // or you can do something to the actual checked checkboxes by working directly with 'this' // something li...
[ 0.4284476637840271, -0.2267707735300064, 0.18142075836658478, -0.18322715163230896, 0.2049027681350708, -0.02775316685438156, 0.1972096562385559, -0.41172534227371216, -0.20426534116268158, -0.5610067248344421, -0.21190111339092255, 0.4997609555721283, -0.5506343245506287, -0.1966102272272...
How can I determine if a user, in say Access, is a member of an Active Directory Security Group? I'd rather not build a whole authentication system into my little Access DB. Thanks Allain found [this online](http://my.advisor.com/doc/08691) ``` Function IsMember(strDomain As String, strGroup _ As String, strMember...
[ -0.3278907537460327, 0.17349733412265778, 0.6567097902297974, -0.2348078191280365, 0.0876910611987114, -0.24640944600105286, 0.49490275979042053, -0.35408541560173035, -0.16134598851203918, -0.3510114252567291, -0.46252673864364624, 0.6548508405685425, -0.24753667414188385, 0.2322621643543...
GetCurrentUser = Environ("USERNAME") End Function Function GetCurrentDomain() As String GetCurrentDomain = Environ("USERDOMAIN") End Function ``` Putting it all together: ``` If IsMember(GetCurrentDomain, "AD Group", GetCurrentUser) Then DoStuff() End If ```
[ -0.31493932008743286, -0.10698482394218445, 0.9842219948768616, -0.2345837950706482, 0.12131571769714355, -0.4067537188529968, 0.13122296333312988, -0.343121737241745, 0.09584121406078339, -0.49417611956596375, -0.5621039867401123, 0.6241912245750427, -0.4361174404621124, 0.027611989527940...
I'm a ClearCase newbie and up until now have been used to SVN. Therefore, I'm a bit confused on the steps I need to take to create a new directory structure containing multiple files to ClearCase. So, say for example there is an existing directory structure within ClearCase as follows: ``` \ParentDirectory \Child...
[ 0.34185266494750977, 0.21122899651527405, 0.5187346935272217, -0.1541515588760376, 0.2333916574716568, 0.12938329577445984, -0.10857901722192764, 0.2927757799625397, -0.18192227184772491, -0.6759428977966309, 0.04070505499839783, 0.22889848053455353, 0.01128349918872118, 0.4540170431137085...
which will contain a number of other files, how do I go about this? From what I have been reading, I will need to first of all check out the parent directory and then use the mkelem command to make each subdirectory and file. However, I have already created the necessary files and directories on my local machine so I ...
[ 0.2209579348564148, -0.09539112448692322, 0.5955406427383423, 0.1323225349187851, 0.2813652753829956, -0.20024479925632477, -0.025256706401705742, -0.1887715607881546, -0.4825773537158966, -0.6318127512931824, -0.33454546332359314, 0.6434906125068665, -0.21585489809513092, 0.09062582254409...
use ClearCase to “add to source control …” recursively?](https://stackoverflow.com/questions/138321), you have to use clearfsimport which does what you are saying (checkout the parent directories, mkelem for the elements) ``` clearfsimport -preview -rec -nset c:\sourceDir\ChildDirectory5 m:\MyView\MyVob\ParentDirector...
[ 0.07034853845834732, -0.3382682502269745, 0.47340327501296997, 0.2413519322872162, 0.199388325214386, -0.08510236442089081, -0.07733455300331116, 0.19823996722698212, -0.11608432978391647, -0.6614823937416077, -0.22938723862171173, 0.4292452335357666, -0.1442064493894577, -0.13867197930812...
any update (like "without updating your workspace"): ClearCase allows to access the data in two ways: * snapshot view (like a SVN workspace, except all the .svn are actually externalized in a view storage outside the workspace) * dynamic view: all your files are visible through the network (instant access/update)
[ -0.03948824480175972, -0.46079158782958984, 0.7186201214790344, 0.12568700313568115, -0.07362740486860275, -0.1241941824555397, 0.1666392982006073, 0.39099493622779846, -0.4897701144218445, -0.7499068379402161, -0.347330778837204, 0.5361197590827942, -0.24967215955257416, 0.038036022335290...