There is a neglected major bug in ML.NET that Microsoft STILL HASN'T fixed.. They must have laid off the wrong team member, and nobody there knows how to fix it, because it is prominent and vexing.
The bug is ML.NET won't connect to SQLServer correctly. Some have gotten it to work but many can't.
After much fidgeting, I was able to get ML.NET to load data from SQLExpress installed on the same PC. (Note, I still can't get it to work with a normal instance on a different PC, but this is a good start until Microsoft figures out AI can't do everything yet in the programming dept. and rehires the right dude back who can fix the problem.)
Here's what I did:
-
-
When installing, select "Mixed Mode Authentication" and "Encryption optional"
-
Install SQL Management Studio 2022 (this will install as part of the above install package)
-
Open Mgmt Studio and create your new Database, and a new Table, and populate it
-
Open ML Studio: Under Data, click [Change Data Source...]
-
Select <other...>, and click [Continue]
-
You now should see ".NET Framework Data Provider for SQL Server" appear in the top "Data source" field
-
For Server name, you must type /[YOUR SERVER NAME HERE]/SQLExpress
-
Note: ^ The above does not auto-populate even though it should
-
Authentication: "Windows Authentication"
-
Encrypt: "Optional (false)"
-
Now, the "Select or enter a database name" field will auto-populate Database names. Pick yours.
-
Test Connection. It should be successful.
-
You can now load the table in ML.NET Data