Problem with multiple databases

blikens
Member Posts: 10
My company has its LIVE database on one server, a test database on another, and then individual copies on hard drives for employees doing form and report design. The design employees synch their work product into the test database and after testing and evaluation, the test database is synched to the live database. The Live database has a different colored bmp for the main menu so users can tell when they are in the live database. Is there a system variable that would allow me to determine if I am working on local database or the network test database so I can change a caption or give myself some sort of warning if I start to do something and I'm not where I thought I was...
0
Comments
-
How about basing your solution on the COMPANYNAME (or part thereof)?0
-
That's a reasonable suggestion, but all the databases are based on the live database and all share the same company name. I suppose I could rename the companyname on each system, but was hoping there might be a system variable with database path.0
-
Take a look at 2000000010 Database file, this table holds the information you need.
Soren,
www.navision.net - the #1 source for navision information0 -
I don't have a 2000000010 object in my tables, but I'm betting that granule is associated with multiple live database licenses. I'm sure it would have been an elegant solution, but back to the drawing boards. I'll have most of the modifications finished shortly, so the issue will be moot, but I was curious to learn a little extra (and maybe keep myself from having to repeat some work). Thanks0
-
hi ,
as soren said that you can find out the database name in any place of code.You cann't see the Database file Object from the Object designer,but you can see the database file from the C/AL Globals or you can create a form from that table.These tables are called virtual tables.Just create a variable to the database file object.
dtfile record databasefile
in Code you can write the following lines to find out the database name.
dtfile.find('-');
databasepath := dtfile."File name";
now you got the database file path in the Databasepath variable.
now you can check out is it Locat database or server database,using string operations.
Mohan
[This message has been edited by Mohan (edited 03-06-2001).]0 -
Thanks for the insight. This solved my issue quite handily!!!0
Categories
- All Categories
- 73 General
- 73 Announcements
- 66.6K Microsoft Dynamics NAV
- 18.7K NAV Three Tier
- 38.4K NAV/Navision Classic Client
- 3.6K Navision Attain
- 2.4K Navision Financials
- 116 Navision DOS
- 851 Navision e-Commerce
- 1K NAV Tips & Tricks
- 772 NAV Dutch speaking only
- 617 NAV Courses, Exams & Certification
- 2K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 320 Dynamics CRM
- 111 Dynamics GP
- 10 Dynamics SL
- 1.5K Other
- 990 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 35 Design Patterns (General & Best Practices)
- 1 Architectural Patterns
- 10 Design Patterns
- 5 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1.1K General Chat
- 1.6K Website
- 83 Testing
- 1.2K Download section
- 23 How Tos section
- 252 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions