Uninstall and install again V4

all about sql are uninstalled in Control panel. I install now Sambapos like always. We will see it !

This 2 files are not created and Sambapos doesnt start. NO LUCK TONIGHT ! :slight_smile:

So you still have those 2 files? If you do restore them.

Mdf and ldf files, it is just screenshot from my lapi. After a new installation this 2 files arent created on my actual pc. Samba doesnt start! For the first instalation on the same pc, everthing was good.

Google it maybe you can find a better answer from there. You need to get SQL to create those files again. Also remember never to delete them again.

This files are created per sambapos using sql. Correct? In this case sql is making problem, then sambapos cannot create them.

No the files are made by SQL Express…You have a master MDF file that is created by SQL Express… that mdf file contains references to all databases… including any for other applications… It is not a single file database created by the app. When you deleted it… SQL Express cannot start any databases or create them. You need to reinstall localdb and repair the mdf.

Give me a minute I will google some stuff for you.

this has some interesting information.

Open Server Explorer, right-click on Data Connections, select Create New SQL Server Database. For "Server Name" use "(LocalDB)\v11.0".

There is another option, as described here but it requires installation of SQL Server Data Tools. A version of the instructions for Visual Studio 2012 is also available.

Since you also mention SQL Server Management Studio, you can simply connect to the LocalDb instance and right-click on Databases, then Create, the standard way. It is more-or-less a regular SQL Server instance and all standard operations will function as usual.

Creating the database can also, obviously, be done from the application code as well, but that requires setting up appropriate database permissions. Depending on your environment that may or may not be a good idea.

I will try today what you said me!

I have installed SAMBAPOS without localdb option, it is starting with a warning. (no database, it is normal) When I install it with localdb, it doesnt start at all.
Uninstalling and installing again is really not possible. Hidden files must be deleted for a new installation?

Hold Alt key and press Tab key to see if there is an error dialog hiding behind the Loading screen.

Also check the logfile located here:


hello QMcKay
Thank you message.
I have check with ALT + TAB to see any error message, there is no message. It is staying always “Loading”
In fact i would like to uninstall and install again SAMBAPOS 4. I have uninstalled last day, i cannot install once again.

  • how can you completely uninstall sambapos and sql express 2012? I make in control panel normally. Another way to uninstall ?


You uninstall those programs through Control Panel Add/Remove Programs. There is no other way. But for both SambaPOS and SQL, un-installation will not remove database files.

There must be an error message somewhere. Did you check the logfile? Did you check Windows Event Viewer?

Where is kocated exactly database? I uninstalled sambapos and sql express via control panel, and removed mdf and ldf files manually. Let s say they are deleted accidentally. Why i cannot insatall it once again?

I make something wrong? Target is: uninstall and install sambapos once again.

If you use mssms and connect to it you can repair the issue. I’ve mentioned that a few times and I don’t see where you tried it?

Uninstalling sambapos and reinstalling will not fix your problem. I really feel it’s not A sambapos issue it’s SQL Express. You could also install SQL Express 2016. Start sambapos without the database then go to settings and set your connect string to connect to the 2016 Instance.

The localdB issue is probably because there is references to those mdf files somewhere that is not getting deleted and it keeps reverting to that.

However mssms can be used to create new mdf and you can tell it where to store it.

PS. I’ve told you where database is. There is not a single file database. The MDF file is the main file that is used but it’s not a single file database like CE.

EDIT: Read this it might help you understand.


Basically you ripped the mdf out without detatching the database first. There is a setting somewhere that is storing that information and when you uninstall localdb and reinstall it… it is still trying to use the MDF that you erased. You need to repair it and tell it to look for a new MDF.


It depends on the Database Engine. SQLExpress comes in 2 “flavors”.

###SQLExpress LocalDB

  • small installation
  • runs as a process, not a service
  • allows only 1 connection to the DB (does not work with multi-terminal setups)
  • DB files (mdf/ldf) stored in User folder (ie. C:\Users\username\)
  • NOTE: it is also possible that the DB files are located elsewhere, such as the Users (hidden) AppData folder within one of the Profile folders.
  • offered as an installation option with SambaPOS


  • larger installation
  • runs as a windows Service
  • allows multiple concurrent connections to the DB (required for multi-terminal setups)
  • DB files (mdf/ldf) stored in SQL Instance folder (default: C:\Program Files\Microsoft SQL Server\MSSQL12.SQLEXPRESS\MSSQL\DATA\)
  • the path varies depending on the version and Instance Name. (ie. for the path shown above, MSSQL12 refers to SQL 2014, and the Instance Name is SQLEXPRESS)
  • the Data path can be changed during SQL installation
  • NOT offered as an installation option with SambaPOS; must be manually downloaded and installed

The easiest fix… would be the load up mssms connect to the instance I provided few posts up in this conversation and then select the databases and delete them via mssms. When you start SambaPOS it should generate a new mdf.

You still have databases in the localdb instance but it cant find the mdf file. You need to delete those first. That is why its important to detach a database first if you want to move the mdf files.

So go ahead and reinstall SambaPOS and choose LocalDb option.

Download MSSMS Link is direct link to the download from MS and follow the following tutorial:

Here is what it should look like when you load mssms.

As the screenshot shows for Server name: you would enter (LocalDb)\v11.0

Once logged in it might look like this:

On left expand Databases then right click SambaPOS4 and choose delete.

Restart SambaPOS and it should create a new DB.