Prepare before configuration
- Install
Microsoft SQL Server Express 2017 (called MS SQL Server).
- Install
Microsoft SQL Server Management Studio.
- Install
DB connection service and setting tool Version 2. You can find it on
Disk5 folder in the DVD-ROM of GT Works3.
Exact path : x:\GTW3\Disk5\MESDB\DBCnct2_64\setup.exe
- Format
SD card (put it in the GOT2000).
GOT2000 MES Interface function requires MS SQL user account to log in the MS SQL Server.
Open
Microsoft SQL Server Management Studio.
Go to your SQL server
Properties:
In the
Sercurity tab enable the
SQL Server and Windows Authentication mode.
Go to SQL server object explorer and open
Properties of
sa user:
In
General tab
assign new password for sa user and
switch off password policy.
In
Status tab
Enable sa user account:
Create database and table for test
Using SQL Server Management Studio create databese for test.
Open context menu on sql server name and click
New Database...
Create new database for test data. Name it
MESDB:
Add new table to newly created database.
Open context menu on your database name and select New -> Table... :
Name first column as
ID and change data type to
int. Change first column property
IdentitySpecification (Is Identity) to
YES.
Name second column
value and change data type also to
int.
Click
save to confirm new table specification and put the
new tabe name ( MESTABLE ) in pop-up window then click
OK.
Your test database and table is ready to use.
Open ODBC configurator from
Start Menu -> Narzędzia Administracyjne Systemu Windows -> Źródła danych ODBC (64-bitowe)
Swich to the
System DNS tab and click
Add...
Select
ODBC Driver 17 for SQL Server
Name Data Source :
MESODBC (remember it cause you will use it in MES Interface configuration).
Write your SQL Server path.
Change the way of authentication to
SQL Server authentication and fill in the credentials accordin to
sa user.
Change the default database to the one you just created in SQL Server Management Studio
In next window confirm default settings by clicking
Close button
To confirm that ODBC can connect to the database click
Test Data Source
If the connection is allright you will see :
TESTS COMPLETED SUCCESSFULLY!
Open the GOT
Utility main menu (usualy by holding left-top corner of the GOT screen couple seconds - if not working switch this functionality on in the GOT project) then go to the Licence management screen. Then
put your MES interface function license code and press Regist.
Open GT Designer3 project to configure MES Interface function.
In the
project tree open MES interface branch.
In the Server service settings:
As a
Server service name put the name of the database.
Fill in the
IP address of the PC with the database.
Fill in the user credentials of the
sa user you setup in the
database.
As Data source name use the name of your ODBC connection.
In the Device tag settings:
Add one tag named
InsertData with three components :
Insert(GB200), InsertCompl(GB201), Value(GD0) as it is below:
In the Job settings:
Add new job :
NewJob1 with the
Trigger 1: Value monitoring startup. As monitored component use:
InsertData->Insert component.
In actions click
Add button to add
Insert action.
When action pop-up opens please add the settings as on the below screen.
Action type:
Insert,
Database:
MESDB (your sql db),
Table name:
MESTABLE (your sql table),
As the
Field name use the name of column from your sql table,
As
tag with value use created tag :
InsertData->Value.