Solving tech problems

Wimbledon final and soft drink ads

Leisure and Pleasure, Thoughts

Watching right now Wimbledon men’s final between Novak Djokovic and Roger Federer (btw, hoping that Djokovic will win it). Almost every ad between games and sets are from producers of soft drinks (Nestea, Coca-Cola, Schweppes) and energy drinks (unknown RedBull competition). They are promising fun, health life, enjoyment and similar crap. If I can give you some advice in this area I can tell you just don’t buy anything like this. Think logically… If they have so much money to spend on advertisement in prime time of biggest sport events…read more

Problems with Map Network Drive in Windows Server 2008R2

System Administration

To list all network shares use this command from Command Prompt: net use To delete specific network share net use /delete \\SERVER_IP\YOUR_SHARE If you map “\\SERVER_IP\SHARE1” as drive letter X using “user1” and “password1”, then try to map “\\SERVER_IP\SHARE2” (a different share) as drive letter Y using the same “user1” and “password1”, and you click the “connect using different credentials” checkbox in the Map Network Drive dialog box and specify “user1” and “password1”, you will get this INCORRECT ERROR MESSAGE that says “The network folder specified is currently mapped using…read more

Stop automatic rebooting of Windows 7 after Windows Update

System Administration

If you want your PC with Windows 7 operating system to work as server then you definitely want to stop automatic rebooting after Windows Update install new patches. To do this you need to do the following: Open the Registry Edit (WindowsKey + R, “regedit.exe“) (Remember to be careful! DON’T change anything unless you know exactly what you’re doing!) Navigate to HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU Chances are that you’ll be missing these keys. If keys WindowsUpdate\AU exist, go ahead to step 3 OTHERWISE, continue through these indented steps… Navigate to HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows (Make sure…read more

How do you copy entire MongoDB database?

Databases

I faced small problem how to duplicate entire MongoDB database and I tried just to rename folder under data directory. So, instead of having my_database I just renamed it to my_new_database but it didn’t helped and when I used show collections it returned me an empty set. I also tried to rename files inside data/my_database to my_new_database but this didn’t helped me either. So, I finally looked into the documentation and found this command which copies the entire database:

How to submit form in jQueryMobile?

Programming

jQuery Mobile is excellent framework and I was trying to figure out why postback of my web form is not working properly and I finally found out that jQuery Mobile use ajax in passing forms so you need to add parameter data-ajax=”false”. It is better to read documentation sometimes.

Using SQL Server PIVOT feature to transform rows into columns

Databases, Programming

PIVOT queries in SQL Server are useful when we need to transform data from row-level to column-level. Example: Imagine having the table named Invoice (payments per month) – for simplicity let’s say that we have PaidDate and Amount. What we wanted now is to get total money collected from the beginning of the year 2014, and in order to do this we can use this PIVOT query: And we finally get

How to get TimeZone by RemoteIP or for specific city

Programming

The goal: to find out the TimeZone of a visitor. There are few free services that can give you this information. First step is to get the City name by RemoteIP address – there are free services/databases that helps you to achieve this, one of them is MaxMind. When you have a city name you can get its latitude/longitude from the database of the same service or you can use Google API like this: For Berlin, Germany: https://maps.googleapis.com/maps/api/geocode/json?address=Berlin&sensor=false You will get JSON result like this: After getting latitude and longitude…read more

Whom to blame for the poor sale?

Learning

There aren’t many doubts. It is always the Salesman and there are three reasons for the poor sale: Salesman didn’t choose the right customer or the right decision maker in the company This means that your product is maybe ideal fit for certain customers but the customer your salesman is talking to is not in this group. Also, if the customer says “we will think about it” it means that he already know from the beginning of the year where he will spend his budget and your product in not…read more

MS SQL Server 2014 “Hybrid” to attack MongoDB

Databases

On April 1st 2014 MS SQL Server 2014 is internally released for small group of big customers such as bwin and others. The biggest improvement is in-memory OLTP engine to deliver breakthrough performance to their mission critical applications. Company bwin scale its applications to 250K requests a second, a 16x increase from before, and provide an overall faster and smoother customer playing experience. The new In-Memory OLTP engine (formerly code named Hekaton), provides significantly improved OLTP performance by moving selected tables and stored procedures into memory. Hekaton enables you to use both…read more