This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public bool SqlServerIsUp() | |
{ | |
return Process.GetProcessesByName("sqlservr").Any(); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
private string GenerateAssembly(string username, string password, string _assemblyPath) | |
{ | |
var _result = ""; | |
using (var csc = new CSharpCodeProvider(new Dictionary<string, string>() { { "CompilerVersion", "v3.5" } })) | |
{ | |
var parms = new CompilerParameters(new[] { "mscorlib.dll", "System.Core.dll", "FluentMigrator.dll" }); | |
parms.GenerateExecutable = false; | |
parms.OutputAssembly = _assemblyPath; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
private string AssemblyString(string username, string password) | |
{ | |
return String.Format(@"using FluentMigrator; | |
namespace UpdatePass | |
{ | |
[Migration({2})] | |
public class Class1 : FluentMigrator.Migration | |
{ | |
public override void Down() | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
namespace ConsoleApplication6 | |
{ | |
using System; | |
class Program | |
{ | |
static void Main(string[] args) | |
{ | |
var a = new MyClass(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT cr_date,cname,pname,login,status,passwd,email FROM clients |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT mail.mail_name,domains.name,accounts.password,domains.status | |
FROM domains | |
LEFT JOIN mail ON mail.dom_id = domains.id | |
LEFT JOIN accounts ON accounts.id = mail.account_id | |
WHERE mail.mail_name <> '' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT domains.name, hosting.fp_adm, accounts.password, clients.login, | |
clients.passwd, dom_level_usrs.passwd As DomainPass, domains.status As Status | |
FROM domains | |
LEFT JOIN hosting ON hosting.dom_id = domains.id | |
LEFT JOIN sys_users ON hosting.sys_user_id = sys_users.id | |
LEFT JOIN accounts ON accounts.id = sys_users.account_id | |
LEFT JOIN clients ON clients.id = domains.cl_id | |
LEFT JOIN dom_level_usrs ON dom_level_usrs.dom_id = domains.id |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT domains.name,forwarding.redirect FROM forwarding LEFT JOIN domains ON forwarding.dom_id = domains.id |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT domains.name,data_bases.name,data_bases.type,db_users.login,db_users.passwd | |
FROM data_bases | |
LEFT JOIN domains ON domains.id = data_bases.dom_id | |
LEFT JOIN db_users ON db_users.db_id = data_bases.id |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT domains.name, ip_addresses.ip_address, certificates.name AS cert_name, certificates.ca_file | |
FROM ((domains INNER JOIN | |
hosting ON domains.id = hosting.dom_id) INNER JOIN | |
(ip_addresses INNER JOIN | |
certificates ON ip_addresses.ssl_certificate_id = certificates.id) ON hosting.ip_address_id = ip_addresses.id) | |
ORDER BY ip_addresses.ip_address |