SQLite Database not showing updates in Manager - sql

I am running a Setup where I have a SQLite DB on my Raspberry Pi and I would like to open it remotely via a Database Manager like SQLiteStudio. I have setup a samba server on my raspberry and shared the .db file. Now I want to open the file on my PC. So far I have tried it and if I open the Database I can see all the entrys, but if I change anything in the database I dont see the changes in SQLiteStudio. Even after a refresh. It works just fine if I have the file on my PC. To see the changes I made in the Database I have to delete the db from SQLiteStudio and add it again. Any clues or other Management programs that worked for you?

It is strongly recommended against using SQLite databases over samba shares. See this answer for more details: Sqlite over a network share
It is known to cause inconsistent results and issues.

Related

How to connect to a SQL Server from an m1 chip macbook

I am working on a project with a friend and he has deployed a SQL Server database. He uses a PC and can access the database using Microsoft SQL Server Management Studio (SSMS).
However I have a Macbook with an M1 chip and so I cannot use SSMS and need to figure out which SQL Server application I want.
It seems like the way to go is Microsoft Azure Data Studio. I cannot figure out how to connect properly, I have looked at several solutions posted online which all say to download docker, download the latest SQL Server image, use SQL edge, run SQL Server in a container and then open Azure and connect.
One caveat is that all these tutorials end with creating a SQL Server on the local host rather than connecting to an existing one.
In Azure, after entering server id, username and password, there is a green dot on the label of the DB on the left drop down menu, indicating that the connection to the DB was successful. However whenever I try to view the DB's from the drop down it loads and then errors:
Object Explorer task didn't complete within 45 seconds
and I cannot run any basic queries either.
At this point I don't care what IDE I use as long as it works. Any advice is much appreciated. It seems like this task should be super easy but has given me such a hard time and we cannot continue working on the project until I get access.
Anyways, thanks again in advance! and lmk if there's any other info I should provide.
Tried using docker with Azure Data Studio and my results were the same as when I only used Azure.
You'll want to use Azure Data Studio.
You don't need Docker at all to meet your goals. Those tutorials were in regards to running your own SQL Server instance on a Mac. You're trying to connect to an existing instance.
As mentioned in the comments, where is the existing SQL Server instance located?...is it on a server that's part of a domain. Is your Mac part of that same domain? It sounds like you're getting some kind of timeout issue or some sort of authentication issue. So this is more of an infrastructure question.
Once connected to the SQL Server instance in Azure Data Studio, what happens if you just open a blank worksheet and run the query SELECT ##SERVERNAME?

How to allow others to run Web App using LocalDb

I have created this assignment where I am essentially using .net Core to read and write to an instance of a SQL localDb: Github
This is my first time using a localdb, but when I submitted it to my professor, he is not able to create, or manipulate the database at all. My thoughts were that when he runs it, it would create and instance of the database on his computer, but I guess not. He gets the following error:
SqlException: Cannot open database 'Bartender_App' requested by login. The Login failed. Login failed for user "Username"
this error occurs when trying to create a new order. Is there any way to bypass this authentication? because the web app works on my computer.
would he have to create his own migrations and update the database from Visual Studios on his end?
I have tried to look it up, but come across deployment of these web apps to a server which is not what I am trying to do, I am just aiming for him to be able to run the application on his computer, even if the database starts empty, and he can manipulate, add, and remove the data from the localDb instance
I apologize in advance for the tags - the autocomplete feature was not showing up correctly.
Is there any way to bypass this authentication? because the web app
works on my computer.
This is impossible, SQL Server Express LocalDB does not accept remote connections.
As an alternative, you can automate the backup of your database structure and provide it to your instructor, you can refer to How to copy a database from one computer to another?.
If there is not much table, manual creation may be faster and easier.
More details ,have a look for Can SQL Server Express LocalDB be connected to remotely?.

Looking for a free DNN community edition website Backup and restore procedure working with DNN 7 and SQL server express 2008 r2

