SQL Server Example

Sep 12 at 6:15 PM
Edited Sep 13 at 6:52 PM
May I get an SQL Server CRUD full example ? Thanks.


I downloaded source from here

https://orm.svn.codeplex.com/svn/

Getting "Object reference not set to an instance of an object." error here on file SqlServerDataStore.cs


public override bool StoreExists
    {
        get
        {
            var masterInfo = (SqlConnectionInfo)m_info.Clone();   <===== error here
            masterInfo.DatabaseName = "master";

            var masterConnectionString = BuildConnectionString(masterInfo);

            var sql = string.Format("SELECT COUNT(*) FROM sys.databases WHERE Name = '{0}'", m_info.DatabaseName);


EDIT: Never mind, found the issue. I have to use a SqlConnectionInfo and use a SQL login, seems that the trusted connection doesn't work. The m_info is not filled if you use a string connection (weird )