Question asked by Pramod on my old Forum.
I have decided to do away with my forum plugin, and instead have added the Ask a question/Contact Me page. All forum posts have been added as regular posts, with “Question:” at the start of the post title.
The example query below creates a product category table and populates it with sample data. I then use a CTE query to return the categories, along with the breadcrumb trail (lineage)
The script in this post can be used to obtain an example of each of the different styles that can be output using the CONVERT Transact-SQL statement when converting date/time to a string. I have output the styles including the century, but the script can easily be modified to output examples without.
If you need to analyse the number of email addresses by email domain, e.g. “@abc.com”, then the script within this post will return the number of records grouped by the domain name of each email address (i.e. to the right of the @ sign)
I needed to remove carriage returns, line feeds and tab characters from an Excel spreadsheet that was copied straight out of Microsoft Access, and have written a script that performs the replace. Just change the option accordingly, and run 🙂
Script that can placed in an Informer calculated column, to return the month and year concatenated into a string, in the format “mm/yyyy”.
Informer script to be placed in a calculated column, to return a URL pointing to the detail of a record.
This will depend very much on the source system of the data in Informer, as a URL may not always be relevant (or possible)
Informer script (to be placed in a calculated column) that can replace pipe (“|”) characters so they do not affect exported results.
Back in June 2014, I discovered a SQL Server Agent job that was failing with the error “Non-SysAdmins have been denied permission to run DTS Execution job steps without a proxy account. The step failed”. It turns out that the person who set up the job did not have sysadmin rights. I changed the owner of the job to a sysadmin user, and now it works 🙂
The script within this post, outputs a list of each DATETIME and SMALLDATETIME field within a database, along with the minimum and maximum values. Useful to identify tables that have a date created or updated column, and you want to find out if they are still being used.
Do you have any spurious characters in a field??
Well, the code within this post, can be used to obtain a list of the ASCII character codes for each individual character of a field