Skip to content

Instantly share code, notes, and snippets.

@doc-E-brown
Created September 25, 2019 06:52
Show Gist options
  • Save doc-E-brown/0c4a7ca89905bd06f24a5c895829624a to your computer and use it in GitHub Desktop.
Save doc-E-brown/0c4a7ca89905bd06f24a5c895829624a to your computer and use it in GitHub Desktop.
C# program to create ris database
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Data.SqlClient;
namespace CreateRisDb
{
class Program
{
static void Main(string[] args)
{
String computer_name = ""; // Fill this string with your computer name
SqlConnection myConn = new SqlConnection("Data Source=" + computer_name + "\\SQLEXPRESS;Integrated Security = true");
myCommand = new SqlCommand("CREATE DATABASE ris", myConn);
myConn.Open();
myCommand.ExecuteNonQuery();
myConn.Close();
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment