The IBExpert Block Editor can be used to edit and execute IBEBlocks and IBEScripts.
The DBExplorer's Scripts/Blocks page displays all existing IBEScripts and IBEBlocks saved locally in the database. The DB Explorer Database page also has a new node, Scripts, displayed in all registered, connected databases. See also Drag 'n' dropping objects into code editors and the DB Explorer context-sensitive menu item, Apply IBEBlock to selected object(s).
There are two ways to store blocks and scripts: (i) in a registered database or (ii) in the IBExpert User Database, which can be activated using the IBExpert Options menu item, Environment Options / User Database. It is strongly recommended to use the IBExpert User Database as the main storage for IBExpert, even if you do not need the Scripts/Blocks feature.
To create a new script in a registered database, click on the Scripts node in the connected database, and use the context-sensitive (right-click) menu to create a new script. You can also create IBEBlocks and Firebird 2 blocks (EXECUTE BLOCK) in this way within your database. Each script or block must have a unique name (up to 100 characters) within the database.
To create a new block or script in the User Database, first enable the option in the IBExpert Options menu, Environment Options / User Database and restart IBExpert. You should now see a new table in the Database Explorer: Scripts/Blocks. This allows you to create scripts and blocks using the context-sensitive menu from the Scripts/Blocks tree and also organize them in folders.
It is even possible to execute Firebird 2.0 blocks stored in registered databases or in the IBExpert User Database directly from the Database Explorer. Simply use the Database Explorer right-click context-sensitive menu or open the script in the Block Editor and execute using [F9].
When writing new IBEBlocks, do not forget to save the block by clicking on the Save icon, in order to commit it, before running it. Input parameters can be specified by clicking on the Parameters icon (or using [Shift + Ctrl + P]), and the block run in the usual IBExpert way by using [F9] or the green arrow icon.
Please refer to IBEBlock and IBEScript for further information and examples of these comprehensive features. Similar to the Debug procedure, trigger, function (IBExpert Debugger)|Procedure and Trigger Debugger, the Block Editor allows you to debug your script or block. It offers the same informational pages: Parameters and Variables, Watches, Last Statement, Breakpoints, Messages, Results and SQL Editor Messages.
Please refer to pp02-ibexpert:02-03-database-objects:stored-procedure:#Debug procedure, trigger, function (IBExpert Debugger)|Debugger]] for further details.
The data on the IBEBlock Results page can be sorted by clicking on a grid column caption. This data can also be exported.