Hello,
this is a tip for beginners like me:
have you noticed how long does it take to process the code generations when you use a database on a remote server?
I finally replicated the db locally but had really an hard time in selecting the correct database every time.
Now my apps change db accordingly to where I am accessing them from.
It’s important that the application database is on your local machine to avoid taking too much to generate code;
it took me a while to achieve this and it might be helpful for others!
This has to be put in the onApplicationInit Event
$server = $_SERVER['SERVER_NAME'];
switch ($server) {
case 'YOURDOMAINNAME':
sc_change_connection ('conn_mysql_LCL', 'conn_mysql_WEB');
break;
case 'YOURLOCALSERVERNAME': // or jus use default:
break;
}
Have a good day!