Cannot open database "DatabaseName" requested by the login. The login failed.
Cause: The database doesn’t exist, or the user doesn’t have access.
Solution 1: Verify database name
Database names are case-sensitive on some SQL Server configurations.Check existing databases:
SELECT name FROM sys.databases ORDER BY name;
Make sure the database name in shopMaster Settings matches exactly.
Solution 2: Grant database access
The login exists but doesn’t have a user in the database:
USE YourDatabaseName;GOCREATE USER your_username FOR LOGIN your_username;GOGRANT SELECT, INSERT, UPDATE, DELETE ON dbo.YourTableName TO your_username;GO
Solution 3: Check database status
The database might be offline or in recovery mode:
Cause: No internet connection detected.How it works:
shopMaster checks internet connectivity before syncing by making a request to https://www.google.com/ (see app/check_connection.py:3).Solutions:
Check your internet connection
Verify you can browse websites
Check if your firewall is blocking shopMaster
Try pinging google.com from Command Prompt:
ping google.com
Check proxy settings
If you’re behind a corporate proxy, shopMaster’s requests might be blocked. You may need to configure proxy settings in your environment.
ENABLE TRIGGER trgAfterInsert ON dbo.YourTableName;ENABLE TRIGGER trgAfterUpdate ON dbo.YourTableName;ENABLE TRIGGER trgAfterDelete ON dbo.YourTableName;
3
Test trigger manually
Make a test change:
UPDATE dbo.YourTableNameSET SellPrice = SellPrice + 0.01WHERE ProductID = 'TEST001';-- Check if it loggedSELECT * FROM ChangeLog WHERE ProductID = 'TEST001';
4
Check Digible API response
Look at the shopMaster console output during sync. You should see:
Response status code: 200Response content: {...}
If status code is not 200, check the error message.
Cause: Your product table has different column names than expected.Required columns:
ProductID - VARCHAR(25)
ProductName - VARCHAR(75)
SellPrice - NUMERIC(18, 2)
QrCode - VARCHAR(100)
Status - INT
Solution:
Option 1: Rename your columns (if possible)
EXEC sp_rename 'YourTable.OldColumnName', 'ProductID', 'COLUMN';EXEC sp_rename 'YourTable.OldProductName', 'ProductName', 'COLUMN';-- Repeat for each column
Renaming columns may break other applications using this database. Test thoroughly.
Option 2: Create a view with standard names
CREATE VIEW Products ASSELECT YourProductIDColumn AS ProductID, YourProductNameColumn AS ProductName, YourPriceColumn AS SellPrice, YourQRColumn AS QrCode, YourStatusColumn AS StatusFROM YourActualTable;
Then use Products as your table name in shopMaster Settings.
Cause: Your SQL Server user doesn’t have permission to create triggers.Solution:
-- Grant permission to create triggersUSE YourDatabaseName;GOGRANT ALTER ON SCHEMA::dbo TO your_username;GO-- Or grant more comprehensive permissionsGRANT CREATE TABLE TO your_username;GRANT CREATE PROCEDURE TO your_username;
If you don’t have administrator access, ask your DBA to run the Configure step with an admin account, then switch back to your regular account for syncing.
ChangeLog table already exists with different structure
Symptom: Configuration fails or triggers don’t work correctly.Solution:
1
Backup existing ChangeLog (if needed)
SELECT * INTO ChangeLog_Backup FROM ChangeLog;
2
Drop existing objects
-- Drop triggersDROP TRIGGER IF EXISTS trgAfterInsert;DROP TRIGGER IF EXISTS trgAfterUpdate;DROP TRIGGER IF EXISTS trgAfterDelete;-- Drop tableDROP TABLE IF EXISTS ChangeLog;
3
Re-run Configure in shopMaster
Go to Settings and click Configure to recreate everything with the correct structure.
Symptom: Application crashes immediately or shows error dialog.
Missing .env file
shopMaster requires a .env file in the same directory as the executable.Solution: Run shopMaster, go to Settings, and complete the configuration. This creates the .env file.
Corrupted .env file
If the .env file is corrupted, delete it and reconfigure:
Close shopMaster
Delete the .env file
Start shopMaster
Complete Settings configuration
Python runtime error
If you’re running from source, ensure you have all dependencies:
Symptom: You click “Start Sync task” and see the message, but no syncs occur.Cause: The background scheduler thread is running, but sync conditions aren’t met.Checklist:
1
Ensure you've configured
You must click Configure in Settings before syncing works.
2
Check token validity
If your Digible token expired, automatic sync silently fails. Check the console for “User Session expired” messages.
3
Verify internet connection
The sync only runs when is_connected() returns True.
4
Check for database changes
The ChangeLog table must have entries for sync to send anything:
SELECT COUNT(*) FROM ChangeLog WHERE ChangeType IN ('INSERT', 'UPDATE');
The scheduled sync runs every 2 minutes (see main.py:38). Wait at least 2 minutes after clicking “Start Sync task” before troubleshooting.
Symptom: Sync takes a very long time or times out.Cause: Large batch sizes or network latency.Current behavior:
Batch size: 200 products per request (see app/helper.py:141)
All products are loaded into memory before sending
Solutions:
Use 'Upload Products' for initial sync
The Upload Products button in Settings sends your entire product catalog in batches of 200. Use this for the initial sync instead of waiting for individual changes.
Reduce batch size for slow networks
If you’re experiencing timeouts, you may need to modify the batch size in the source code.
This requires rebuilding the application from source.
Index the ChangeLog table
Add an index to speed up sync queries:
CREATE INDEX IX_ChangeLog_ChangeTypeON ChangeLog(ChangeType, ChangeDateTime);
Symptom: shopMaster uses excessive CPU continuously.Cause: The schedule check loop runs every 10 seconds (see main.py:32).This is normal behavior. The application uses minimal CPU most of the time, with brief spikes during:
If you’ve tried these solutions and still have issues:
1
Check console output
shopMaster prints detailed logs to the console. Look for error messages and stack traces.
2
Test components individually
Test SQL Server connection in SSMS
Test Digible login credentials in browser
Verify internet connectivity
3
Gather diagnostic information
Before contacting support, collect:
Error messages (exact text)
SQL Server version: SELECT @@VERSION
ODBC driver version
shopMaster version
Relevant console output
4
Contact Digible support
Reach out to Digible support with your diagnostic information for personalized assistance.
Most issues are related to SQL Server permissions or network connectivity. Start troubleshooting there before investigating application-specific issues.