If you are using the Scriptcase automatic installation, the PHP architecture will be the same as the installer that you have downloaded.


Setting up SyBase on Windows

The automatic installation already comes with the SyBase driver, only needing to connect with the database in the ScriptCase.


Configuring the SyBase on Windows

Before we continue this tutorial it is necessary to verify the PHP architecture in the [phpinfo()][url_phpinfo]. Accessing the PHP Info of your Scriptcase, for example, you will find the PHP architecture.

Arquitetura do PHP

  • Architecture x86 = 32 bits
  • Architecture x64 = 64 bits

If you are using the Scriptcase installer the PHP architecture will be same of the installer you have downloaded.

The automatic installation of scriptcase already has the SyBase previously configured, only missing the SyBase ODBC Driver to create the connection.

The SyBase ODBC Driver it’s already installed with the SyBase database. If you are using the Scriptcase in the same server of your database won’t be need to install the SyBase ODBC Driver.

In case the Scriptcase server is other, will be need to install.

You will need to access the site and download the SyBase ODBC Driver 32 or 64 bits. The architecture of the installer need to be the same of you Operational System.

Creating an ODBC Data Source

  • Access the Control Panel > System and Security > Administrative tools > ODBC Data Sources(32 or 64 bits), according to the architecture of your PHP.
  • If you have a data source configured, proceed to Creating the connection inside Scriptcase.

  • Select the tab System DNS and click in Add.

Accessing and configuring the ODBC data source Accessing and configuring the ODBC Data Sources

  • Choose the SyBase Driver:
    • Adaptive Server Enterprise

ODBC Driver available ODBC Driver Available.

  • After select the driver the screen below must appear, In the tab “General” you need to inform the data for the connection:
    • Data Source Name: Name of the data source that will be used to create the connection with Scriptcase.
    • Server Name: Server IP where the Database is.
    • Server Port: Inform the default port of your Database. The default port is 5002.
    • Database Name: Name of your Database.
    • Logon ID: Name of your Database user.
    • Service Name: Name of the Database service.
    • BackEnd Type: Your Database type.

Creating the data source. Creation of the Data Source.

  • After have informed the data above, click in Advanced > Client Charset > Others, to inform the charset of your Database.

Select Database. Select the Data Base.

  • After finished the settings above click in OK to finish the ODBC Data Source creation. Will be showed the ODBC Data Source Administrator where is possible to view your data source created.

Creating the data source. Creation the Data Source.

Creating a Connection with ScriptCase

  • Access ScriptCase using the URL
  • After accessing ScriptCase, access or create a new project, click on the new connection icon or access “Database > New Connection”

Creating a new connection Creating a new connection

  • After that, you will see a page with all the database connections that you can create. Select a “SyBase” connection

 Selecting a Windows database connection Selecting a Windows database connection

  • New connection : You will place the information of the connection to your database here:

 Connecting with Windows database Connecting with Windows database

  • Connection Name : Defines the name of your new connection.
  • DBMS Driver : Allows you to select the drivers: Sybase_ct.
  • Server/Host (Name or IP) : Insert the name or IP of the server where the Windows database is located.
  • Database Name : Select the database.
  • Username : Inform the user to access the Windows database.
  • Password : Inform the password to access the Windows database.
  • Test Connection : Displays a message of the status of the connection if successful or not.

  • For more options on connecting, click on the Advanced tab:

![ Advanced setup for the Windows database][conexao_avancado_all] Advanced setup for the Windows database

  • Decimal Separator - Select the separator type, between a dot or a comma.
  • Persistent Connection - Persistent Connection are connections that do not close when finishing a script.
  • Use the schema before table name - Allows the use of schema before the name of the tables.

  • Filter : Accessing this tab, we can setup which tables will be listed on this connection:

Filtering the Windows database Filtering the Windows database

  • Show - Allows the display of the the filters on the tables, views, System Tables and procedures.
    • Tables - Allows to setup the display of Tables from your database.
    • Views - Allows to setup the display of Views from your database.
    • System Tables - Allows to setup the display of System Tables from your database.
    • Procedures - Allows to setup the display of Procedures from your database.
  • Searches - Allows to define which tables and Owner will be displayed.
    • Tables - Allows to define a prefix (prefix%) or name of the tables for display.
    • Owner - Allows to define the owner of the tables for listing.
    • Show - Allows to define what will be displayed or not from the table an owner’s setup.

.png .png [conexao_avancado_all]: ../../../../assets/images/docs/database/conexoes/avancado.png