I am looking for a free DNN community edition website Backup and restore procedure working with DNN 7 and SQL server express 2008 r2.
I usually design and develop website in local PC as my connection speed to the actual server is low. And then I want to publish (deploy) the result in the server. I may need to repeat this procedure a few times as our website is always under development and I need to add new pages or update the existing ones.
I use DNN 7 community edition. I have already googled and have found plenty of commercial tools for this backup and restore. But the free methods seems to be 1.
old or
not working properly or
not a straight forward procedure or
very buggy.
I have gone e.g. through the 4 links given in
http://www.dnnsoftware.com/community-blog/cid/134680/HOW-TO-Move-a-DotNetNuke-installation
without any success.
Could you please help me 1.
how I could develop my website in local PC and then upload the
result in the server?
And later after adding a few new pages in the local PC how I could sync the result with the server?
Thank you very much in advance for your help and consideration.
.
.
.
"when using SQL express, if I simply copy the entire local folder to production (including the APP_DATA folder, which contains the database)." ... How I could just save the newly registered users data in the website's database before copying entire local folder to production and restore this data after copying. In other way, I want to update the page contents and added designs but I don't want to loose newly registered users data between two consecutive website updates. I hope could find a working procedure for this because working online with server is very slow due to my connection speed and I have to keep a replica of the website in the local PC and add new pages or programs in the local PC and then update the result to the server when required. The specs of two systems are as follows:
local PC: Windows 8 Pro (with admin access)
Server (VPS): Windows web server 2008 (with admin access)
1) The easiest way to do this, when using SQL express, is to simply copy the entire local folder to production (including the APP_DATA folder, which contains the database)
2) Repeat step 1, but you'll lose any changes you made in production since the last time you pushed things up.
DNN doesn't really support this type of synchronization as a platform. They tried to offer it in their Enterprise product, but it worked so poorly they scrapped the feature.

Can SQL Server Express LocalDB be connected to remotely?

I am looking into using the new SQL Server Express LocalDB (I think it is code named "Denali") for a desktop application.
It is currently running with SQL Compact, but the user is wanting to share the database between multiple PCs on a network. Unfortunately this is not something that SQL Compact can do, so I am investigating other solutions.
The client requires the ability to send database files easily to other sites or to back them up to a flash disk, so I am avoiding going to SQL Express because there is quite a bit of "administrator" knowledge required to backup and restore.
So, my questions is, does the new SQL Express LocalDB support remote connections to the database over a network and/or through a shared network folder with the mdf file in it?
LocalDB does support supplying a path for an attached local DB in it's connect string (AttachDbFileName) hence the shared network folder option.
NOTE: This question pertains to "LocalDB" the new version of SQL Express 'Denali' and not to SQL Server Express 2008 or prior.
See article here announcing LocalDB's release: http://blogs.msdn.com/b/sqlexpress/archive/2011/07/12/introducing-localdb-a-better-sql-express.aspx
No, SQL Server Express LocalDB doesn't accept remote connections.
The idea with shared network folder might work, but only if you are able to make sure the LocalDB instance is shutdown before you try to copy the file. Also keep in mind that only one LocalDB instance can have any given database file open at the same time. and don't forget about the log files!
Additional security warning: unlike SQL Server Compact databases, SQL Server Express databases (including LocalDB ones) are not designed as secure data exchange format. For instance, they can contain malicious code in .NET assemblies embedded in them. So you should never open databases from untrusted source.
Maybe providing the customer with a simple tool that automates the backup process would be a better idea?
This isn't a fresh thread, but I would like to share my experience with SQL Server Express database LocalDB.
I have a WPF C# project using SQL database with LocalDb Engine. It is working fine no problem, I can use the database with the WPF app. I wanted this app to work on network with more PCs.
On the network another PC can use the database from my PC using UNC path in the connection string.
It seemed to me the remote connection is working. However when the remote PC is connected, I am not able to use the database with my local WPF app. If I run my app first the remote PC could not connect. So this tells me that the remote connection is working, but the multiple connection is not allowed.
OK, I didn't give up and I run the app from my PC twice and I saw it is working which tells me that the same SQL LocalDB engine can handle multiple connections locally only.
I hope this experience will help someone. Thanks.
In short, yes it can. Here is a tutorial on how to configure it.
Also, here is another post with a potential issue that might occur.
Both explain how to configure SQL Server Express to accept Remote Connections.

Portforward SQL Server?

I haven't done SQL in a while, so I need to freshen up on things. I have a SQL Database running on my computer, and my server is localhost. I made an app in VB.Net that connects to this database. Everything works fine and all, until I distrubute my app to another person. When they try to connnect it doesn't seem to work for them. Do you know whats happening, I copy the whole release folder to them, and they can't connect? Also does anyone know why my icon is not appearing for my application as well, when I give it to another person?
Sincerely,
Kevin
It looks like you are distributing the code with a connection to a MySQL server in localhost, but the other users do not have a SQL server installed. So, depending on what you actually want to do, you have alternatives:
You want to distribute your app with a database, where each user will have his own data (their own 'SQL server'): In this case I recommend you to use SQLite. That way, they don't have to install any database server because SQLite is a file-based DB server, all the funcionality is in the library, no install needed. http://sqlite.phxsoftware.com/ is a .NET binding that works very well.
You want for other people to connect to your database: Then you have to configure connectivity from your users to your database and have a means to configure the connection string, because you probably have "localhost" hard coded there now. Opening the DB server to the world is not a very wise thing to do in general, YMMV. A good alternative is to offer a web services / REST interface for clients to access the data instead of opening direct connections to the DB server.