Servername.company.com vs. servername like it is in db properties

OK.My user gets error ‘cannot find path to server’ when pressing the button with following code:

@Command([FileOpenDatabase];“Servername.companyname.com”:“CRM\SIEBELUAT.NSF”);

{lots of other stuff here}

But it works, when pressing the button like this one:

@Command([FileOpenDatabase];“ServerName/How/It/IS/Indbproperties”:“CRM\SIEBELUAT.NSF”);

{lots of other stuff here}

It works fine!

What’s the difference? Either works fine for me???

Subject: servername.company.com vs. servername like it is in db properties

I’m not a developer so will not comment your code because do not know anything about it, but from network perspective this sounds like DNS issue…you said either works for you but only one for user, are you guys in same location? same LAN, using same DNS? do you have static entries in you PC’s host file… these are things to look for

Subject: RE: servername.company.com vs. servername like it is in db properties

Well, he sits about three desks down, so same location lol!

I wonder tho, he is probably on different mailserver…It occours he may have even been using a local mailfile, maybe that wouldn’t help…

I do not know what 'static entries in your PC’s host file is…

I give up I’ll just use the method that works!

Subject: Connection Doc or different DNS Segment?

Your user may be on a different network segment where the DNS name of the server cannot resolve.

The distinguished name of the server is found by either a local connection doc or a lookup to the user’s defined home server’s NAMES.NSF for that server name in the home server’s DNN.

Have user put a connection doc in local names.nsf with IP addr associated to that DNS name…

well…it’s worth a shot anyway…

Subject: servername.company.com vs. servername like it is in db properties

It really is not a good practice to hardcode server names and database names. I normally use the following:

database := @Subset(@DbName; -1);

server := @Name([CN]; @Subset(@DbName; 1));

Or use a profile document in the database and do a lkup to it.

Subject: RE: servername.company.com vs. servername like it is in db properties

Thanks Tom.In general, I agree. But this is not really part of an application, it’s just a button to go out to users…

I can’t use @DbName because that would be there mailfile (not the application server), and I can’t use profile docs on their mailfiles…

In general tho I guess that is good advice. Just seems strange that one works not the other…

Subject: RE: servername.company.com vs. servername like it is in db properties

Yeah, sort of strange, I expect the other posts are correct, most likely dns / network issues - I’ll bet you can ping servername.com and the other user’s can’t resolve it, hence the error.

The host file is stored in your C:\WINNT\system32\drivers\etc which acts like a local dns for resolution.

if you can’t use a profile doc, maybe you can use an environment variable or grab the servername from thier location document - if its the same.

I have done many projects cleaning up other developer’s code where they have hardcoded stuff all over the place(server and dbnames, paths), if the infrastructure group decides to consolodate servers and your application gets moved, it becomes problematic.