1. Jeff Henninger
  2. SnapDevelop
  3. Thursday, 18 March 2021 20:56 PM UTC

Hello,

I'm attempting to follow the instructions at https://docs.appeon.com/snapdevelop2019/Create_a_Web_API/index.html, but I'm running into an error when I attempt to Add -> New Item -> DataContext. After selecting my Server name, the, "Connect to database" only shows databases in the System Databases area (see screenshot attached). If I put in the AdventureWorks2012 database name I receive a, "Cannot open database..." error.

What am I doing wrong?

Attachments (1)
Armeen Mazda @Appeon Accepted Answer Pending Moderation
  1. Thursday, 18 March 2021 21:52 PM UTC
  2. SnapDevelop
  3. # 1

What version of SnapDevelop are you using?  2019?  2019 R2?  or 2019 R3?

Comment
There are no comments made yet.
Miguel Leeuwe Accepted Answer Pending Moderation
  1. Thursday, 18 March 2021 21:58 PM UTC
  2. SnapDevelop
  3. # 2

If I remember well, there's a setting on the database that allows you to connect remotely. Make sure that it's set.

Can you connect using MS Management Studio?

Comment
There are no comments made yet.
Jeff Henninger Accepted Answer Pending Moderation
  1. Friday, 19 March 2021 12:06 PM UTC
  2. SnapDevelop
  3. # 3

Miguel,

I checked the setting on the server and, "Allow remote connections to this server" is checked on.

Comment
There are no comments made yet.
Jeff Henninger Accepted Answer Pending Moderation
  1. Friday, 19 March 2021 12:07 PM UTC
  2. SnapDevelop
  3. # 4

Armeen,

I'm using SnapDevelop 2019 R3.

Comment
  1. Armeen Mazda @Appeon
  2. Friday, 19 March 2021 14:23 PM UTC
Then you are reading the wrong doc. Here is the 2019 R3 version: https://docs.appeon.com/snapdevelop2019r3/Create_a_Web_API/index.html
  1. Helpful
There are no comments made yet.
Miguel Leeuwe Accepted Answer Pending Moderation
  1. Friday, 19 March 2021 13:36 PM UTC
  2. SnapDevelop
  3. # 5

I remember I also struggled with connecting to Adventureworks:

 

The key was in the "servername" field. I have SQLSERVER Express edition installed locally and my computername is WIN8DEV2: What works for me is "WIN8DEV2\SQLEXPRESS", but also "WIN8DEV2". I'm not using "windows authentication", maybe you could try using sqlserver authentication?

Comment
There are no comments made yet.
Miguel Leeuwe Accepted Answer Pending Moderation
  1. Friday, 19 March 2021 13:38 PM UTC
  2. SnapDevelop
  3. # 6

Also make sure this service is running:

Comment
There are no comments made yet.
Miguel Leeuwe Accepted Answer Pending Moderation
  1. Friday, 19 March 2021 13:45 PM UTC
  2. SnapDevelop
  3. # 7

Also make sure your database is "online" using sqlserver management studio:

 

 

Comment
There are no comments made yet.
  • Page :
  • 1


There are no replies made for this question yet.
However, you are not allowed to reply to this question.