In Business Application Studio , Can't see tables in Connection Explorer - get "Nothing here" - sqlite

-> In Business Application Studio, I have created a table orders in datamodel.cds file under db folder.
-> In Connection explorer, I have make a new connection and it's created successfully but my table is showing nothing.
Expecting : In Connection Explorer, orders table should come.

Related

Deploy existing data on ASP.NET web project from local database in Visual Studio to Azure database

I've successfully deployed my ASP.NET project to Azure but the database has been deployed with no data, consequently throwing internal server errors due to functionality requiring that data. I can't see the exact error message as I'm unable to disable customErrors on my project (there's no webconfig file on Razor Pages)
I need to update my database on Azure with the data currently stored locally. How do you do this and is this possible?
N.B - I am using EF core with code-first migrations for data access
On the local machine open the "Microsoft server SQL management studio", connect to the local database server and navigate to the appropriate database. Rightclick on the database name and select "Generate scripts...". Select the tables you want to export, then click "next>". On this screen click the "Advanced" button, scroll down to "Types of data to script" and select "Data only". Now you can generate the script and copy that to a connection to the Azure DB, that can be an other query in de Management Studio or in the Azure portal.

Where is the Azure Web App database?

I been following a Microsoft tutorial on Azure Web Apps:
https://azure.microsoft.com/en-us/documentation/articles/web-sites-dotnet-deploy-aspnet-webforms-app-membership-oauth-sql-database/
I created a Web App on Azure then created the website in VS 2013 on my PC with authentication all working. I then tried to publish the website onto Azure. When I go through the publishing steps, I do not get a connection string. I have tried waiting (24 hours) and looked around the app to see if there are any settings, but I cannot find a way to get a connections string. Everything other than the login-in works.
I know I selected a free 20Mb database, but I cannot see any sign of one on the Azure portal. I created a second Azure Web app and it is exactly the same.
Where would I find the Azure app database (in the Azure Portal) used for storing the username & password? Any idea how I can get the login to work in the Azure cloud?
So long you shouldn't have to wait. I just tried it and had the free DB after two minutes.
You find all SQL Server databases incl. the free one in the SQL Server section. That's the icon on the left with the container and the "DB" in front. There you should find your new database. Click on it, switch to the dashboard and on the right you find the section "quick glance". Click on the link "Show connection string" and copy from there what you need.
Btw, you should not be able to create a second free SQL DB. If you're allowed to create "second" free SQL DB, than there is no first one. That would definitely mean there went something wrong in the first place.
While creating the website you would have specified the database server, db name etc. Under the sql db section this db will be listed. If you have done that way. then migrate the db that you have locally to azure using the migration wizard and then provide that azure sql db connection string in the web.config ( from where the connectionstring is used.) then the application should work fine.

Having trouble linking to my Azure DB

I'm publishing an ASP.NET MVC 5 app to Azure Websites. In my Azure portal, I linked the website to my Azure SQL database. However, when I click the "View Connection String" link on the portal, I get a popup that says there are no connection strings.
Please keep in mind that my connection string in my app have a different name i.e. it's not named DefaultConnection, rather it's named myAppNameConnection.
Also, I'm publishing the app directly from VS 2013 and I'm able to select the correct DB in the publish wizard. However, when the app is published it is NOT able to communicate with the database. Any idea what may be causing this issue?
In your VS tool you have the right connection string configured in your Web.config file.
When you publish the website in Azure, it overwrites automatically the connection strings in the web.config file with the ones stored as global variables in the website service.
You must go on the Azure portal, click on your website, then click on configure on the tab menu.
Go down to connection strings, and insert the right connection string there.

Visual Studio error when trying to find my database

I am a student learning asp.net and I ran into a problem when trying to reconfigure data sources I created. When I run my web application I am able to edit/add/delete entries that are in my database but when I try to create or reconfigure a datasource it gives me this message:
Database schema could not be retrieved for this connection. Please
make sure the connection settings are correct and that the database is
online.
Could not load file or assembly
‘Microsoft.SqlServer.Management.Sdk.Sfc, Version=10.0.0.0, Culture=
neutral, PublicKey Token=89845dcd8080cc91’ or one of its
dependencies. The system cannot find the file specified.
Now I never changed the place of the database on my computer and I have never deleted it from the originating folder. I went into my 'Sever Explorer' tab and it shows that the database is connected. I right clicked on my database in the data connections list and went to 'Modify Connection...' and ran the 'Test Connection' option and it says the "Test connection succeeded". If my application can edit the database why can't Microsoft Visual Studio find the connection to let me edit the datasource?
As the error indicated that the problem was the system cannot locate the right assembly (SQL Server SDK).
I suspect that the installation of your SQL Server is not a complete or a successful one, or you should have to download some components to provide a successful connection.
Useful links with components that you would consider downloading here or here

Copy table from one data connection and paste into database in another data connection in visual studio

This may be super obvious, but I can't see it. I have a table I created in SQL Server Management Studio. I had to create it there because I needed to use a function for an alpha-numeric ID column that increments itself. I then exported the table, but had to use my local server. Now, in visual studio, I have the local server connection that contains the table I want to copy to a connection for a remote server. I can right-click and select 'Copy', but I can't right-click and 'Paste' into the database I need.
I'm fairly new at this and if anyone has a better way to make an auto incrementing alpha-numeric column in Visual Studio, I would love to hear about it.
Thanks
I would go back into SQL Server Management Studio, connect to the remote server, and create the table there. This would also show you any possible permissions issues that you may have on the remote server.
You will need to update your app.config file in your VB Project.
You can right click on the project and click properties
Under 'Settings' you will find a 'Connection' with a 'Name' and a 'Value'
You need to change the value for 'Connection Properties' for:
Server Name: from LOCALHOST to your remote server url
Also be sure to update username/password credentials
Click 'Test Connection' to confirm you can connect
You can also manually edit these settings in the app.config file
You can also manually edit the MyApp.exe.config file where your app is deployed (where MyApp is the executable name)

Resources