Not a long post but very handy query that can be used when you need to know the installed SQL Server product's version, edition, flavour, server name details. SQL Query to get version details for installed Microsoft SQL Server: SELECT SERVERPROPERTY('productversion') AS 'Product Version', SERVERPROPERTY ('productlevel') AS 'Product Level', SERVERPROPERTY ('edition') AS 'Product Edition', @@SERVERNAME AS 'Server Name', SUBSTRING(@@VERSION, 1, CHARINDEX('-', @@VERSION) - 1) + CONVERT(VARCHAR(100), SERVERPROPERTY('edition')) + ' ' + CONVERT(VARCHAR(100), SERVERPROPERTY('productlevel')) AS 'Server Version'; Following query shows below output on my test machine: Happy coding !! » Read more
I was recently working with a sidekick thing where I was using MySQL as my backend database. This was accessed from the application with hostname - localhost and username dev. I had created one view and was using it in the thing I was working on. It was originally scripted like this: CREATE DEFINER = 'dev'@'localhost' VIEW somedatabase.somerandomviewname AS SELECT `sd`.`somerandomcolumnone` as `ColOne`, `sd`.`somerandomcolumntwo` as `ColTwo` FROM `someshitytable` `sd` WHERE sd.blahblah IS NOT NULL; One day I realized that my workstation is going crazy over few tools I use everyday. I could have repaired or fixed or reinstalled them but then I choosed to do a full cleanup and start fresh (for no particular reason). So I used MySQL dump backup feature from maintanance and created backup scripts for that database, which also contains the creation script for this view obviously. Once my machine was ready » Read more
This steps will guide you to install SQL Server 2012 Express edition, code name “Denali”. The express edition is free version of SQL Server 2012 and is available for download from Microsoft site. Download the installer and run. Step 1: The installer will create a temporary folder in your C drive to extract the files required by the installation. Step 2: Once the extraction is completed, you will be presented with this welcome page. On left hand side of the application contains different tab links to choose your desired installation required. When you click on the “Options” tab link you will be able to see where the installer is located and what version x86 / x64 it is currently going to install. As we are installing the SQL Server 2012 fresh, click on “New SQL Server stand-alone installation and add features to an existing installation”, this will start configuring the process » Read more