SQL Basics

Today, I am writing this blog because I did not have a chance to conduct the SQL training with the support team yesterday before I departed for a new adventure; I feel like I owe it to them to give them something. This is part one of the training session. This part is about SQL basics. Part two is about using patterns to gain efficiencies in your day-to-day work. Let’s start with part one: SQL Basics.

Continue reading SQL Basics

How to use SQL to Extract a Number from a String

Recently I had a need to extract the number from a string in the database.  The string would be something like ‘Monitor 16″‘ or “16 inch Monitor”.   I would need to get the size for various reasons including fees and reports, but no real good way of doing it.  I have come up with the following Scalar SQL Function to do this very job.

Continue reading How to use SQL to Extract a Number from a String

SQL Function – Find a Value in a String of Values

In a table I have a field that you can use comma delimited value (example 1,2,3,22). When I tried to filtering use a “LIKE” statement on the value 2, I was being returned 2 and 22. ARG!

So what do you do? You create a simple function the returns a 1 or 0. 1 being successfully found and a 0 meaning failed to find. Seems simple enough? Well it was and the function can be easily tweaked to match the solution you need! Here is the function as I used it:
Continue reading SQL Function – Find a Value in a String of Values

MaxMind GEOIP Look-up for Microsoft SQL

Recently I implemented a GEOIP solution on a client site; however, the site was built on a Microsoft SQL database engine and I could not find a solution for looking up the country name easily.  Through some quick Google searches I had tripped on the site for which I started at ( http://dev.maxmind.com/geoip/csv ).  The site maxmind.com gave me the MySQL solution and the mathematical solution for creating the integer.  Based on this information, I created my own function in MS SQL to retrieve me the calculated IP integer for easier use.

Continue reading MaxMind GEOIP Look-up for Microsoft SQL

Do Not Get Boxed

As a developer, it is important to look around and experience new things, as it helps you to stay sharp and marketable. This doesn’t mean that you need to quit your job.  Just do not get boxed in as single purpose developer.

It is important not to be just a developer of one kind. Do not just be a PHP Developer, DotNet Developer, or a SQL Developer. Strive to be more than what you are currently doing.

As an example; when I was just starting out as a developer I had two unique jobs. First job was a Visual COBOL Developer and the second job was a Factory Automation Integrator specializing in database and Visual Basic integrations to Allen-Bradley PLC. If I had allowed myself to be boxed into either one of these developer types, I would not have had the opportunities to do more. With the Factory Automation Integrator, I would probably be pumping gas as the firms I used to work for and see around are mostly gone now and who the heck is using Visual COBOL anymore?

As a Web Developer working for a web development firm, you may be asked by a customer to do a mobile application or a windows application to complement their other work you may have done.

I strive every day to learn something new. I learn it until I know it well enough to be productive. I also practice what I have learned in the projects I work on in my spare time. .

In my current job I am a Web Developer, SQL Developer, Windows Developer, Mobile Developer and a Support Specialist.  I have also worked where I had a single focus as a Web Developer at a web development firm, but I stretched myself to do business needs analysis. It is important to be forever evolving as a developer. Just don’t speak of the new technologies. Learn the new technologies and know and practice what have you have learned.