Cannot setup server

I have an “issue” – this is on OS X 10.4.1

  1. Created a new db in Servoy/databases/, let’s call it FOO, in Sybase Central (4.3.0.2258) All went OK, no error reported by S.C. All was done according the the manual (e.g., use logging, UTF8, etc.)

  2. Added “database/foo.db” to the sybase.config file

  3. Launched Servoy and tried to name the new Sybase ASA connection. [I notice that there are no ***'s in the Password field, whereas “dba” does show in the User Name field … I forget if this is normal??] Server Name = foo; Database Server URL modifed to read:
    jdbc:sybase:Tds:localhost:2638?ServiceName=FOO&CHARSET=utf8

  4. When I click OK I get the dreaded “Cannot setup server” dialog. The details say:
    “java.sql.SQLException: JZ00L: Login failed. Examine the SQLWarnings chained to this exception for the reason(s).”

Not sure where to look for SQLWarnings. I found an old thread very similar to this problem, but …

– the problem for that developer seemed to be connected to some kind of corruption. This is a spanking new database
– that thread said to look in the sybase log for the “SQLWarnings chained to this exception”
– this is all my sybase_log.txt file says (even after exiting the whole connecton-naming process and quitting Servoy):
“I. 06/30 10:43:16. Database server started at Thu Jun 30 2005 10:43
I. 06/30 10:43:16. Trying to start SharedMemory link …
I. 06/30 10:43:16. SharedMemory link started successfully
I. 06/30 10:43:16. Trying to start TCPIP link …
I. 06/30 10:43:16. Starting on port 2638
I. 06/30 10:43:16. TCPIP link started successfully
I. 06/30 10:43:16. Now accepting requests”

What next?

If anyone is about to give me advice about doing something in the shell, please be gentle. The shell scares me due to lack of experience on the command line.

Molto grazi.

kazar

Hi Kazar

When I started using Servoy I too used to dread seeing that wretched “Cannot setup Server” message. Happily I rarely see it now but here’s some thoughts from my own checklist

Although you closed Servoy didn’t say if you also stopped the SQL service - if not this is most likely problem and can jump to 4) below

1 check messages in …/Servoy/.log.txt
2 have you added db to sybase.confi using exact filename & all lowercase
3 change Connection Servicename to all lowercase - suggest using lowercase for all db_names, usernames and passwords
4 quit Servoy then stop dbsrv9 Service using Applications/Utilities/Process Viewer
5 restart Servoy

Best of luck

Graham Greensall
Worxinfo Ltd

Thanks for the reply, Graham!

Although you closed Servoy didn’t say if you also stopped the SQL service - if not this is most likely problem and can jump to 4) below

yes, I did use Activity Monitor (what it’s called on Tiger) to quit the dbsrv9 process before I relaunched Servoy

1 check messages in …/Servoy/.log.txt

I’m sorry, how do I get to that file? Filenames that start with “.” are hidden on a Mac. I tried doing a Find for invisible files that start with .log and came up blank.

2 have you added db to sybase.confi using exact filename & all lowercase
3 change Connection Servicename to all lowercase - suggest using lowercase for all db_names, usernames and passwords

Umm, never knew that. I’ve been following the example given in the very excellent “Migrating a FileMaker Solution to Servoy” tutorial that Bob Cusick wrote (ClickWare). In the example given, the database created in Sybase Central is named in solid caps, and the URL path for the database when naming the connection is also in solid caps. However, the database name is typed into the sybase.config file in all lower-case, and the database connection is named in all lower-case. I figured this was not something arbitrary in the example, but was a protocol to be followed. And I followed it.

After I post this, I’ll start over attempting to create and then connect to a database with all instances of typing its name being in all lower-case characters. I’ll let you know if that helps. But the main thing is, where do I find this SQLWarnings? Don’t see the “.log.txt” file you refer to in the Servoy directory (as well I shouldn’t see anything on a Mac that starts with “.”), and the sybase_log.txt file another thread pointed to shows nothing suspicious. It might help if I could locate the log that might give some specifics as to What Is Wrong.

Best of luck

thanks, I think I need it today. ever have a day where your chops are just off by a few degrees? probably time to take a real hoiday weekend (here i the States) and get away from this screen.

kazar

Hopefully you’ll be up & flying along by the time this filters through . . .

I usually work on XP and the .log.txt file is in main Servoy folder - BUT just checked on my Powerbook OSX 10.2.8 and can’t find the .log.txt file !!!

