Product Documentation

FairCom Java Stored Procedures

Previous Topic

Next Topic

Init

First we need to open a connection to the FairCom Database Engine.

Below is the code for Initialize():

SET ECHO OFF

-- Initialize

ECHO INIT;

SET AUTOCOMMIT ON;

IF EXISTS (select proc_name from sysprocedures where proc_name = 'define')

BEGIN

DROP PROCEDURE Define;

END

IF EXISTS (select proc_name from sysprocedures where proc_name = 'add_customermaster_record')

BEGIN

DROP PROCEDURE Add_CustomerMaster_Record;

END

IF EXISTS (select proc_name from sysprocedures where proc_name = 'add_customerorders_record')

BEGIN

DROP PROCEDURE Add_CustomerOrders_Record;

END

IF EXISTS (select proc_name from sysprocedures where proc_name = 'add_orderitems_record')

BEGIN

DROP PROCEDURE Add_OrderItems_Record;

END

IF EXISTS (select proc_name from sysprocedures where proc_name = 'add_itemmaster_record')

BEGIN

DROP PROCEDURE Add_ItemMaster_Record;

END

IF EXISTS (select proc_name from sysprocedures where proc_name = 'delete_records')

BEGIN

DROP PROCEDURE Delete_Records;

END

IF EXISTS (select proc_name from sysprocedures where proc_name = 'display_records')

BEGIN

DROP PROCEDURE Display_Records;

END

TOCIndex