text stringlengths 0 30.5k | title stringclasses 1
value | embeddings listlengths 768 768 |
|---|---|---|
I have the following code:
```
SELECT <column>, count(*)
FROM <table>
GROUP BY <column> HAVING COUNT(*) > 1;
```
Is there any difference to the results or performance if I replace the COUNT(\*) with COUNT('x')?
(This question is related to a [previous one](https://stackoverflow.com/questions/59294/in-sql-whats-the-... | [
0.3297118544578552,
0.12610173225402832,
0.2565429210662842,
-0.11295793950557709,
-0.3052747845649719,
-0.10102662444114685,
-0.059523388743400574,
-0.4167194068431854,
0.19319084286689758,
-0.624797523021698,
0.0221775621175766,
0.42965567111968994,
-0.41468802094459534,
0.26207518577575... | |
in INDEX usage -- most DBMS will actually optimize `SELECT( n ) into SELECT(*)` anyway. See the ASK TOM: Oracle has been optimizing `SELECT(n) into SELECT(*)` for the better part of a decade, if not longer:
<http://asktom.oracle.com/pls/asktom/f?p=100:11:0::::P11_QUESTION_ID:1156151916789>
> problem is in count(col) t... | [
-0.3275340795516968,
-0.2448958456516266,
0.39043915271759033,
0.033531948924064636,
-0.002876602578908205,
-0.121529720723629,
-0.03377017006278038,
-0.1703166663646698,
-0.44509944319725037,
-0.6340069770812988,
-0.03151379153132439,
0.44215530157089233,
-0.33132418990135193,
0.161108121... | |
you are using COUNT(col) (don't!) and col is marked NULL, then it will actually have to count the number of occurrences in the table (either via index scan, histogram, etc. if they exist, or a full table scan otherwise).
Bottom line: if what you want is the count of rows in a table, use COUNT(\*) | [
-0.011875229887664318,
-0.09856024384498596,
0.4429761469364166,
-0.07097780704498291,
0.08828166127204895,
-0.0568811297416687,
0.093393474817276,
-0.05912422016263008,
-0.3046557605266571,
-0.5385309457778931,
-0.2886740565299988,
0.3172464966773987,
-0.5834033489227295,
0.02955986931920... | |
So I'm getting really sick of E\*TRADE and, being a developer, would love to find an online broker that offers an API. It would be great to be able to write my own trading tools, and maybe even modify existing ones.
Based on my research so far, I've only found one option. Interactive Brokers offers a multi-language AP... | [
0.709256112575531,
0.20382176339626312,
0.2424672245979309,
0.17443925142288208,
-0.04912975803017616,
0.017465107142925262,
-0.1811337172985077,
0.2888026237487793,
-0.142338827252388,
-0.8333659172058105,
0.05709995701909065,
0.47898733615875244,
0.006475775968283415,
0.2744828760623932,... | |
for Excel
* [Pinnacle Trading](http://www.pcmtrading.com)
+ C++
+ Perl
+ VB.NET
+ Excel
* [MB Trading](http://www.mbtrading.com/developersMain.aspx?page=sdk)
I vote for IB(Interactive Brokers). I've used them in the past as was quite happy. Pinnacle Capital Markets trading also has an API (pcmtrading.com) but I hav... | [
0.22024594247341156,
0.2056729644536972,
0.053494300693273544,
-0.1544150412082672,
-0.09160007536411285,
0.2071571797132492,
-0.12700055539608002,
0.01702216826379299,
-0.313589483499527,
-0.4365823566913605,
0.15442030131816864,
0.759021520614624,
0.03780440241098404,
0.05491826310753822... | |
In a ColdFusion Component (CFC), is it necessary to use fully qualified names for variables-scoped variables?
Am I going to get myself into trouble if I change this:
```
<cfcomponent>
<cfset variables.foo = "a private instance variable">
<cffunction name = "doSomething">
<cfset var bar = "a function ... | [
0.20249803364276886,
0.1841147243976593,
0.73052579164505,
-0.2803955674171448,
-0.005380167160183191,
-0.18323391675949097,
0.15694284439086914,
-0.36633726954460144,
0.06906016170978546,
-0.24860015511512756,
-0.17920352518558502,
0.33475634455680847,
-0.2607433795928955,
-0.018020125105... | |
<cfset var bar = "a function local variable">
<cfreturn "I have #foo# and #bar#.">
</cffunction>
</cfcomponent>
```
It won't matter to specify "variables" when you create the variable, because foo will be placed in the variables scope by default; but it will matter when you access the variable.
```
<cfcom... | [
0.4200298488140106,
0.20031319558620453,
0.6557899117469788,
-0.4162804186344147,
0.0006671802839264274,
0.11698545515537262,
0.16481976211071014,
-0.458153635263443,
-0.029700184240937233,
-0.4567004442214966,
-0.25094738602638245,
0.8241149187088013,
-0.5014768838882446,
-0.0845493003726... | |
<cfreturn "I have #foo# and #bar#.">
</cffunction>
<cffunction name="doAnotherThing">
<cfargument name="foo" required="yes"/>
<cfset var bar = "a function local variable">
<cfreturn "I have #variables.foo# and #bar#.">
</cffunction>
</cfcomponent>
```
doSomething("args") returns ... | [
0.13147015869617462,
0.4160495102405548,
0.8963233232498169,
-0.44815805554389954,
-0.21613174676895142,
0.08328349143266678,
0.3037254214286804,
-0.629619300365448,
-0.0042445845901966095,
-0.3630430996417999,
-0.10056732594966888,
0.7657949924468994,
-0.28691011667251587,
0.0148938652127... | |
I'm working on an ASP.NET website which targets desktop browsers. We want to enable an optional mobile view (e.g. <http://m.sample.com>) which will offer a few simple pages which will be mostly text. There will be not need for AJAX or even Javascript, and there's no user input - it's really just tables of text with a f... | [
0.40368011593818665,
-0.030826043337583542,
0.3201366662979126,
0.015860863029956818,
-0.04049517959356308,
0.2540578544139862,
0.012668440118432045,
0.14304497838020325,
-0.1861044466495514,
-0.6405305862426758,
0.14935879409313202,
0.27779823541641235,
-0.1101900190114975,
-0.25642451643... | |
the /Mobile subfolder approach, and used [Scott Hanselman's iPhone tips for viewport and other stuff](http://www.hanselman.com/blog/MakeYourWebsiteMobileAndIPhoneFriendlyAddHomeScreenIPhoneIconsAndAdjustTheViewPort.aspx).
I have done this in the past and the way I did it is by separating the pages by creating a directo... | [
0.15216541290283203,
-0.0478329099714756,
0.7154368758201599,
-0.029756680130958557,
-0.1775045543909073,
0.20091162621974945,
0.15592022240161896,
-0.07470782101154327,
-0.3938065767288208,
-0.6493768095970154,
0.14885981380939484,
0.5152249336242676,
-0.1365739405155182,
-0.0399617217481... | |
the site, you just parse the user-agent string of the request to figure out the browser and redirect accordingly. So, for example a person with an iphone comes to your site, you parse the [user-agent string](http://developer.apple.com/documentation/AppleApplications/Reference/SafariWebContent/OptimizingforSafarioniPhon... | [
0.19288870692253113,
0.11681339144706726,
0.5886882543563843,
-0.1517307609319687,
-0.0020783732179552317,
-0.0002954868250526488,
0.44750747084617615,
0.014989292249083519,
-0.407869815826416,
-0.5992221832275391,
-0.22508612275123596,
0.38559263944625854,
-0.415081650018692,
-0.069693498... | |
support. That would be the only reason in my opinion to use the ASP.NET Mobile support, is if you want to support WML enabled phones also. | [
0.4168635606765747,
-0.28869107365608215,
0.6580049395561218,
0.25708380341529846,
0.01195057574659586,
-0.40722033381462097,
0.1398734152317047,
0.10052752494812012,
-0.2956584692001343,
-0.4409271776676178,
-0.32552748918533325,
0.5343547463417053,
-0.2611966133117676,
-0.272456914186477... | |
I've been making my way through *The Little Schemer* and I was wondering what environment, IDE or interpreter would be best to use in order to test any of the Scheme code I jot down for myself.
[Racket](http://racket-lang.org/) ([formerly Dr Scheme](http://racket-lang.org/new-name.html)) has a nice editor, several diff... | [
0.33020052313804626,
-0.22893711924552917,
0.24718348681926727,
-0.25994357466697693,
-0.1066468209028244,
-0.08137879520654678,
0.25584718585014343,
0.11759450286626816,
-0.4714798629283905,
-0.6382306218147278,
-0.1777111142873764,
0.16069839894771576,
-0.061940472573041916,
-0.213736787... | |
As much as we would all like to say it is a benefit to programmers to be language agnostic, is it really feasible to support multiple enterprise Web applications of the same type all written in different languages? Think about how complicated a CMS or e-commerce system can be -- now imagine supporting three different C... | [
0.37196770310401917,
0.3196018934249878,
-0.28444671630859375,
0.3486594557762146,
0.027147287502884865,
-0.13732346892356873,
0.3047196865081787,
0.30699193477630615,
-0.3029387593269348,
-0.4082562029361725,
0.06170807406306267,
0.5870556235313416,
-0.3377918303012848,
-0.000847441144287... | |
who wonders why we can't get something done right on time. Can anyone speak from experience on this? Does your company usually just suck it up, and try and to learn a new platform on the fly? Do you bill up-to-speed, or eat those costs?
[Racket](http://racket-lang.org/) ([formerly Dr Scheme](http://racket-lang.org/new-... | [
0.6238265037536621,
-0.2879517674446106,
0.08395259082317352,
0.007474386598914862,
0.02065972611308098,
0.014834885485470295,
-0.0225814338773489,
0.10260553658008575,
-0.6120413541793823,
-0.5716731548309326,
0.012942871078848839,
0.23356248438358307,
-0.1826353371143341,
-0.304504066705... | |
Is there a system stored procedure to get the version #?
Try
```
SELECT @@VERSION
```
or for SQL Server 2000 and above the following is easier to parse :)
```
SELECT SERVERPROPERTY('productversion')
, SERVERPROPERTY('productlevel')
, SERVERPROPERTY('edition')
```
From: <http://support.microsoft.com/k... | [
0.035899609327316284,
-0.16778376698493958,
0.503621518611908,
-0.2788017988204956,
-0.07026807218790054,
-0.13836874067783356,
-0.08377858251333237,
-0.1245860680937767,
-0.2845260202884674,
-0.34624040126800537,
-0.20114266872406006,
0.23188306391239166,
-0.3485269546508789,
0.1481497436... | |
I'd like to make some custom MenuHeaders in WPF so I can have (for example), an icon and text in a menu item.
Normally using MenuItems, if you populate the Header field with straight text, you can add an accelerator by using an underscore. eg, \_File
However, if I wanted to put in a UserControl, I believe this functi... | [
0.28366127610206604,
-0.0027441284619271755,
0.29102790355682373,
0.08461272716522217,
-0.023503897711634636,
-0.005000410135835409,
-0.06441966444253922,
-0.24734550714492798,
-0.5121192932128906,
-0.878165602684021,
0.21868054568767548,
0.714289665222168,
-0.3095645308494568,
0.047767683... | |
</MenuItem.Header>
</MenuItem>
...
```
I think the Icon property fits your needs.
However to answer the original question, it is possible to retain the Accelerator functionality when you compose the content of your menuitem. **If you have nested content in a MenuItem you need to define the AccessText property expli... | [
0.026204315945506096,
0.20069347321987152,
0.4548588693141937,
0.06613568216562271,
0.15621371567249298,
0.23884105682373047,
-0.15434370934963226,
-0.24184739589691162,
-0.46517202258110046,
-0.8907803297042847,
0.07809199392795563,
0.7009289860725403,
-0.36985424160957336,
-0.14260962605... | |
<AccessText>_Open..</AccessText>
</StackPanel>
</MenuItem.Header>
</MenuItem>
<MenuItem Header="_Close" />
</Menu>
``` | [
-0.4198245704174042,
0.3180893063545227,
0.48128843307495117,
-0.29212456941604614,
0.2925311028957367,
-0.03241432458162308,
-0.1020122691988945,
-0.1872774213552475,
-0.19458262622356415,
-0.7584177255630493,
-0.5941042304039001,
0.3702597916126251,
-0.10813871771097183,
0.18481312692165... | |
A former coworker insisted that a database with more tables with fewer columns each is better than one with fewer tables with more columns each. For example rather than a customer table with name, address, city, state, zip, etc. columns, you would have a name table, an address table, a city table, etc.
He argued this ... | [
0.07526935636997223,
0.13996180891990662,
-0.06541936844587326,
0.4883134365081787,
0.18584609031677246,
0.05176328122615814,
-0.12127958238124847,
0.02588745392858982,
-0.4682351052761078,
-0.693311870098114,
0.03485725075006485,
0.20711755752563477,
-0.33345770835876465,
0.24320116639137... | |
tables with fewer columns over fewer tables with more columns?
I have a few fairly simple rules of thumb I follow when designing databases, which I think can be used to help make decisions like this....
1. Favor normalization. Denormalization is a form of optimization, with all the requisite tradeoffs, and as such it ... | [
-0.08985960483551025,
0.20398105680942535,
0.19935372471809387,
0.16205759346485138,
-0.20036651194095612,
0.026594189926981926,
0.15535826981067657,
-0.07453904300928116,
-0.3204689919948578,
-0.7079644203186035,
0.006293572951108217,
0.6236512064933777,
-0.4039596915245056,
-0.2289132773... | |
Use views or downstream tables to implement denormalization rather than denormalizing the core of the schema, *when data volume and usage scenarios allow for it*.
The usual result of these rules is that the initial design will favor tables over columns, with a focus on eliminating redundancy. As the project progresses... | [
0.05213916674256325,
0.012919308617711067,
0.3046678304672241,
0.26636746525764465,
-0.08677732944488525,
0.1563194841146469,
0.001957840286195278,
-0.11350465565919876,
-0.15295958518981934,
-0.6879438757896423,
-0.21829770505428314,
0.39224737882614136,
-0.25765231251716614,
0.0533340275... | |
Of all the forms of CAPTCHA available, which one is the "least crackable" while remaining fairly human readable?
I agree with Thomas. Captcha is on its way out. But if you must use it, [reCAPTCHA](http://www.recaptcha.net) is a pretty good provider with a simple API. | [
0.20049388706684113,
-0.1405736356973648,
0.3750165104866028,
0.29445236921310425,
-0.04516400769352913,
-0.536655843257904,
0.4620083272457123,
0.5025240182876587,
-0.32723382115364075,
-0.5896681547164917,
-0.30478107929229736,
0.5033868551254272,
-0.09789487719535828,
0.0962872505187988... | |
I understand the main function of the lock key word from MSDN
> lock Statement (C# Reference)
>
>
> The lock keyword marks a statement
> block as a critical section by
> obtaining the mutual-exclusion lock
> for a given object, executing a
> statement, and then releasing the
> lock.
When should the lock be use... | [
0.20740099251270294,
0.20752696692943573,
0.2194647192955017,
-0.00648094667121768,
0.1710844784975052,
-0.29828760027885437,
0.21758995950222015,
-0.2995677590370178,
-0.050682906061410904,
-0.4334334433078766,
-0.29025572538375854,
0.3143693804740906,
-0.359174519777298,
0.28037717938423... | |
it is single threaded and I want to know should I leave them in, are they even necessary?
Please note this is more of a general knowledge question, the application speed is fine, I want to know if that is a good design pattern to follow in the future or should this be avoided unless absolutely needed.
> When should th... | [
0.4965462386608124,
0.13919663429260254,
0.21624629199504852,
0.227338507771492,
0.11310737580060959,
-0.3166140615940094,
0.2884595990180969,
-0.26057198643684387,
-0.4149380326271057,
-0.3390384614467621,
-0.05083252862095833,
0.5095798969268799,
-0.3580487072467804,
0.22768819332122803,... | |
sure that you're not implicitly using system threads. For example if you use asynchronous I/O you may receive callbacks from a random thread, not your original thread.
> Is there performance issues with using lock?
Yes. They're not very big in a single-threaded application, but why make calls you don't need?
> ...if... | [
0.47326549887657166,
-0.04622877389192581,
-0.1984473168849945,
0.5264912843704224,
0.17146576941013336,
-0.4266044795513153,
0.47484272718429565,
0.11353766918182373,
-0.27475008368492126,
-0.32051292061805725,
0.10970182716846466,
0.45363903045654297,
-0.41862016916275024,
-0.06852898001... | |
threads requires careful design, and the more you can isolate the tricky part, the better. | [
0.389034628868103,
-0.3346380591392517,
-0.16238175332546234,
0.38788220286369324,
0.14383769035339355,
0.07358122617006302,
0.43784666061401367,
-0.058271605521440506,
-0.4892004132270813,
-0.5612213015556335,
-0.1485663801431656,
-0.0861884355545044,
-0.21154466271400452,
0.3122757077217... | |
The IT lady just gave me a laptop to keep!
I've always wanted to have Linux install to play with so the first thing I did is search stackoverflow for Linux Distro suggestions and found it [here](https://stackoverflow.com/questions/659/what-is-your-preferred-linux-distribution#6730). However they also mention that you... | [
0.11599451303482056,
0.16219066083431244,
0.11680183559656143,
0.25836607813835144,
-0.15139788389205933,
0.0672287568449974,
-0.29616332054138184,
0.3273990750312805,
-0.005795320030301809,
-0.25762367248535156,
0.1031491607427597,
0.6972038745880127,
0.09786147624254227,
0.45198026299476... | |
choose to use? Should I just be googling Ubunto+DriverName or are there better resources?
You can try [Linux-On-Laptops](http://www.linux-on-laptops.com). A quick search shows this [Tecra A5](http://cuentame.algocorto.com/linux/ubuntu-dapper-tecra-a5.html).
You can also download a LiveCD version, that will tell you if... | [
0.45861124992370605,
-0.049462515860795975,
0.08831112086772919,
0.2042611837387085,
-0.032647304236888885,
-0.041053202003240585,
-0.08311532437801361,
0.407787561416626,
-0.16715490818023682,
-0.7631487250328064,
-0.018639737740159035,
0.8822468519210815,
-0.14146171510219574,
0.08475538... | |
I have a page results page (you get there after submitting your search query elsewhere) whit a whole bunch of gridviews for different type of data objects.
Obviously, some of the queries take longer than the others. How can I make each gridview render as soon as it has the data it needs?
This has been tricky for me b... | [
0.39885735511779785,
0.03582251816987991,
0.6676098108291626,
-0.15337730944156647,
-0.1018238216638565,
0.21366894245147705,
0.5500295162200928,
-0.20786722004413605,
-0.13626639544963837,
-1.0229802131652832,
0.048233140259981155,
0.512471616268158,
-0.1276160031557083,
0.153738409280776... | |
all of the queries before returning even the first update panel, so he won't save any time there.
The trick to do this is to move each of your complex gridviews into a user control, in the user control, get rid of the Object DataSource crap, and do your binding in the code behind.
Write your bind code so that it only... | [
-0.005633254069834948,
-0.11099832504987717,
0.7932135462760925,
0.02422228269279003,
-0.19249190390110016,
-0.2244454175233841,
0.10511219501495361,
-0.45166897773742676,
-0.03148297965526581,
-1.1513983011245728,
-0.11074894666671753,
0.6562853455543518,
-0.29599541425704956,
-0.01134729... | |
Since our switch from Visual Studio 6 to Visual Studio 2008, we've been using the MFC90.dll and msvc[pr]90.dlls along with the manifest files in a private side-by-side configuration so as to not worry about versions or installing them to the system.
Pre-SP1, this was working fine (and still works fine on our developer... | [
0.7183354496955872,
-0.2784433662891388,
0.6674836277961731,
-0.19914695620536804,
-0.08637568354606628,
0.019970936700701714,
0.1680886298418045,
-0.14150728285312653,
-0.42400917410850525,
-0.5843777060508728,
-0.05840730294585228,
0.593669593334198,
-0.19467319548130035,
0.0776876136660... | |
the define for `_BIND_TO_CURRENT_VCLIBS_VERSION=1` to all of our projects so that they will use the SP1 DLLs in the redist folder (or subsequent ones as new service packs come out). It took me hours to find this.
I've double checked the generated manifest files in the intermediate files folder from the compilation, an... | [
0.29669567942619324,
0.08052361011505127,
0.7431030869483948,
-0.019725434482097626,
0.22720907628536224,
-0.128297820687294,
0.49940797686576843,
-0.12911441922187805,
-0.12750989198684692,
-0.5643270015716553,
-0.16289371252059937,
0.46178871393203735,
-0.2774457037448883,
0.236785814166... | |
the application.
None of the searches I've done on google or microsoft have come up with anything that relates to my specific issues (but there are hits back to 2005 with this error message).
Any one had any similar problem with SP1?
Options:* Find the problem and fix it so it works as it should (preferred)
* Instal... | [
0.3677193224430084,
0.051997989416122437,
0.4451185166835785,
0.14663852751255035,
0.06720475852489471,
-0.2707318067550659,
0.6202263832092285,
-0.16767027974128723,
-0.3065241873264313,
-0.8400712013244629,
-0.1566200852394104,
0.8968741297721863,
-0.32330968976020813,
-0.036365829408168... | |
to RTM dlls), and that works as long as the RTM dlls are installed in the folder. If the SP1 dlls are dropped in, it gets the following error:
> c:\Program Files\...\...\X.exe
>
>
> This application has failed to start because the application configuration is incorrect. Reinstalling the application may fix this prob... | [
0.295783668756485,
0.002068873727694154,
0.754453182220459,
-0.10969536006450653,
0.10961364954710007,
-0.14549730718135834,
0.5939599871635437,
-0.42776474356651306,
-0.3234955668449402,
-0.6562299728393555,
-0.25560832023620605,
1.1924190521240234,
-0.269604355096817,
0.09182829409837723... | |
myself last week and consider myself somewhat of an expert now ;)
I'm 99% sure that not all dlls and static libraries were recompiled with the SP1 version. You need to put
```
#define _BIND_TO_CURRENT_MFC_VERSION 1
#define _BIND_TO_CURRENT_CRT_VERSION 1
```
into *every* project you're using. For every project of a ... | [
0.1697407066822052,
0.03921430557966232,
0.7213152050971985,
-0.04113001376390457,
-0.1057034283876419,
-0.4633748233318329,
0.11980690062046051,
-0.19602732360363007,
-0.41831526160240173,
-0.8387280702590942,
-0.12883737683296204,
0.5847084522247314,
-0.28591397404670715,
0.2871274948120... | |
what the embedded manifest says. Download XM Resource Editor: <http://www.wilsonc.demon.co.uk/d10resourceeditor.htm>. Open every dll and exe in your solution. Look under 'XP Theme Manifest'. Check that the 'version' attribute on the right-hand side is '9.0.30729.1'. If it's '9.0.21022', some static library is pulling i... | [
0.3833937346935272,
-0.004241551738232374,
0.6397264003753662,
0.2949801981449127,
-0.013746966607868671,
-0.36940503120422363,
0.28692710399627686,
-0.12396057695150375,
-0.25410008430480957,
-0.5239428281784058,
-0.4286167025566101,
0.5181151628494263,
-0.19884933531284332,
-0.0061862901... | |
embed the old manifest. Open C:\Program Files\Microsoft Visual Studio 9.0\VC\crt\include\crtassem.h. Search for the '21022' string. In that define, put something invalid (change 'define' to 'blehbleh' or so). This way, when you're compiling a project where the `_BIND_TO_CURRENT_CRT_VERSION` preprocessor flag is not set... | [
0.28496357798576355,
0.2079075276851654,
0.43082958459854126,
-0.05918371304869652,
0.10267727822065353,
-0.2019995152950287,
0.21682605147361755,
0.038059934973716736,
-0.44455090165138245,
-0.8619270920753479,
-0.14233402907848358,
0.41440320014953613,
-0.4713749289512634,
0.149244412779... | |
for sure that there is nothing in the SxS folder that is being used instead of the side-by-side dlls that you supplied. | [
0.4263973832130432,
-0.06914845108985901,
-0.0669894814491272,
0.37243151664733887,
0.3008743226528168,
-0.3539431095123291,
0.10246539860963821,
0.4247971475124359,
-0.24013471603393555,
-0.3489075303077698,
-0.030213575810194016,
0.5571770668029785,
-0.1335851550102234,
-0.01246568094938... | |
What's the best way to determine which version of the .NET Compact Frameworks (including Service Packs) is installed on a device through a .NET application.
I have battled this problem myself last week and consider myself somewhat of an expert now ;)
I'm 99% sure that not all dlls and static libraries were recompiled ... | [
0.13867110013961792,
0.03984154388308525,
0.6493123173713684,
-0.006472943350672722,
0.09886328130960464,
-0.5240590572357178,
0.184189572930336,
-0.31122446060180664,
-0.3867153823375702,
-0.8825225830078125,
-0.23825675249099731,
0.45939669013023376,
-0.2376958727836609,
0.01317778136581... | |
. As an alternative to the lines above, you can also put
```
#define _BIND_TO_CURRENT_VCLIBS_VERSION 1
```
which will bind to the latest version of all VC libs (CRT, MFC, ATL, OpenMP).
Then, check what the embedded manifest says. Download XM Resource Editor: <http://www.wilsonc.demon.co.uk/d10resourceeditor.htm>. O... | [
0.2329431176185608,
-0.03809017315506935,
0.8613941073417664,
0.21610194444656372,
0.06250052899122238,
-0.2869783639907837,
0.15712116658687592,
-0.07285579293966293,
-0.43061965703964233,
-0.6856644153594971,
-0.3727130889892578,
0.48261240124702454,
-0.2977326214313507,
0.29806005954742... | |
version and others don't.
A great way to debug which libraries don't have the preprocessor directives set: temporarily modify your platform headers so that compilation stops when it tries to embed the old manifest. Open C:\Program Files\Microsoft Visual Studio 9.0\VC\crt\include\crtassem.h. Search for the '21022' stri... | [
0.30459147691726685,
0.08986110985279083,
0.39278268814086914,
-0.15929269790649414,
0.14421230554580688,
-0.33385705947875977,
0.393026202917099,
0.1925528645515442,
-0.43797415494918823,
-0.8399802446365356,
-0.2563096880912781,
0.4296068549156189,
-0.43558362126350403,
0.195455372333526... | |
know what dlls are being pulled in. It's easiest to install a fresh Windows XP copy with no updates (only SP2) on a virtual machine. This way you know for sure that there is nothing in the SxS folder that is being used instead of the side-by-side dlls that you supplied. | [
0.45823103189468384,
-0.11528930068016052,
0.3937891721725464,
0.3413769602775574,
-0.027363020926713943,
-0.44811999797821045,
0.041676707565784454,
0.2583937644958496,
-0.4768509268760681,
-0.5000742077827454,
-0.23163627088069916,
0.6110973358154297,
-0.13138598203659058,
-0.08467645198... | |
Erasing programs such as Eraser recommend overwriting data maybe 36 times.
As I understand it all data is stored on a hard drive as 1s or 0s.
If an overwrite of random 1s and 0s is carried out once over the whole file then why isn't that enough to remove all traces of the original file?
A hard drive bit which used to... | [
0.17849412560462952,
0.3175853192806244,
-0.0159456729888916,
0.1606711447238922,
0.2955433130264282,
0.007677301298826933,
0.37915199995040894,
0.10749748349189758,
-0.43771854043006897,
-0.33122196793556213,
-0.16834092140197754,
0.1953277289867401,
-0.2450358122587204,
0.334813416004180... | |
can be discerned with a reasonable degree of accuracy, by measuring the slight variances in strength. The result won't be exactly correct and there will be errors, but a good portion of the previous contents can be retrieved.
By the time you've scribbled over the bits 35 times, it is effectively impossible to discern ... | [
0.14829950034618378,
0.2577638030052185,
0.11776845157146454,
0.25769707560539246,
0.25363799929618835,
0.0021500682923942804,
0.4109698534011841,
-0.1792329102754593,
-0.47937628626823425,
-0.23824618756771088,
-0.37612438201904297,
0.059775564819574356,
-0.1927882581949234,
0.24804778397... | |
been necessary when working with floppy disks or some other medium, but hard disks do not need it. | [
0.10695591568946838,
-0.021817423403263092,
0.19357244670391083,
0.22208108007907867,
0.33888673782348633,
-0.4449343979358673,
-0.44578585028648376,
0.18468835949897766,
-0.46031272411346436,
-0.40319788455963135,
-0.4589371979236603,
0.8187786340713501,
0.13290676474571228,
-0.0671241581... | |
I realize that CHAR is recommended if all my values are fixed-width. But, so what? Why not just pick VARCHAR for all text fields just to be safe.
The general rule is to pick **CHAR** if all rows will have close to the *same length*. Pick **VARCHAR** (or *NVARCHAR*) when the *length varies* significantly. CHAR may also ... | [
-0.05329051986336708,
0.17730389535427094,
0.28570351004600525,
-0.19024281203746796,
-0.36325517296791077,
0.19493676722049713,
0.3474369943141937,
-0.1515136957168579,
-0.11834181845188141,
-0.4996374845504761,
0.04436860606074333,
0.5980832576751709,
-0.020777253434062004,
0.11961358040... | |
using a one-byte character set) storing the word "FooBar"
* **CHAR(6)** = 6 bytes *(no overhead)*
* **VARCHAR(100)** = 8 bytes *(2 bytes of overhead)*
* **CHAR(10)** = 10 bytes *(4 bytes of waste)*
The bottom line is **CHAR** *can* be *faster* and more *space-efficient* for data of relatively the same length (within ... | [
0.27278944849967957,
0.2413082867860794,
0.3302227258682251,
-0.015198204666376114,
-0.1678892970085144,
0.11584047973155975,
0.22469180822372437,
-0.3988473415374756,
-0.23765724897384644,
-0.44229990243911743,
-0.025551937520503998,
0.5419432520866394,
-0.11578836292028427,
0.01507034339... | |
it comes to [multi-byte characters](http://dev.mysql.com/doc/refman/5.0/en/charset-unicode-utf8.html) sets, and is a is case where VARCHAR becomes a much better choice.
*A note about the declared length of the **VARCHAR***: Because it stores the length of the actual content, then you don't waste unused length. So stor... | [
-0.02900560386478901,
0.051370769739151,
0.39645320177078247,
-0.1427147537469864,
-0.11654358357191086,
0.2984449565410614,
0.22133196890354156,
-0.19965562224388123,
-0.37704992294311523,
-0.4917486011981964,
-0.24035805463790894,
0.3780738115310669,
0.053813278675079346,
0.1321107447147... | |
at least the docs are unclear. | [
0.5131263732910156,
0.1806224286556244,
0.1152145192027092,
-0.052160900086164474,
0.16437767446041107,
-0.11831112205982208,
0.08641333132982254,
0.11268363893032074,
-0.11835037171840668,
-0.16413138806819916,
0.1258155256509781,
0.44900524616241455,
0.19141390919685364,
-0.0155433379113... | |
Is there an equivalent operator to Haskell's list difference operator `\\` in F#?
Was bounced, yet I believe it is worth to write here the implementation of `( /-/ )` (the F# version of Haskell's `\\`):
```
let flip f x y = f y x
let rec delete x = function
| [] -> []
| h :: t when x = h -> t
| h :: t -> h :: d... | [
-0.07569676637649536,
-0.6099328398704529,
0.567726731300354,
-0.030293717980384827,
-0.38190868496894836,
-0.1103115901350975,
0.08763917535543442,
-0.3064134418964386,
-0.1547030806541443,
-0.415507435798645,
-0.04268988221883774,
0.8311513066291809,
-0.5269594788551331,
-0.1227234825491... | |
ys`. For example: `(7 :: [1 .. 5] @ [5 .. 11]) /-/ [4 .. 7]` evaluates into `[1; 2; 3; 5; 7; 8; 9; 10; 11]`. | [
-0.021936379373073578,
0.2795918881893158,
0.3149450421333313,
-0.3315255343914032,
-0.13938438892364502,
0.44362932443618774,
0.4209405481815338,
-0.012829012237489223,
0.2013518065214157,
-0.2522706687450409,
-0.5378989577293396,
0.531296968460083,
-0.09607727080583572,
0.041175346821546... | |
The most common method for corrupting compressed files is to inadvertently do an ASCII-mode FTP transfer, which causes a many-to-one trashing of CR and/or LF characters.
Obviously, there is information loss, and the best way to fix this problem is to transfer again, in FTP binary mode.
However, if the original is los... | [
0.011005193926393986,
0.10219462215900421,
0.05421315133571625,
0.376033753156662,
0.28156089782714844,
-0.09716907143592834,
0.2639286518096924,
0.24773266911506653,
-0.26343661546707153,
-0.43150708079338074,
-0.3242776095867157,
0.4535715579986572,
-0.13655725121498108,
0.24885827302932... | |
interesting to try out this question during the stackoverflow beta period, and see if anyone else has gone down the successful-recovery path or discovered tools I don't know about.]
From [Bukys Software](http://wayback.archive.org/web/jsp/Interstitial.jsp?seconds=5&date=1195189396000&url=http%3A%2F%2Fwww.bukys.com%2Fse... | [
-0.2702687382698059,
0.16109830141067505,
0.2569577991962433,
0.03465241938829422,
-0.048662349581718445,
0.05835200473666191,
0.5109872221946716,
-0.09057052433490753,
-0.3000679612159729,
-0.5489566922187805,
-0.2907087206840515,
0.488138347864151,
-0.28969845175743103,
0.255193710327148... | |
bad, 0.29%
> is suspect.
>
>
> ...
>
>
> An error in the compressed input
> disrupts the decompression process for
> all subsequent bytes...The fact that
> the decompressed output is
> recognizably bad so quickly is cause
> for hope -- a search for the correct
> answer can identify wrong answers
> quickly.
... | [
-0.2643132209777832,
0.2391081154346466,
0.025633996352553368,
0.2943284511566162,
-0.12830962240695953,
0.11679891496896744,
0.43659988045692444,
-0.33360347151756287,
0.029197046533226967,
-0.42070502042770386,
-0.3511567711830139,
0.4114137887954712,
-0.34819597005844116,
0.112874791026... | |
due to other causes (e.g. disk full while
> logging)
> * Lookahead for guiding the search along the highest-probability paths
>
>
> These techniques identify 75% of the
> necessary repairs with certainty, and
> the remainder are explored
> highest-probability-first, so that
> plausible reconstructions are
> ide... | [
-0.10367188602685928,
0.2739059627056122,
0.1663978099822998,
0.04725181311368942,
0.33074167370796204,
-0.011354586109519005,
0.5553842782974243,
-0.38145002722740173,
-0.20605456829071045,
-0.7795762419700623,
-0.7046258449554443,
0.7237941026687622,
0.28734511137008667,
-0.1818399876356... | |
I need to disable specific keys (Ctrl and Backspace) in Internet Explorer 6. Is there a registry hack to do this. It has to be IE6. Thanks.
Long Edit:
@apandit: Whoops. I need to more specific about the backspace thing. When I say disable backspace, I mean disable the ability for Backspace to mimic the Back browser ... | [
0.2544780671596527,
-0.023361902683973312,
0.4312974214553833,
-0.023674650117754936,
-0.20263372361660004,
-0.2822831869125366,
0.6305682063102722,
0.32514259219169617,
0.00840463675558567,
-0.9740049242973328,
-0.23317599296569824,
0.7642610669136047,
-0.45290815830230713,
0.041257072240... | |
popup blocker turned on, which block this. But, Ctrl clicking result in the new window being launched.
This is for a kiosk application, which is currently a web based application. Clients do not have the funds at this time to make their site kiosk friendly. Things like URL filtering and disabling the URL entry field i... | [
0.1409640610218048,
-0.06485641002655029,
0.4601156711578369,
-0.01631932333111763,
-0.11675868183374405,
0.18363255262374878,
0.22630095481872559,
0.04789833724498749,
-0.49775758385658264,
-0.5576780438423157,
-0.22577932476997375,
0.2243782877922058,
-0.56894451379776,
0.323536604642868... | |
choosing `a` as `2` and `b` as `1`. (The number of such coincidences explodes as the numbers grow.)
The traditional way to attack such a problem is [dynamic programming](http://en.wikipedia.org/wiki/Dynamic_programming): build a table bottom-up of the solutions to the sub-problems (starting with "how many combinations... | [
-0.15391905605793,
-0.1385919749736786,
0.0492318831384182,
-0.0496211051940918,
-0.2555275559425354,
-0.08952067047357559,
0.3125712275505066,
-0.1869300901889801,
-0.4209805428981781,
-0.2556617856025696,
-0.5820459723472595,
0.5362196564674377,
-0.6496706604957581,
0.07296795397996902,
... | |
{
// tab[i][j] is how many combinations of (i+1) vars add up to j
long[][] tab = new long[n][sum+1];
// # of combos of 1 var for any sum is 1
for( int j=0; j < tab[0].length; ++j ) {
tab[0][j] = 1;
}
for( int i=1; i < tab.length; ++i ) {
for( int j=0; j < tab[i].length; ++j ) {
// # combos of ... | [
0.18076898157596588,
-0.4058287441730499,
0.30005714297294617,
-0.3521025776863098,
-0.16570712625980377,
0.40421730279922485,
0.5550630688667297,
-1.0880252122879028,
-0.3315216600894928,
-0.17558196187019348,
-0.148540198802948,
0.4809061288833618,
-0.5331659913063049,
-0.241277053952217... | |
// of combos of i vars adding up to k, for all 0 <= k <= j
// (choosing i vars forces the choice of the (i+1)st).
tab[i][j] = 0;
for( int k=0; k <= j; ++k ) {
tab[i][j] += tab[i-1][k];
}
}
}
return tab[n-1][sum];
}
```
```
$ time java Combos
2656615626
real 0m0.151s
user ... | [
-0.060604073107242584,
-0.30319923162460327,
0.2592962682247162,
-0.3924608826637268,
0.13150224089622498,
0.46648916602134705,
0.5821892023086548,
-0.8856353759765625,
-0.27650439739227295,
-0.5129401087760925,
0.021865878254175186,
0.5331306457519531,
-0.4276648759841919,
-0.014351970516... | |
I would like to be able to define and use a custom type in some of my PowerShell scripts. For example, let's pretend I had a need for an object that had the following structure:
```
Contact
{
string First
string Last
string Phone
}
```
How would I go about creating this so that I could use it in function... | [
-0.002075597643852234,
-0.025682972744107246,
0.44491103291511536,
0.02414771541953087,
0.010678493417799473,
0.02220098301768303,
0.00617718743160367,
-0.20546042919158936,
-0.16516363620758057,
-0.4044014811515808,
0.0926467701792717,
0.5621610283851624,
-0.5209097862243652,
-0.041027244... | |
this possible, or even recommended in PowerShell?
Prior to PowerShell 3
---------------------
PowerShell's Extensible Type System didn't originally let you create concrete types you can test against the way you did in your parameter. If you don't need that test, you're fine with any of the other methods mentioned abov... | [
0.348699152469635,
0.027191605418920517,
0.3035924732685089,
-0.08059219270944595,
0.009562119841575623,
-0.41386717557907104,
0.18506579101085663,
-0.16497772932052612,
0.03461843356490135,
-0.5922297239303589,
0.055165186524391174,
0.6790347695350647,
-0.6295733451843262,
-0.123416155576... | |
public string First;
public string Last;
public string Phone;
}
"@
```
***Historical Note***: In PowerShell 1 it was even harder. You had to manually use CodeDom, there is a very old function [new-struct](http://poshcode.org/scripts/190) script on PoshCode.org which will help. Your example becomes:
```
New-Str... | [
-0.05514625832438469,
-0.19128747284412384,
0.28797924518585205,
-0.00399003503844142,
-0.05207149311900139,
-0.23763668537139893,
0.20202061533927917,
-0.3961922228336334,
-0.04381002485752106,
-0.501645028591156,
-0.08429008722305298,
0.7201024293899536,
-0.6060060858726501,
-0.212620407... | |
the Add-Member way that [Steven and others have demonstrated](https://stackoverflow.com/a/59980/8718) above.
Since PowerShell 2 you could use the -Property parameter for New-Object:
```
$Contact = New-Object PSObject -Property @{ First=""; Last=""; Phone="" }
```
And in PowerShell 3, we got the ability to use the `... | [
-0.1403064876794815,
-0.1454704850912094,
0.6349580883979797,
0.017784778028726578,
0.02102385088801384,
-0.17958684265613556,
0.05352059751749039,
-0.3917372226715088,
-0.3184211552143097,
-0.5123687982559204,
-0.13323301076889038,
0.5831298232078552,
-0.5242628455162048,
0.05996738374233... | |
"is" one of those type by decorating a parameter with the `PSTypeName` attribute:
```
function PrintContact
{
param( [PSTypeName("Contact")]$contact )
"Customer Name is " + $contact.First + " " + $contact.Last
"Customer Phone is " + $contact.Phone
}
```
In PowerShell 5
===============
In PowerShell 5 e... | [
-0.20549555122852325,
-0.22850632667541504,
0.7787168622016907,
-0.20022894442081451,
0.18994852900505066,
-0.2124110460281372,
-0.007231295574456453,
-0.13067443668842316,
-0.011980343610048294,
-0.5528175830841064,
-0.23527976870536804,
0.7918053269386292,
-0.446181058883667,
0.150539651... | |
constructor to
# force properties to be set:
Contact($First, $Last, $Phone) {
$this.First = $First
$this.Last = $Last
$this.Phone = $Phone
}
}
```
We also got a new way to create objects without using `New-Object`: `[Contact]::new()` -- in fact, if you kept your class simple and don'... | [
-0.04991714656352997,
-0.15044058859348297,
0.4352666735649109,
-0.013768451288342476,
-0.18368200957775116,
-0.20793254673480988,
0.21548642218112946,
-0.3554805517196655,
-0.0694815069437027,
-0.5843402147293091,
0.1062140166759491,
0.7830128073692322,
-0.4558238089084625,
0.089656472206... | |
set):
```
class Contact
{
# Optionally, add attributes to prevent invalid values
[ValidateNotNullOrEmpty()][string]$First
[ValidateNotNullOrEmpty()][string]$Last
[ValidateNotNullOrEmpty()][string]$Phone
}
$C = [Contact]@{
First = "Joel"
Last = "Bennett"
}
``` | [
0.17672108113765717,
0.021339857950806618,
0.4735540747642517,
-0.031716492027044296,
0.38594451546669006,
-0.16281414031982422,
0.2413366734981537,
-0.2874300181865692,
0.1876765489578247,
-0.30900320410728455,
-0.35507556796073914,
0.9112856388092041,
-0.5137824416160583,
-0.068795964121... | |
Suppose the following:
```
>>> s = set([1, 2, 3])
```
How do I get a value (any value) out of `s` without doing `s.pop()`? I want to leave the item in the set until I am sure I can remove it - something I can only be sure of after an asynchronous call to another host.
Quick and dirty:
```
>>> elem = s.pop()
>>> s.... | [
0.03386235609650612,
-0.0675172507762909,
0.40421056747436523,
0.0648670345544815,
0.11924748122692108,
-0.16741830110549927,
0.2679555416107178,
-0.5042874813079834,
-0.1656583547592163,
-0.7249954342842102,
-0.43749573826789856,
0.21919500827789307,
-0.27552926540374756,
0.13701294362545... | |
or slicing. | [
0.30876296758651733,
-0.17546144127845764,
-0.38062629103660583,
0.09022606909275055,
-0.37841808795928955,
0.44299256801605225,
-0.37207159399986267,
0.4010844826698303,
-0.32723021507263184,
-0.32050806283950806,
-0.027009855955839157,
0.5522329807281494,
0.18360206484794617,
-0.03768767... | |
I'd like to create a spring bean that holds the value of a double. Something like:
```
<bean id="doubleValue" value="3.7"/>
```
Declare it like this:
```
<bean id="doubleValue" class="java.lang.Double">
<constructor-arg index="0" value="3.7"/>
</bean>
```
And use like this:
```
<bean id="someOtherBean" ...>
... | [
0.4962034225463867,
0.10624048858880997,
-0.21252843737602234,
-0.2248147875070572,
-0.1494646519422531,
0.028543073683977127,
-0.011787192896008492,
0.18777279555797577,
-0.2359573096036911,
-0.37579435110092163,
0.1454281061887741,
0.08752499520778656,
-0.48719966411590576,
0.01938151009... | |
Should I use a dedicated network channel between the database and the application server?
...or...
Connecting both in the switch along with all other computer nodes makes no diference at all?
The matter is **performance!**
Declare it like this:
```
<bean id="doubleValue" class="java.lang.Double">
<constructor-a... | [
0.3046269416809082,
0.24149423837661743,
0.09480161964893341,
-0.12518247961997986,
0.12964457273483276,
-0.2531271278858185,
0.1982148140668869,
-0.1865892857313156,
-0.04085622727870941,
-0.7440704703330994,
0.14088091254234314,
0.49824658036231995,
-0.09268824756145477,
0.09562424570322... | |
I'm looking for a technique or tool which we can use to obfuscate or somehow secure our compiled c# code. The goal is not for user/data security but to hinder reverse engineering of some of the technology in our software.
This is not for use on the web, but for a desktop application.
So, do you know of any tools ava... | [
0.6570396423339844,
0.3063814043998718,
-0.1799471378326416,
0.36933737993240356,
0.1761551797389984,
-0.3973087668418884,
0.19177624583244324,
0.2966991066932678,
0.09362410753965378,
-0.3991911709308624,
0.11332285404205322,
0.524387538433075,
-0.28562524914741516,
0.20526248216629028,
... | |
How would obfuscation affect this?
This is a pretty good list of obfuscators from [Visual Studio Marketplace](https://marketplace.visualstudio.com/search?term=.net%20obfuscators&target=VS&category=All%20categories&vsVersion=&sortBy=Relevance)
Obfuscators
* [ArmDot](https://www.armdot.com/)
* [Crypto Obfuscator](http:/... | [
0.07344019412994385,
0.2680250406265259,
0.24072133004665375,
-0.09516771137714386,
-0.24515032768249512,
0.04804953560233116,
0.215644970536232,
-0.2981940507888794,
-0.1639406383037567,
-0.2865338623523712,
0.2091427594423294,
0.4765937328338623,
0.041936036199331284,
-0.0009081689640879... | |
How do I get the path of the directory in which a [Bash](http://en.wikipedia.org/wiki/Bash_%28Unix_shell%29) script is located, *inside* that script?
I want to use a Bash script as a launcher for another application. I want to change the working directory to the one where the Bash script is located, so I can operate o... | [
0.42049291729927063,
0.10002723336219788,
0.29690301418304443,
-0.05026354640722275,
-0.13466139137744904,
-0.20984704792499542,
0.29401445388793945,
-0.30456146597862244,
-0.0189372468739748,
-0.583360493183136,
0.027444802224636078,
0.7452078461647034,
-0.012666300870478153,
-0.051621939... | |
the last component of the path used to find the script is not a symlink (directory links are OK). If you also want to resolve any links to the script itself, you need a multi-line solution:
```
#!/usr/bin/env bash
SOURCE=${BASH_SOURCE[0]}
while [ -L "$SOURCE" ]; do # resolve $SOURCE until the file is no longer a syml... | [
-0.24988596141338348,
0.07628638297319412,
0.5533270239830017,
-0.08568381518125534,
0.02571685239672661,
-0.2302071750164032,
0.4300835132598877,
-0.3062628209590912,
-0.05194699019193649,
-0.7234396934509277,
-0.17128072679042816,
0.7855207324028015,
-0.16739554703235626,
0.0151831135153... | |
-P "$( dirname "$SOURCE" )" >/dev/null 2>&1 && pwd )
```
This last one will work with any combination of aliases, `source`, `bash -c`, symlinks, etc.
**Beware:** if you `cd` to a different directory before running this snippet, the result may be incorrect!
Also, watch out for [`$CDPATH` gotchas](http://bosker.wordp... | [
0.3052646219730377,
0.307508647441864,
0.37494587898254395,
-0.21941083669662476,
-0.04994701221585274,
-0.26664474606513977,
0.4090983271598816,
-0.23141241073608398,
-0.09302107244729996,
-0.3287818133831024,
-0.37000998854637146,
0.7750314474105835,
-0.38740184903144836,
-0.033655699342... | |
bash
SOURCE=${BASH_SOURCE[0]}
while [ -L "$SOURCE" ]; do # resolve $SOURCE until the file is no longer a symlink
TARGET=$(readlink "$SOURCE")
if [[ $TARGET == /* ]]; then
echo "SOURCE '$SOURCE' is an absolute symlink to '$TARGET'"
SOURCE=$TARGET
else
DIR=$( dirname "$SOURCE" )
echo "SOURCE '$SOUR... | [
-0.19603057205677032,
-0.03404858335852623,
0.4342156648635864,
-0.4206441342830658,
-0.09365303814411163,
-0.12553530931472778,
0.4470687806606293,
-0.804223895072937,
-0.19355402886867523,
-0.16737516224384308,
-0.2381293773651123,
0.6130962371826172,
-0.25851869583129883,
-0.11737933009... | |
"$SOURCE" )
DIR=$( cd -P "$( dirname "$SOURCE" )" >/dev/null 2>&1 && pwd )
if [ "$DIR" != "$RDIR" ]; then
echo "DIR '$RDIR' resolves to '$DIR'"
fi
echo "DIR is '$DIR'"
```
And it will print something like:
```none
SOURCE './scriptdir.sh' is a relative symlink to 'sym2/scriptdir.sh' (relative to '.')
SOURCE is './s... | [
-0.28945431113243103,
0.07371833920478821,
0.43353649973869324,
-0.4838666617870331,
0.13375224173069,
0.05658991262316704,
0.23275257647037506,
-0.5184445977210999,
0.20852936804294586,
-0.34099578857421875,
-0.27324286103248596,
0.7481591105461121,
-0.30389925837516785,
0.030483333393931... | |
I have a page that uses
```
$(id).show("highlight", {}, 2000);
```
to highlight an element when I start a ajax request, that might fail so that I want to use something like
```
$(id).show("highlight", {color: "#FF0000"}, 2000);
```
in the error handler. The problem is that if the first highlight haven't finished... | [
-0.1032554879784584,
-0.030780024826526642,
0.33709651231765747,
-0.04455406963825226,
-0.2459370642900467,
0.020134661346673965,
0.100777268409729,
-0.05602755397558212,
-0.4120626449584961,
-0.6997326016426086,
-0.17230826616287231,
0.19831477105617523,
-0.27433329820632935,
0.0864390581... | |
for instance, an element is being hidden with `.slideUp()` when `.stop()` is called, the element will now still be displayed, but will be a fraction of its previous height. Callback functions are not called.
>
>
> If more than one animation method is called on the same element, the later animations are placed in the ... | [
0.13878081738948822,
-0.18831662833690643,
0.6601255536079407,
-0.041710641235113144,
0.1578579992055893,
0.06144140660762787,
0.13655847311019897,
-0.09271636605262756,
-0.23986412584781647,
-0.44662904739379883,
-0.5732693672180176,
0.3922487497329712,
-0.11231444031000137,
0.10556194931... | |
the queue are removed and never run.
>
>
> If the `jumpToEnd` argument is provided with a value of true, the current animation stops, but the element is immediately given its target values for each CSS property. In our above `.slideUp()` example, the element would be immediately hidden. The callback function is then ... | [
0.15995262563228607,
-0.19907145202159882,
0.5205010175704956,
-0.08340946584939957,
0.1918392777442932,
-0.11874639242887497,
0.3215707838535309,
0.05543266236782074,
-0.10473915189504623,
-0.22335807979106903,
-0.5209927558898926,
0.3360035717487335,
-0.4176141023635864,
0.24060466885566... | |
I need to write a web application using SQL Server 2005, asp.net, and ado.net. Much of the user data stored in this application must be encrypted (read HIPAA).
In the past for projects that required encryption, I encrypted/decrypted in the application code. However, this was generally for encrypting passwords or credi... | [
0.16440168023109436,
0.6561569571495056,
0.2677115499973297,
-0.15420261025428772,
-0.031169423833489418,
-0.2758868932723999,
0.4148540198802948,
-0.2721173167228699,
0.23767100274562836,
-0.5505362749099731,
0.1468016654253006,
0.5068162083625793,
-0.2535022497177124,
-0.1182019114494323... | |
types. (I could be convinced otherwise if anyone has real, empirical evidence.)
I've consulted BOL, and I'm fairly adept at using google. So I don't want links to online articles or MSDN documentation (its likely I've already read it).
One approach I've wrapped my head around so far is to use a symmetric key which is... | [
0.46747344732284546,
0.19918769598007202,
0.16005297005176544,
0.16583018004894257,
0.07876896113157272,
-0.36774852871894836,
0.31900811195373535,
-0.37490114569664,
-0.070041723549366,
-0.6541332602500916,
-0.34107324481010437,
0.6032655835151672,
-0.5382835865020752,
0.20114105939865112... | |
a file, burn to CD and store off site.
5. Create the Symmetric key with encryption algorithm of choice using the certificate.
Then anytime a stored procedure (or a human user via Management Studio) needs to access encrypted data you have to first open the symmetric key, execute any tsql statements or batches, and then... | [
0.22488129138946533,
0.06888256222009659,
0.220046266913414,
0.21588005125522614,
0.11958663165569305,
-0.23861318826675415,
0.16446517407894135,
-0.09032247215509415,
-0.19381213188171387,
-0.543252170085907,
-0.6749981045722961,
0.45277145504951477,
-0.02451826073229313,
0.16622132062911... | |
the sproc? The danger I see is, what if something goes wrong with the tsql execution, and code sproc execution never reaches the statement that closes the key. I assume this means the key will remain open until sql kills the SPID that sproc executed on.
2. Should I instead consider making three database calls for any g... | [
0.11888433992862701,
0.04191794991493225,
0.6581746935844421,
-0.04832351207733154,
0.08418543636798859,
-0.36313116550445557,
0.23478099703788757,
-0.3886103332042694,
-0.3657680153846741,
0.06649602949619293,
-0.22659918665885925,
0.6384719610214233,
-0.4171600043773651,
-0.0565541237592... | |
to maximize the odds that an open key ultimately is closed.)
3. Any considerations should I need to use client side transactions (meaning my code is the client, and initiates a transaction, executes several sprocs, and then commits the transaction assuming success)?
1) Look into using TRY..CATCH in SQL 2005. Unfortunat... | [
0.07257270812988281,
0.007077561225742102,
0.30689653754234314,
-0.14365175366401672,
-0.1476583182811737,
-0.40465983748435974,
0.1633952409029007,
-0.4322538673877716,
-0.2338116466999054,
-0.41248443722724915,
-0.07782033085823059,
0.4641193449497223,
-0.1783139854669571,
-0.07401435077... | |
until it's promoted to a distributed transaction). As for concerns with open/closing the key multiple times inside a transaction, I don't know of any issues to be aware of. | [
0.3366647958755493,
-0.13499616086483002,
0.5664607286453247,
-0.00477591110393405,
0.33401262760162354,
-0.3079375624656677,
0.0011808994458988309,
0.0162932388484478,
-0.47527340054512024,
-0.3612634241580963,
-0.21768327057361603,
0.4969600439071655,
0.08083684742450714,
0.2549930810928... | |
How do I get the key of the current element in a `foreach` loop in C#?
For example:
PHP
---
```
foreach ($array as $key => $value)
{
echo("$value is assigned to key: $key");
}
```
### What I'm trying to do in C#:
```
int[] values = { 5, 14, 29, 49, 99, 150, 999 };
foreach (int val in values)
{
if(search ... | [
0.06366749107837677,
0.04083054140210152,
0.44012099504470825,
-0.2887948453426361,
0.1866312325000763,
0.21379345655441284,
0.4769497513771057,
-0.7493249773979187,
-0.028474532067775726,
-0.33173510432243347,
-0.3150501847267151,
0.41074007749557495,
-0.14179188013076782,
-0.160695612430... | |
for loop or create a temp variable that you increment on each pass.
Which would of course look like this:
```
int[] values = { 5, 14, 29, 49, 99, 150, 999 };
for (int key = 0; key < values.Length; ++key)
if (search <= values[key] && !stop)
{
// set key to a variable
}
```
With .NET 3.5 you can take a mor... | [
0.30491629242897034,
-0.31392112374305725,
0.19450819492340088,
-0.1812742054462433,
0.0342288576066494,
-0.17996272444725037,
0.6783660054206848,
-0.0830024927854538,
-0.19813862442970276,
-0.4174072742462158,
-0.38064098358154297,
0.26941218972206116,
-0.6753069162368774,
0.1157137081027... | |
you need it for, but handy if you tend to do a lot of collection processing. | [
0.3387193977832794,
0.0915275290608406,
-0.1803329885005951,
0.3537222146987915,
0.3766177296638489,
-0.15452337265014648,
-0.24050725996494293,
0.08770954608917236,
-0.22216589748859406,
-0.2511134147644043,
0.21886752545833588,
0.5057548880577087,
0.2918395400047302,
-0.20136335492134094... | |
My question is pertaining to the best practice for accessing a child object's parent. So let's say a class instantiates another class, that class instance is now referenced with an object. From that child object, what is the best way to reference back to the parent object? Currently I know of a couple ways that I use o... | [
-0.050478141754865646,
-0.13474902510643005,
0.09041404724121094,
0.35934188961982727,
-0.07662884145975113,
0.11414066702127457,
0.10977475345134735,
0.1939368098974228,
-0.27514711022377014,
-0.7128908038139343,
0.15477581322193146,
0.21980351209640503,
0.055649831891059875,
0.3992666304... | |
it that was publicly declared.
```
_class:Class = getDefinitionByName("com.site.Class") as Class;
```
And then reference that variable based on its parent to child hierarchy.
Example, if the child is attempting to reference a class that's two levels up from itself:
```
_class(parent.parent).function();
```
Thi... | [
0.08089747279882431,
0.03084263578057289,
0.13569803535938263,
-0.06963726133108139,
0.015944771468639374,
-0.20613910257816315,
0.18613576889038086,
0.06284435838460922,
0.09303345531225204,
-0.6366276144981384,
-0.0728062093257904,
0.462391197681427,
-0.21696633100509644,
0.1362535953521... | |
outside of the current object I'm in.
Another method I've seen used is to simply pass a reference to this into the class object you are creating and just catch it with a constructor argument
```
var class:Class = new Class(this);
```
and then in the Class file
```
public function Class(objectRef:Object) {
_p... | [
0.12419326603412628,
0.004612375982105732,
0.35231685638427734,
-0.121377132833004,
0.3022218644618988,
-0.03479916602373123,
0.031487833708524704,
0.093461774289608,
-0.07909319549798965,
-0.5949339866638184,
-0.07594102621078491,
0.4387899935245514,
-0.2675066888332367,
0.481007665395736... | |
parent to child relationship is irrelevant because I'm accessing the method or property directly through the imported class.
I just feel like I'm missing something really obvious here. I'm basically looking for confirmation if these are the correct ways to reference the parent, and if so which is the most ideal, or am... | [
0.16025260090827942,
-0.105911485850811,
-0.1642303466796875,
0.36988168954849243,
-0.09466835111379623,
0.08711811155080795,
-0.019133001565933228,
0.031877875328063965,
0.16955985128879547,
-0.7982757687568665,
0.31166544556617737,
0.4758669137954712,
0.07773808389902115,
0.4934555590152... | |
I think it's definitely better to pass in whatever the class may need and then inside the class it doesn't have to do any parent.parent etc anymore.
With this if you in the future want to change the structure, it's very easy to just pass in a new reference; the implementation of the child class doesn't have to change ... | [
0.0804964154958725,
-0.17880114912986755,
-0.20671799778938293,
0.4132702946662903,
-0.2277749478816986,
-0.09381622076034546,
0.34911227226257324,
0.17286935448646545,
-0.3271549642086029,
-0.5333318114280701,
0.23756420612335205,
0.23737527430057526,
-0.07658208161592484,
0.3261791467666... | |
Silverlight v2.0 is getting closer and closer to RTM but I have yet to hear any stats as to how many browsers are running Silverlight. If I ask Adobe (by googling "Flash install base") they're [only too happy to tell me](http://www.adobe.com/products/player_census/flashplayer/version_penetration.html) that 97.7% of bro... | [
0.6547300815582275,
0.2833016812801361,
0.3856210708618164,
-0.04668166860938072,
-0.26441386342048645,
-0.3485264778137207,
0.18995265662670135,
0.31139782071113586,
-0.4281029999256134,
-0.4575108587741852,
0.1435394585132599,
0.6445106863975525,
-0.1360761672258377,
0.03348350524902344,... | |
me your stats!
Quick Answer: [www.riastats.com](http://www.riastats.com)
This site compares the different RIA plugins using graphical charts and graphs.
It gets its data from small snippets of javascripts running on sites accross the web (approx 400,000 last time I looked)
At the time of this post, Silverlight 2 was... | [
0.5878089666366577,
-0.08462593704462051,
0.39867135882377625,
0.2986944019794464,
-0.4138353168964386,
-0.03046581521630287,
0.33749353885650635,
0.0046246955171227455,
-0.23404262959957123,
-0.5147134065628052,
0.1327635645866394,
0.19735769927501678,
0.27011826634407043,
0.1627061516046... | |
How much traffic can one web server handle? What's the best way to see if we're beyond that?
I have an ASP.Net application that has a couple hundred users. Aspects of it are fairly processor intensive, but thus far we have done fine with only one server to run both SqlServer and the site. It's running Windows Server 2... | [
0.11001522839069366,
0.19527247548103333,
0.5513153076171875,
-0.01929924264550209,
-0.16296115517616272,
0.03068614937365055,
0.17572693526744843,
0.008728861808776855,
-0.5136665105819702,
-0.4857253134250641,
0.34254902601242065,
0.487419456243515,
-0.10804131627082825,
-0.0083796586841... | |
to do something to fix the application (I don't really want to spend a lot of time hunting down little optimizations if I'm just expecting too much from the box).
What you need is some info on [Capacity Planning](http://msdn.microsoft.com/en-us/library/ms979198.aspx)..
Capacity planning is the process of planning for ... | [
0.22226013243198395,
-0.06150855869054794,
0.19361484050750732,
0.2526482045650482,
0.27759474515914917,
0.08857802301645279,
0.3013983368873596,
0.014524778351187706,
-0.4609992504119873,
-0.48776471614837646,
-0.15155377984046936,
0.4641583263874054,
-0.1874246597290039,
-0.1316097229719... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.