Another thought - do a Search for “servoy.properties” files. Should only be one but you may find two and discover that only one of them has links to your new DB. Check that the details on the new db server in servoy.properties exactly match the real file.

BTW once you’ve got it running make a copy of the properties file - Servoy can get confused if you play with the Runtime module and its saves a lot of time to just copy back a known version.

Shout again if you’re still in trouble

Graham Greensall
Worxinfo Ltd

Are you also sure this database is opened by Sybase iAnywhere?
Sybase iAnywhere is one of the database engines where you can load specific databases into the server.

To make sure your database is loaded in Sybase iAnywhere add it to /Application//sybase_db/sybase.config

In that same directory you also find sybase_log.txt. Which, I think, is what Graham was referring to.
Any problems Sybase iAnywhere has will be logged here.

Hope this helps.

The warning you see tells you you can’t login.

  1. If you did not set up you new database in your sybase.config file in your servoy/sybase_db directory you should first do that. Don’t forget to throw you new db in the servoy/database directory or point to the correct directory.

  2. I don’t thing any upper/lowercase juggling will help you. Not sure how this works out in Sybase and Servoy but the mac doesn’t do anything with it (to see this happening create two new folders. One with the name ‘New’ and the next one ‘new’. You will get a warning that the name is already used).

  3. The message you see is database specific. Google for ‘asa java.sql.SQLException: JZ00L’ or see the docs and you will see some pointers…

grahamg:
Another thought - do a Search for “servoy.properties” files. Should only be one but you may find two and discover that only one of them has links to your new DB. Check that the details on the new db server in servoy.properties exactly match the real file.

There are two copies of files named servoy.properties on my drive.

One is in: Applications/Servoy/

The other is in Users/sybase/

Which one should I trash? Or are these both supposed to be there?

Gosh. To date I’ve been working with pre-created db’s. Right now this process of creating a new solution has taken 1.5 days with zero results, very frustrating. But better to find out up front what all the potential pitfalls are, after which I’m sure this must be a breeze…

kazar

Hi Ilyse,

I read in your initial post that the password did not have ‘***’ in there but did you actually enter a password ?

Sybase databases have user: ‘dba’ & password : ‘sql’ as default so make sure that ‘sql’ goes in there.

Also the other gotcha as has been mentioned is that SC allows you to create a new database but you have to be careful that this database actually does reside in Servoy folder OR that the full path to that database is what gets entered into the sybase config file and not just 'database/foo.db !

BTW the .log.txt file which Graham mentioned is in the Servoy folder but is hidden…so, I use BBedit to open hidden files as lo, there it is !

Cheers
Harry

ROCLASI:
Are you also sure this database is opened by Sybase iAnywhere?
Sybase iAnywhere is one of the database engines where you can load specific databases into the server.

To make sure your database is loaded in Sybase iAnywhere add it to /Application//sybase_db/sybase.config

Yes, as per my first post, I’ve done all steps by the book, including adding the db to the sybase.config file. The stopped the dbserv9 process and then restarted Developer.

In that same directory you also find sybase_log.txt. Which, I think, is what Graham was referring to.
Any problems Sybase iAnywhere has will be logged here.

Again, from my intial post, this is all the sybase_log.txt file says:

“I. 06/30 10:43:16. Database server started at Thu Jun 30 2005 10:43
I. 06/30 10:43:16. Trying to start SharedMemory link …
I. 06/30 10:43:16. SharedMemory link started successfully
I. 06/30 10:43:16. Trying to start TCPIP link …
I. 06/30 10:43:16. Starting on port 2638
I. 06/30 10:43:16. TCPIP link started successfully
I. 06/30 10:43:16. Now accepting requests”

Any clues in there I’m not seeing?

Any and all ideas, whether repetition of stuff in the manual or completely outside-of-the-box are most welcome. Thanks!

kazar

Re: two servoy.properties files.

I would rename the one in Users/Sybase, check the …/Servoy/ one to be sure that it has your new db details then re-boot.

Getting a new database/solution runing the first time is probably the hardest thing you’ll face in Servoy if coming from a Filemaker type background - but it’s like riding a bike so once you’ve stopped wobbling it’ll be fine.

Regards

Graham Greensall

grahamg:
I would rename the one in Users/Sybase, check the …/Servoy/ one to be sure that it has your new db details then re-boot

BINGO!

thanks to everyone who has responded for keeping me from quitting and getting a job changing light bulbs in a factory, and thanks to Graham for the answer that worked!

Strange that a servoy.properties file got written to top level of a User directory?? Anyhow, even if the mystery is not solved, the problem is.

Finally: Back To Work.

kazar