{"action":"created","issue":{"url":"https://api.github.com/repos/aspnet/Microsoft.Data.Sqlite/issues/485","repository_url":"https://api.github.com/repos/aspnet/Microsoft.Data.Sqlite","labels_url":"https://api.github.com/repos/aspnet/Microsoft.Data.Sqlite/issues/485/labels{/name}","comments_url":"https://api.github.com/repos/aspnet/Microsoft.Data.Sqlite/issues/485/comments","events_url":"https://api.github.com/repos/aspnet/Microsoft.Data.Sqlite/issues/485/events","html_url":"https://github.com/aspnet/Microsoft.Data.Sqlite/issues/485","id":298089436,"number":485,"title":"Use with PowerShell 6.0.1","user":{"login":"elijahgagne","id":2213005,"avatar_url":"https://avatars3.githubusercontent.com/u/2213005?v=4","gravatar_id":"","url":"https://api.github.com/users/elijahgagne","html_url":"https://github.com/elijahgagne","followers_url":"https://api.github.com/users/elijahgagne/followers","following_url":"https://api.github.com/users/elijahgagne/following{/other_user}","gists_url":"https://api.github.com/users/elijahgagne/gists{/gist_id}","starred_url":"https://api.github.com/users/elijahgagne/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/elijahgagne/subscriptions","organizations_url":"https://api.github.com/users/elijahgagne/orgs","repos_url":"https://api.github.com/users/elijahgagne/repos","events_url":"https://api.github.com/users/elijahgagne/events{/privacy}","received_events_url":"https://api.github.com/users/elijahgagne/received_events","type":"User","site_admin":false},"labels":[{"id":404517640,"url":"https://api.github.com/repos/aspnet/Microsoft.Data.Sqlite/labels/closed-question","name":"closed-question","color":"777777","default":false}],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":22,"created_at":"2018-02-18T14:38:14Z","updated_at":"2018-02-21T07:09:11Z","closed_at":"2018-02-20T18:39:10Z","author_association":"NONE","body":"I am trying to use this library with PowerShell 6.0.1 on Windows 10. I originally opened https://github.com/PowerShell/PowerShell/issues/6050 to get some help and we determined that the issue would more appropriately be opened in this location. \r\n\r\nI have created a small .Net core app by doing the following.\r\n\r\n```\r\nmkdir ~\\Desktop\\test\r\ncd ~\\Desktop\\test\r\ndotnet new console\r\n\r\ndotnet add package Microsoft.Data.Sqlite.Core\r\n\r\nnotepad Program.cs\r\n```\r\n\r\nHere's what Program.cs looks like\r\n```\r\nusing System;\r\nusing Microsoft.Data.Sqlite;\r\n\r\nnamespace dotnetcore_sqlite_test\r\n{\r\n    class Program\r\n    {\r\n        static void Main(string[] args)\r\n        {\r\n            Console.WriteLine(\"Hello World!\");\r\n\r\n            var dbconn = new Microsoft.Data.Sqlite.SqliteConnection();\r\n            dbconn.ConnectionString = \"Data Source=C:\\vault.db\";\r\n\r\n            Console.ReadLine();\r\n        }\r\n    }\r\n}\r\n```\r\n\r\n\r\nI can then run and publish the app without issue\r\n```\r\ndotnet restore\r\ndotnet build\r\ndotnet run\r\ndotnet publish\r\n```\r\n\r\nMoving over to PowerShell, here is my attempt to use it there:\r\n```\r\nPowerShell v6.0.1\r\nCopyright (c) Microsoft Corporation. All rights reserved.\r\n\r\nhttps://aka.ms/pscore6-docs\r\nType 'help' to get help.\r\n\r\nPS C:\\Users\\egagn> [Reflection.Assembly]::LoadFile(\"C:\\Users\\egagn\\Desktop\\test\\bin\\Debug\\netcoreapp2.0\\publish\\Microsoft.Data.Sqlite.dll\")\r\n\r\nGAC    Version        Location\r\n---    -------        --------\r\nFalse  v4.0.30319     C:\\Users\\egagn\\Desktop\\test\\bin\\Debug\\netcoreapp2.0\\publish\\Microsoft.Data.Sqlite.dll\r\n\r\n\r\nPS C:\\Users\\egagn> [Reflection.Assembly]::LoadFile(\"C:\\Users\\egagn\\Desktop\\test\\bin\\Debug\\netcoreapp2.0\\publish\\SQLitePCLRaw.core.dll\")\r\n\r\nGAC    Version        Location\r\n---    -------        --------\r\nFalse  v4.0.30319     C:\\Users\\egagn\\Desktop\\test\\bin\\Debug\\netcoreapp2.0\\publish\\SQLitePCLRaw.core.dll\r\n\r\n\r\nPS C:\\Users\\egagn>\r\nPS C:\\Users\\egagn> $Connection = New-Object -TypeName Microsoft.Data.Sqlite.SqliteConnection\r\nPS C:\\Users\\egagn> $Connection.connectionstring = \"Data Source=C:\\vault.db\"\r\nThe following exception occurred while retrieving member \"connectionstring\": \"Could not load file or assembly 'SQLitePCLRaw.core, Version=1.0.0.0, Culture=neutral, PublicKeyToken=1488e028ca7ab535'. The system cannot find the file specified.\"\r\nAt line:1 char:1\r\n+ $Connection.connectionstring = \"Data Source=C:\\vault.db\"\r\n+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\r\n+ CategoryInfo          : NotSpecified: (:) [], ExtendedTypeSystemException\r\n+ FullyQualifiedErrorId : CatchFromBaseGetMember\r\n```\r\n\r\nThe issue seems to be that SQLitePCLRaw.core is not properly getting imported. Might you be able to help me figure out this issue?"},"comment":{"url":"https://api.github.com/repos/aspnet/Microsoft.Data.Sqlite/issues/comments/367233248","html_url":"https://github.com/aspnet/Microsoft.Data.Sqlite/issues/485#issuecomment-367233248","issue_url":"https://api.github.com/repos/aspnet/Microsoft.Data.Sqlite/issues/485","id":367233248,"user":{"login":"elijahgagne","id":2213005,"avatar_url":"https://avatars3.githubusercontent.com/u/2213005?v=4","gravatar_id":"","url":"https://api.github.com/users/elijahgagne","html_url":"https://github.com/elijahgagne","followers_url":"https://api.github.com/users/elijahgagne/followers","following_url":"https://api.github.com/users/elijahgagne/following{/other_user}","gists_url":"https://api.github.com/users/elijahgagne/gists{/gist_id}","starred_url":"https://api.github.com/users/elijahgagne/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/elijahgagne/subscriptions","organizations_url":"https://api.github.com/users/elijahgagne/orgs","repos_url":"https://api.github.com/users/elijahgagne/repos","events_url":"https://api.github.com/users/elijahgagne/events{/privacy}","received_events_url":"https://api.github.com/users/elijahgagne/received_events","type":"User","site_admin":false},"created_at":"2018-02-21T07:09:11Z","updated_at":"2018-02-21T07:09:11Z","author_association":"NONE","body":"@iSazonov Would you be willing to provide an example of how to call LoadUnmanagedDllFromPath(). I'm not easily figuring that out. "}}
{"actor":{"display_login":"elijahgagne"}}