There is no exact equivalent in traditional SQL. As others have pointed out, you can check exists and then insert, but that introduces a race condition; wrapping it in an explicit transaction might help depending on the locking model, but might still introduce failures that have to be introduced by client code.
That said, if you can make some assumptions about what else is writing to the table then you can get fairly close. One technique I often use is like this:
-- Insert the row if none with the same PK exists. -- As a single SQL statement, this executes atomically -- in all but the most braindead DBMSes. -- insert into mytable (keycol, datacol) select 1, 'a' where not exists ( select 0 from mytable where keycol = 1 )
-- OK, now there is definitely a row there with keycol=1. -- Update the row which exists. -- This is redundant work if we just inserted it above, but do it anyway. -- update mytable set datacol = 'a' where keycol = 1
This is clearly not safe in general. If there are others accessing the table and doing general delete, or test-and-set, it can lose data. However, if you know that code like the above is the only code accessing the table, or if you restrict it to the above plus simple inserts, then you have a safe way to insert-or-update a row that doesn't involve holding locks for a period of time and doesn't require an explicit transaction.
Back in the day The Phantom Edit took out a lot of the crud (Jar-Jar, etc) from Star Wars Episode 1 and made a shorter, more watchable film. Is there a decent fan re-edit of the Hobbit trilogy into one fast-paced two-hour movie?
It depends on the monitor. Some will let you run at a resolution of exactly half and scale crisply, so that each pixel from the computer becomes a neat square of four pixels on the monitor. Sadly there are too many monitors which generate a blurry mess even when doing an exact integer scaling like this. (From my limited experience older monitors are better than newer in this respect.) Scaling in the video hardware is the same. It's from a misapplied idea that fancy scaling like bicubic is superior to the naive nearest-neighbour. That is true for photographs, but not for input images which are intended to have exact pixel boundaries.
My first resort would be to set a font scaling of 200% in the operating system. If running Windows it may help to turn off Aero, so that (as above) you get clean pixel scaling and not blurring.
This was for running ssh on a 16MHz 386SX back in the day... it really was limited by encryption speed and not the buffer size issues which openssh-hpn fixes.
Perhaps the input images they used were also low-res? If they had used higher resolution photos it would have taken much more computing time to run them through the neural network for hundreds of iterations.
I guess the same neural networks could also enhance the resolution of the images by being fed a scaled-up version and outputting it with more (imagined) detail.
In my experience 200% font scaling has worked fine since Windows XP. There are very few apps which don't handle it right - although a few things such as the command prompt remain unscaled. It probably helps to turn off the Aero crap though.
I use a couple of 24" 4k monitors. Just set 200% font scaling and you have things appearing the same size by default as they would on a 1920x1080 monitor with normal font scaling. But they look much better rendered, and if you want you can zoom out to smaller text sizes while remaining legible.
Sadly this snippet does not work in recent perl versions (I tried 5.18). 'each window' for example now needs to be 'each %window' since hashes must always have the % prefix. (In ancient perl versions the % was added implicitly if not given)
Can't you just copy in the minesweeper.exe file from an older Windows version and run it? Who knows, if you do an upgrade from 7 to 10 it most likely will be still there.
Acorn's PC emulator emulated an 8086 (not 80186). There are a couple of extra instructions added in the later 80186. Not much software uses them but apparently the game Star Trek 25th Anniversary did.
Dave Lawrence's FasterPC emulator provided a virtual 80186 (though the CPU emulation was still just as slow, the video support was faster and PC speaker emulation much better, so it could play many DOS games that used 320x200 res in 256 colours. Like Civilization...)
The PC-XT keyboard has excellent keyswitches but a lousy layout. The PC-AT keyboard is much better; the 122-key Model F terminal keyboard is the most modern layout you can get with capacitive buckling spring.
I've done that - put black M13 caps on an F122 - but what do you do about the Enter key on the numeric keypad? The F has a stabilizer wire which the M lacks, so if you put the black key on as-is it sits limply and doesn't click properly.
Similarly, the spacebar stabilizer wire is different - how do you get the black spacebar to attach properly?
I see that whoever did that mod changed the F to ANSI layout. I kept mine as ISO but that meant I had to stay with a few non-black keys.
Older Model M keyboards have a detachable cable. You can buy a replacement cable with USB adaptor built in, effectively turning it into a USB keyboard. For those with fixed cable, yes, the 'blue cube' adaptor works, or there are ones sold based on "Soarer's converter".
The IBM T220 was launched in 2001 and has a resolution of 3840x2400, slightly more than 4k. Even back then, processing power wasn't really an issue, but getting enough display bandwidth was (four separate DVI cables were needed to get the full refresh rate of 41Hz).
Others have mentioned Topre keyboards; you might also like to look at Mattias quiet keyboards. But really if you are happy with the Logitech G15 then there is no need to change away from rubber domes - keyfeel is entirely a matter of personal preference.
The real competition (in features, that is, not price) for an Apple tablet would be the Panasonic Toughpad 4k, a monster 20-inch tablet with 3840x2560 resolution (that is, 4:3 aspect ratio). It's a beautiful piece of kit but hugely expensive. Apple could put the same panel in a 20 inch "iPad Pro" or "MacPad" and if priced more keenly it could sell well among those doing graphics work who want something more portable than a desktop.
You're right that Dell laptops are relatively easy to modify and upgrade - for a laptop. But still you can't expect to transplant a motherboard into any but the most closely related model. I upgraded my old M90 to an M6300 by replacing the motherboard, CPU and memory. For the M6400, I believe that the motherboard and case from the M6500 should be compatible (provided you change the CPU and CPU heatsink) but I cannot be entirely sure.
The newer 17 inch Dell models have 1920x1080 screens instead of 1920x1200. You couldn't jam the older screen into them because it is physically a different size, even if the connector turns out to be the same.
That said, if you can make some assumptions about what else is writing to the table then you can get fairly close. One technique I often use is like this:
This is clearly not safe in general. If there are others accessing the table and doing general delete, or test-and-set, it can lose data. However, if you know that code like the above is the only code accessing the table, or if you restrict it to the above plus simple inserts, then you have a safe way to insert-or-update a row that doesn't involve holding locks for a period of time and doesn't require an explicit transaction.
Back in the day The Phantom Edit took out a lot of the crud (Jar-Jar, etc) from Star Wars Episode 1 and made a shorter, more watchable film. Is there a decent fan re-edit of the Hobbit trilogy into one fast-paced two-hour movie?
It depends on the monitor. Some will let you run at a resolution of exactly half and scale crisply, so that each pixel from the computer becomes a neat square of four pixels on the monitor. Sadly there are too many monitors which generate a blurry mess even when doing an exact integer scaling like this. (From my limited experience older monitors are better than newer in this respect.) Scaling in the video hardware is the same. It's from a misapplied idea that fancy scaling like bicubic is superior to the naive nearest-neighbour. That is true for photographs, but not for input images which are intended to have exact pixel boundaries. My first resort would be to set a font scaling of 200% in the operating system. If running Windows it may help to turn off Aero, so that (as above) you get clean pixel scaling and not blurring.
This was for running ssh on a 16MHz 386SX back in the day... it really was limited by encryption speed and not the buffer size issues which openssh-hpn fixes.
I patched 'none' encryption into openssh many years ago: http://membled.com/work/patche...
Since you asked about Hitler and systemd.... https://www.youtube.com/watch?...
Can we stop this stupidity of writing "$50,000 dollars"? It's 50,000 dollars, or $50,000. Would you write "5kg kilograms"?
Perhaps the input images they used were also low-res? If they had used higher resolution photos it would have taken much more computing time to run them through the neural network for hundreds of iterations. I guess the same neural networks could also enhance the resolution of the images by being fed a scaled-up version and outputting it with more (imagined) detail.
In my experience 200% font scaling has worked fine since Windows XP. There are very few apps which don't handle it right - although a few things such as the command prompt remain unscaled. It probably helps to turn off the Aero crap though.
I use a couple of 24" 4k monitors. Just set 200% font scaling and you have things appearing the same size by default as they would on a 1920x1080 monitor with normal font scaling. But they look much better rendered, and if you want you can zoom out to smaller text sizes while remaining legible.
Sadly this snippet does not work in recent perl versions (I tried 5.18). 'each window' for example now needs to be 'each %window' since hashes must always have the % prefix. (In ancient perl versions the % was added implicitly if not given)
Can't you just copy in the minesweeper.exe file from an older Windows version and run it? Who knows, if you do an upgrade from 7 to 10 it most likely will be still there.
Acorn's PC emulator emulated an 8086 (not 80186). There are a couple of extra instructions added in the later 80186. Not much software uses them but apparently the game Star Trek 25th Anniversary did. Dave Lawrence's FasterPC emulator provided a virtual 80186 (though the CPU emulation was still just as slow, the video support was faster and PC speaker emulation much better, so it could play many DOS games that used 320x200 res in 256 colours. Like Civilization...)
The PC-XT keyboard has excellent keyswitches but a lousy layout. The PC-AT keyboard is much better; the 122-key Model F terminal keyboard is the most modern layout you can get with capacitive buckling spring.
I've done that - put black M13 caps on an F122 - but what do you do about the Enter key on the numeric keypad? The F has a stabilizer wire which the M lacks, so if you put the black key on as-is it sits limply and doesn't click properly. Similarly, the spacebar stabilizer wire is different - how do you get the black spacebar to attach properly? I see that whoever did that mod changed the F to ANSI layout. I kept mine as ISO but that meant I had to stay with a few non-black keys.
Older Model M keyboards have a detachable cable. You can buy a replacement cable with USB adaptor built in, effectively turning it into a USB keyboard. For those with fixed cable, yes, the 'blue cube' adaptor works, or there are ones sold based on "Soarer's converter".
So... what is it you need that Mono doesn't do?
That's true but I don't think the required CPU power scales linearly with the display size.
The IBM T220 was launched in 2001 and has a resolution of 3840x2400, slightly more than 4k. Even back then, processing power wasn't really an issue, but getting enough display bandwidth was (four separate DVI cables were needed to get the full refresh rate of 41Hz).
Others have mentioned Topre keyboards; you might also like to look at Mattias quiet keyboards. But really if you are happy with the Logitech G15 then there is no need to change away from rubber domes - keyfeel is entirely a matter of personal preference.
Panasonic is about the only major PC maker which makes Apple kit look cheap. You pay a big premium for that extra ruggedness.
The real competition (in features, that is, not price) for an Apple tablet would be the Panasonic Toughpad 4k, a monster 20-inch tablet with 3840x2560 resolution (that is, 4:3 aspect ratio). It's a beautiful piece of kit but hugely expensive. Apple could put the same panel in a 20 inch "iPad Pro" or "MacPad" and if priced more keenly it could sell well among those doing graphics work who want something more portable than a desktop.
How do these banknotes fit into the rules of Rock Paper Scissors Spock Lizard?
You're right that Dell laptops are relatively easy to modify and upgrade - for a laptop. But still you can't expect to transplant a motherboard into any but the most closely related model. I upgraded my old M90 to an M6300 by replacing the motherboard, CPU and memory. For the M6400, I believe that the motherboard and case from the M6500 should be compatible (provided you change the CPU and CPU heatsink) but I cannot be entirely sure. The newer 17 inch Dell models have 1920x1080 screens instead of 1920x1200. You couldn't jam the older screen into them because it is physically a different size, even if the connector turns out to be the same.
I wonder whether installing Classic Shell would help users who are used to Windows XP and earlier versions.