SQL and MySQL Snippets

MS SQL Return record count with leading zeros

Published Jan 05, 2012
First I set the column of REC to a datatype of bigint . Then i run this query to do a count...

Meditech DR Core SQL Tables

Published Jan 05, 2012
Core Tables for Meditech Data Repository SQL database. */ Module TableName ABS...

MS SQL Query for Meditech Data Repository DR GL Account Summary

Published Jan 05, 2012
use MYDATABASE Select * from GlAccountAmounts GAA INNER JOIN DMisGlAccount GA on GAA.AccountID...

MSSQL queries from database creation to queries and stored procedures.

Published Jan 05, 2012
create database MYDATABASE on (name=MYDATABASE, filename='c:\CCTB111\MYDATABASE.mdf', size=1mb...

MS SQL query for searching in column names.

Published Jan 05, 2012
Search column names for keywords using "like" SELECT name FROM sysobjects WHERE id IN (...

MS SQL Query to return information about database details.

Published Jan 05, 2012
Microsoft SQL query to return all tables, row counts, column counts, and size of tables. USE...

MySQL select using multiple "like"

Published Dec 28, 2011
Scenario Version: MySQL 5.0 Database Name: testdb Table Name: domains Field Name: domainame...

MySQL select using multiple "NOT LIKE"

Published Dec 28, 2011
Scenario Version: MySQL 5.0 Database Name: testdb Table Name: domains Field Name: domainame...

Simple MYSQL Select Queries

Published Dec 28, 2011
Version: MySQL 5.0 Database Name: testdb Table Name: domains Field Name: domainame Simple...