add ping() for mysql, mysqli and pdo to ensure db connection available while doing query

[*]  Project : add ping() for mysql, mysqli and pdo to ensure db connection available while doing query