Logging your work – PB Docs 2017

Logging your work

As you work with your database, you generate SQL statements. As
you define a new table, for example, PowerBuilder builds a SQL CREATE
TABLE statement internally. When you save the table, PowerBuilder
sends the SQL statement to the DBMS to create the table. Similarly,
when you add an index, PowerBuilder builds a CREATE INDEX
statement.

You can see all SQL generated in a Database painter session in
the Activity Log view. You can also save this information to a file.
This allows you to have a record of your work and makes it easy to
duplicate the work if you need to create the same or similar tables in
another database.

To start logging your work

  1. Open the Database painter.

  2. Select Start Log from the Design menu or the pop-up menu in
    the Activity Log view.

    PowerBuilder begins sending all generated syntax to the
    Activity Log view.

To stop the log

  • Select Stop Log from the Design menu or the pop-up menu in
    the Activity Log view.

    PowerBuilder stops sending the generated syntax to the
    Activity Log view. Your work is no longer logged.

To save the log to a permanent text file

  1. Select Save or Save As from the File menu.

  2. Name the file and click Save. The default file extension is
    SQL, but you can change that if you want to.

Submitting the log to your DBMS

You can open a saved log file and submit it to your DBMS in
the ISQL view. For more information, see Building and
executing SQL statements
.


Document get from Powerbuilder help
Thank you for watching.
Was this article helpful?
Subscribe
Notify of
guest
0 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x