[RESOLVED] Can't reinstall Samba, it doesn't build a database anymore

I have had it working, but wanted to reinstall it, to clear out the test data in the database. I uninstalled both Samba and the SQL programs, but now it doesn’t create a new database anymore on installation. The installation completes without error messages, but at program launch, it gives an error, saying that it cannot find the database, through the given path. Any ideas what to do?

Here the log::

*[Exception Info 1]
Top-level Exception
Type: System.ArgumentException
Message: Format of the initialization string does not conform to specification starting at index 27.
Source: System.Data
Stack Trace: at System.Data.Common.DbConnectionOptions.GetKeyValuePair(String connectionString, Int32 currentPosition, StringBuilder buffer, Boolean useOdbcRules, String& keyname, String& keyvalue)
at System.Data.Common.DbConnectionOptions.ParseInternal(Hashtable parsetable, String connectionString, Boolean buildChain, Hashtable synonyms, Boolean firstKey)
at System.Data.Common.DbConnectionOptions…ctor(String connectionString, Hashtable synonyms, Boolean useOdbcRules)
at System.Data.Common.DbConnectionStringBuilder.set_ConnectionString(String value)
at System.Data.SqlServerCe.SqlCeConnectionStringBuilder…ctor(String connectionString)
at System.Data.SqlServerCe.SqlCeConnection.set_ConnectionString(String value)
at System.Data.Entity.Infrastructure.SqlCeConnectionFactory.CreateConnection(String nameOrConnectionString)
at System.Data.Entity.Internal.LazyInternalConnection.Initialize()
at System.Data.Entity.Internal.LazyInternalConnection.get_Connection()
at System.Data.Entity.Internal.LazyInternalContext.get_Connection()
at Samba.Infrastructure.Data.SQL.EFWorkspace…ctor(CommonDbContext context)
at Samba.Persistance.Data.WorkspaceFactory.Create()
at Samba.Presentation.Bootstrapper.InitializeShell()

[Assembly Info]
PresentationFramework, Version=4.0.0.0
System.Xaml, Version=4.0.0.0
Microsoft.Practices.Prism.MefExtensions, Version=4.0.0.0
mscorlib, Version=4.0.0.0
System, Version=4.0.0.0
WindowsBase, Version=4.0.0.0
Samba.Services, Version=1.0.0.0
Samba.Presentation.Services, Version=1.0.0.0
Samba.Presentation.Common, Version=1.0.0.0
Samba.Domain, Version=1.0.0.0
PresentationCore, Version=4.0.0.0
Microsoft.Practices.ServiceLocation, Version=1.0.0.0
Samba.Infrastructure, Version=1.0.0.0
Microsoft.Practices.Prism, Version=4.0.0.0
System.ComponentModel.Composition, Version=4.0.0.0
DevExpress.Xpf.Core.v13.2, Version=13.2.5.0
Samba.Localization, Version=1.0.0.0
FastButton, Version=1.0.0.0
-----------------------------*

I had same probleme because I didn’t completly desinstall sambapos4.
You must desinstall sambapos4 with windows program and erase manualy the last folder sambapos4 in “/Documents” and “/Program Files” (if not totaly remove)
If you don’t do this, sambapos4 keep your old settings in memory (that is your old database settings and since you have erased your sql database, you get this message)
When you completly remove sambapos4, when you reboot, you start with a new file.sdf database
Hope that will help you

Or an easy way, you replace the path database to your sambapos4.sdf file which is in ./documents folder when you get the error message (but don’t know if that works)

It seems there is an error with your “Database Connection String”

If it popups a dialog that displays your connection string you can correct it there.

Or you can completely reset all local settings to default by deleting SambaSettings.txt file under C:\ProgramData\SambaPOS\SambaPOS4. It will be better if you copy it to somewhere since you may need it for checking your previous settings.

1 Like

Sorry, I forgot this folder :blush:

Ok, first of all thank you for your swift responses. I managed to get the issue resolved.

@amaury254 - I had completely deinstalled the software and manually removed all traces of Samba, including quite a few registry strings, without success. Samba still kept redirecting to a database that didn’t exist. No idea where this path was stored on my computer.

@emre - In fact it wasn’t a problem with the path, as the database sambapos4.sdf simply didn’t get created upon reinstall. Due to this faulty database connection string that it kept referring to, it didn’t build the database. There was nothing that I could find in SambaSettings.txt either, but as I mentioned before, I had removed all files, directories and registry entries related to Samba on the computer.

When finally I changed the path in the error dialogue window to only the database name (sambapos4.sdf), it did create the database and all went well.

Hope this helps.

The reason I did the reinstall was a problem with changing the test entries in the database, it didn’t refresh the database after changes made. I’ll see if I can find a solution to that one now… We are planning to use Samba on a Microsoft Surface Pro as POS system in a bar, here in Paris. I’ll post the result as soon as we have it operational.

1 Like