Recent from talks
Nothing was collected or created yet.
PowerBuilder
View on Wikipedia| Appeon PowerBuilder | |
|---|---|
| Developer | SAP/Appeon |
| Initial release | July 1992 |
| Stable release | PowerBuilder 2025
/ May 7, 2025 |
| Preview release | None
|
| Written in | C++ and C# |
| Operating system | Microsoft Windows |
| Available in | English, Japanese for the IDE (numerous languages supported for deployed applications) |
| Type | IDE |
| License | Commercial |
| Website | www |
PowerBuilder is an integrated development environment owned by SAP since the acquisition of Sybase in 2010. On July 5, 2016, SAP and Appeon entered into an agreement whereby Appeon, an independent company, would be responsible for developing, selling, and supporting PowerBuilder.[1]
Over the years, PowerBuilder has been updated with new standards. In 2010, a major upgrade of PowerBuilder was released to provide support for the Microsoft .NET Framework.[2] In 2014, support was added for OData, dockable windows, and 64-bit native applications.[3] In 2019 support was added for rapidly creating RESTful Web APIs and non-visual .NET assemblies using the C# language and the .NET Core framework. And PowerScript client app development was revamped with new UI technologies and cloud architecture.[4] In 2025 the IDE was revamped with new code editor and ultra-fast compiler.[5]
Appeon has been releasing new features every 6-12 month cycles, which per the product roadmap focus on four key focus areas: sustaining core features, modernizing application UI, improving developer productivity, and incorporating more Cloud technology.[6]
Features
[edit]PowerBuilder has a native data-handling component called a DataWindow, which can be used to create, edit, and display data from a database. This object gives the programmer a number of tools for specifying and controlling user interface appearance and behavior, and also provides simplified access to database content and JSON or XML from Web services. To some extent, the DataWindow frees the programmer from considering the differences between Database Management Systems from different vendors. DataWindow can display data using multiple presentation styles and can connect to various data sources.
Usage
[edit]PowerBuilder is used primarily for building business-oriented CRUD applications.
Although new software products are rarely built with PowerBuilder, many client-server ERP products and line-of-business applications built in the late 1980s to early 2000s with PowerBuilder still provide core database functions for large enterprises in government,[7][8][9] higher education,[10] manufacturing, insurance, banking,[11] energy, and telecommunications.
History
[edit]Early history
[edit]PowerBuilder originated from Computer Solutions Inc. (CSI), a software consulting firm founded in 1974 by Mitchell Kertzman in Massachusetts.[12][circular reference][13] CSI developed GrowthPower, an MRP II software package with integrated financial modules released in 1981, which ran exclusively on the HP 3000 platform and achieved over 1,000 customer installations at its peak.[14]
In the late 1980s, as demand increased for graphical user interfaces amid the rise of Microsoft Windows, Kertzman partnered with Dave Litwack, former executive vice president of product development at Cullinet Software (acquired by Computer Associates in 1989).[15][16] Litwack joined the company in 1988 as head of research and development to develop a client/server GUI tool, leading to its rebranding as Powersoft Corporation in 1990.[17][18]
PowerBuilder 1.0 was released in July 1991 as a rapid application development tool featuring the DataWindow and PowerScript language.[19] Powersoft went public on February 3, 1993, with shares closing at $38 from an initial $20 price.[20]
Sybase announced its acquisition of Powersoft on November 15, 1994, in a stock swap valued at approximately $940 million; the merger closed on February 14, 1995, at a revised value of about $904 million due to Sybase's stock fluctuations.[21][22][23][24]
Recent history
[edit]In December 2013 SAP announced the new version going directly to number 15 and released a beta version.[25] Key features included support for the .NET Framework v4.5, SQL Server 2012, Oracle 12, Windows 8, OData and Dockable Windows. SAP later released this as version 12.6.
On May 31, 2019 PowerBuilder 2019 was released by Appeon. This release supports C# development. It provides a new C# IDE, .NET data access objects, C# migration solution, Web API client, and UI themes.[26]
On April 3, 2020 PowerBuilder 2019 R2 was launched by Appeon. This release includes a first-ever PowerScript-to-C# code converter, which can automatically migrate 80-95% of PowerBuilder business logic and DataWindows to C#.[27] Interoperability between PowerScript and .NET programming languages is also now supported. Many existing features have also been enhanced.
On January 22, 2021 PowerBuilder 2019 R3 was launched by Appeon. This release provides a groundbreaking new app deployment technology called PowerClient, which securely automates the installation and update of client apps over HTTPS. C# Web API development has been greatly enhanced with asynchronous programming and support for Amazon Aurora and Azure cloud databases. Aside from many other new features, PowerBuilder 2019 R3 is a long-term support (LTS) version that replaces previous LTS versions[28]
On August 6, 2021 PowerBuilder 2021 was launched by Appeon. The Cloud deployment capability of the PowerBuilder 2021 IDE, in conjunction with the matching PowerServer 2021 runtime, was revamped, bringing PowerBuilder up-to-date with the latest .NET technologies. The presentation layer now executes PowerScript natively on Windows devices. The middle-tier has been rebuilt around REST API standard with a pure .NET Core implementation. A new CI/CD utility that integrates with Git/SVN and Jenkins, witch compiles all PowerBuilder projects using the command-line interface, was added alongside other features.[29]
On September 4, 2022 PowerBuilder 2022 was launched by Appeon. This release brings enhancements to the productivity of developing both client/server & installable cloud apps and more security measures to safeguard your apps. It includes many new features, including Windows 11 support, introducing time-saving functionalities to the IDE, such as Tabbed Code Editor, Jump to Objects, and Quick Code Search, and supports the latest HTTP/2 and TLS 1.3 protocols and two-way TLS authentication.[30]
On August 4, 2023 PowerBuilder 2022 R2 was launched by Appeon. This release introduces a range of new features aimed at helping developers build powerful, feature-rich, and secure client/server and installable cloud apps more efficiently, including tabbed windows, fillable PDFs, and SMTP client.[31]
On January 8, 2024 PowerBuilder 2022 R3 was launched by Appeon. This release is a long-term support version. Features previously released in earlier releases have been enhanced and/or corrected.[32]
On May 7, 2025 PowerBuilder 2025 was launched by Appeon. This release delivers a revamped IDE that boosts developer productivity throughout the SLDC—from writing and extending code to debugging, automating builds, and deploying applications. It features a new-generation code editor, ultra-fast compiler, automatic REST API creation, faster GIT operations, and codeless UI modernization features.[5]
Features
[edit]PowerBuilder is an object-oriented programming language. Nearly all of the visual and non-visual objects support inheritance, polymorphism, and encapsulation. The programmer may utilize a common code framework such as PowerBuilder Foundation Classes, also known as PFC, to inherit objects from and leverage pre-existing code.[33]
The DataWindow is the key component (and selling point) of PowerBuilder. The DataWindow offers a visual SQL painter which supports outer joins, unions and subquery operations. It can convert SQL to visual representation and back, so the developer can use native SQL if desired. DataWindow updates are automatic — it produces the proper SQL at runtime based on the DBMS to which the user is currently connected. This feature makes it easier for developers who are not experienced with SQL.
The DataWindow also has the built-in ability to both retrieve data and update data via stored procedures or REST Web APIs as well as import/export JSON data. The RESTClient object introduced in PowerBuilder 2017 facilitates bridging the DataWindow with REST Web APIs and requiring minimal coding.[34]
RDBMS interfaces
[edit]PowerBuilder offers native interfaces to all major databases, as well as ODBC and OLE-DB, in the Enterprise version. There are many connectivity options that allow performance monitoring and tuning, such as:
- Integrated security
- Tracing of all SQL
- Isolation level
- Password expiration dialog
- Blocking factor
- Number of SQL statements to cache
- Use connection pool
- Thread safety
- Trace ODBC API calls
Due to the information about the database schema (such as primary key information) that are stored in PowerBuilder's data dictionary, the code required to implement data display and browsing is greatly simplified, because the dictionary information allows generation of the appropriate SQL behind the scenes.
PowerBuilder supports the following ways of interacting with a database:
DataWindow: this is the simplest approach, relying on automatically generated SQL.
- "Embedded SQL"
- Embedded SQL supports SELECT, INSERT, UPDATE, DELETE and cursors. This option is used when the developer desires more control than is available with the DataWindow option. Example:
UPDATE my_employee SET STATUS = 'A';
IF sqlca.sqlcode<>0 THEN ...
- "Dynamic SQL"
- This is a form of parameterized SQL, where the user builds a string that may optionally have bind variables. Dynamic SQL may be used to create cursors as well.
Integration with third-party software
[edit]PowerBuilder supports ActiveX and OCX controls, both visible and non-visible. It also can use OLE Automation as a client. However, PowerBuilder supports only late binding, not early binding. Therefore, when using OLE Automation, a dropdown of possible actions is not provided. PowerBuilder can also act as a DDE client or server, providing a further mechanism to interoperate with other applications.
PowerBuilder can make Windows and third-party API calls, and, in general, works well with third-party libraries in DLL files, however it does not directly support callback functions.
Compilation and debugging
[edit]PowerBuilder offers a "/pbdebug" (or variants: "-pbdebug", "-pbd", "/debug", "-debug", "-deb") runtime switch, which creates a log file. This can help track down a bug "in the field", as the user simply emails this log file to the developer. It has another feature which can log all SQL statements to a file. It also has built-in performance profiling, an integrated debugger, context-sensitive help, and an active newsgroup to provide support.
PowerBuilder applications are typically compiled to p-code, which is then interpreted by the PowerBuilder runtime environment. An application can also be compiled to machine code, which can sometimes offer a performance benefit.
Criticism
[edit]Extensibility of the language was rather limited for older versions of PowerBuilder. To develop a solution that includes external C++ code may not only require a competent C++ developer, but also a PowerBuilder expert to guide the developer through the myriad subtleties of the language and the PowerBuilder Virtual Machine.
Inheritance and object-oriented features are limited to some object types (Windows, Userobjects and Menus). In particular, it is not possible to inherit from a DataWindow. A PowerBuilder user cannot open a descendant and a parent at the same time in the painter, though they can see all ancestors' code while working on the descendant.
To address these criticisms, Appeon has set a new roadmap for PowerBuilder, which it publishes openly on the Appeon Website.[35] Amongst developers, the (classic) PowerScript language itself, which is still available for compatibility reasons, is known as a "language built around the DataWindow", and PowerBuilder is known as the "IDE built around the DataWindow". C# development centered around a new .NET DataWindow with automated migration of existing DataWindows was introduced in PowerBuilder 2019.[36]
Community
[edit]Since Appeon took over PowerBuilder, it has launched a new official community website for PowerBuilder developers. This community website offers technical articles, webinars, and Q&A, which are authored by community users. Appeon also hosts an annual user conference called Appeon Elevate, and recordings of the conference sessions are available from the conference website. There are a number of local user groups around the world that cooperate with Appeon to deliver abridged versions of the conference in seminar format and local language. [37]
There are also a variety of grassroots community groups and resources for PowerBuilder developers to share and convene. PowerBuilderTV[38] is series of webinars by PowerBuilder users and vendors that tend to focus on third party add-ons. PowerBuilder Central[39] is a community initiative to create a single source for third party add-ons and services.
PowerBuilder Tools
[edit]- Appeon PowerServer - Deploys existing or new PowerBuilder projects as cloud-native applications that runs on .NET Core with support for almost every single PowerBuilder feature, including the PFC framework.[40]
- Visual Expert for PowerBuilder - Visual Expert helps in sharing the knowledge of your applications. It also automates impact analysis and checks code quality.[41]
- Enable Multilingual - Enable makes PowerBuilder applications multilingual quickly and easily. Using Enable, developers can only need to make a few small changes to the original PowerBuilder code to go from monolingual to multilingual.[42]
- ProDiff for PowerBuilder - ProDiff is designed to highlight the differences between versions of PowerBuilder development source code.[43]
- Visual Guard for PowerBuilder - Visual Guard is an access control and application-level permissions tool. It helps you centralize view and control of users and their rights in PowerBuilder applications.[44]
- STD Framework for PowerBuilder - A free object-oriented development framework for PowerBuilder Classic, Web Services, Appeon PowerServer Web and Mobile.[45]
- Ultimate Suite for PB - A suite of controls, written in PowerScript, that modernizes the GUI of PowerBuilder applications; Ultimate Suite for PB gives applications a contemporary look and makes them more user-friendly.[46]
- AscentialTest - Automated testing for PowerBuilder, web, and others. Deep integration with the PowerBuilder VM api's allow AT to see and understand PB objects.
- PowerGen - Automated build and regeneration of PowerBuilder applications. Supports building directly from Source Control.[47]
References
[edit]- ^ Martin Berner (5 July 2016). "Appeon Signs Agreement with SAP to Bring Major Innovations to PowerBuilder". SAP Community Network.
- ^ "Sybase PowerBuilder tool readied for Microsoft's .Net". Sybase. 18 August 2009.
- ^ "SAP announces PowerBuilder 12.6". PB TV News. Retrieved 12 July 2023.
- ^ "PowerBuilder 2019 Press Release". Appeon.
- ^ a b "PowerBuilder 2025 Now Available for General Availability | Appeon". www.appeon.com. Retrieved 2025-07-16.
- ^ "Appeon Products Roadmap". Appeon.
- ^ "Java Vs .NET: Pros and Cons of Migrating PowerBuilder Applications To either of those Technologies". Kumaran Systems. 10 July 2023.
- ^ "PowerBuilder World Tour". powerbuilder-world-tour.com.
- ^ "Superior Court of Orange County Applications Developer I/II (Oracle/.NET) - PRIMARILY REMOTE OPPORTUNITY Job in Orange, CA". Glassdoor.[permanent dead link]
- ^ "PowerCampus™ by Ellucian". Ellucian | The leader in higher education technology.
- ^ "The Bank of New York Mellon Specialist Developer (Mainframe DB2/IMS, CICS, IMS/DC, Powerbuilder, .Net) Job in New York, NY". Glassdoor.[dead link]
- ^ "Mitchell Kertzman". Wikipedia. Retrieved July 10, 2025.
- ^ "Mitchell Kertzman - HWVP". HWVP. Retrieved July 10, 2025.
- ^ "PowerBuilder History, Powersoft History". Patrick Lannigan. Winter 2004. Retrieved July 10, 2025.
- ^ "Dave Litwack Elected to EnterpriseDB Board of Directors". EDB. August 30, 2006. Retrieved July 10, 2025.
- ^ "Company News; Computer Associates In $300 Million Deal". The New York Times. September 28, 1989. Retrieved July 10, 2025.
- ^ "Computerworld". 1991. Retrieved July 10, 2025.
- ^ "PowerBuilder History, Powersoft History". Patrick Lannigan. Winter 2004. Retrieved July 10, 2025.
- ^ "PowerBuilder History, Powersoft History". Patrick Lannigan. Winter 2004. Retrieved July 10, 2025.
- ^ "The IPO that roared". ProQuest 196906205. Retrieved July 10, 2025 – via ProQuest.
- ^ "Sybase To Acquire Powersoft". The New York Times. November 15, 1994. Retrieved July 10, 2025.
- ^ "Sybase to Buy Powersoft for $940 Million". Los Angeles Times. November 15, 1994. Retrieved July 10, 2025.
- ^ "COMPANY NEWS; SYBASE COMPLETES PURCHASE OF POWERSOFT". The New York Times. February 14, 1995. Retrieved July 10, 2025.
- ^ "PowerBuilder History, Powersoft History". Patrick Lannigan. Winter 2004. Retrieved July 10, 2025.
- ^ "PowerBuilder 15 beta is here!". sap.com.
- ^ "PowerBuilder 2019 Press Release". Appeon.
- ^ "PowerBuilder 2019 R2 Press Release". Appeon.
- ^ "PowerBuilder 2019 R3 Press Release". Appeon.
- ^ "Appeon Releases PowerBuilder 2021 with Revamped Cloud Deployment | Appeon Website". www.appeon.com. Retrieved 2022-09-12.
- ^ "Appeon Releases PowerBuilder 2022 | Appeon Website". www.appeon.com. Retrieved 2022-09-12.
- ^ "Appeon Releases PowerBuilder 2022 R2 | Appeon Website". www.appeon.com.
- ^ "Appeon Releases PowerBuilder 2022 R3 | Appeon Website". www.appeon.com.
- ^ "EHS | Health & Safety | Quality Management Software | Intelex".
- ^ "RESTClient Tutorial - Calling Web APIs". Appeon.
- ^ "PowerBuilder Roadmap". Appeon.
- ^ "PowerBuilder .NET API Reference". Appeon.
- ^ "PowerBuilder User Group Meeting in Germany". Appeon. Archived from the original on 2017-12-22. Retrieved 2024-11-19.
- ^ "PowerBuilderTV".
- ^ "PowerBuilder Central - About Us". powerbuildercentral.com.
- ^ "Appeon PowerServer Product Page". Appeon.
- ^ "Visual Expert Product Page". Novalys.
- ^ "Enable Multilingual Product Page". Novalys.
- ^ "ProDiff Product Page". PBDR Ltd.
- ^ "Visual Guard Product Page". Novalys.
- ^ Chris Pollach. "STD Framework Download Page".
- ^ "PB Ultimate Suite Product Page". Novalys.
- ^ "PowerGen Overview".
External links
[edit]PowerBuilder
View on GrokipediaHistory
Origins and Early Development
Powersoft Corporation, originally founded in 1974 as Computer Systems Integrators by Mitchell Kertzman, shifted its focus in 1988 toward developing client-server application tools amid the rising popularity of personal computers and Windows environments.[10] This pivot led to the creation of PowerBuilder, a pioneering rapid application development (RAD) platform designed to streamline the building of database-driven applications. By leveraging visual programming paradigms, Powersoft aimed to empower developers to create robust client-server solutions without extensive manual coding, targeting the growing demand for SQL-integrated business software.[11] PowerBuilder 1.0 was released on July 1, 1991, marking a significant advancement in Windows-based development by introducing intuitive visual painters for designing forms and reports, alongside native SQL support for database connectivity.[12] A cornerstone feature was the debut of the DataWindow technology, a declarative control that enabled seamless binding of data from relational databases to user interfaces, allowing developers to generate dynamic reports and editable grids with minimal scripting. This RAD approach, combined with PowerScript—a proprietary event-driven language—positioned PowerBuilder as an efficient tool for enterprise applications, quickly gaining traction among developers transitioning from mainframes to distributed systems.[13] Subsequent releases built on this foundation, with PowerBuilder 2.0, launched in June 1992, further enhanced the platform by introducing object-oriented inheritance for reusable components and expanded database interfaces, including improved support for SQL Server and Oracle. These updates facilitated more scalable and modular application design, solidifying PowerBuilder's role in team-based development.[14] Powersoft experienced rapid growth during this period, selling over 8,000 copies of PowerBuilder by early 1993 and projecting $25 million in revenue for 1992, which underscored its emergence as a market leader in fourth-generation language (4GL) tools for client-server environments.[13] The company's successful initial public offering on February 3, 1993, raised $71 million at $20 per share, with stock nearly doubling on the first trading day, reflecting strong investor confidence in PowerBuilder's innovative ecosystem.[15] This financial milestone enabled further investment in the product's evolution, setting the stage for broader enterprise adoption.Sybase Ownership Period
In November 1994, Sybase announced its acquisition of Powersoft Corporation, the creator of PowerBuilder, in a stock swap valued at approximately $940 million. The merger closed in February 1995, positioning PowerBuilder as a key component of Sybase's client-server ecosystem by enabling seamless integration with Sybase databases like Adaptive Server Enterprise for rapid development of database-driven applications. This move expanded PowerBuilder's reach, allowing Sybase to offer end-to-end solutions for enterprise computing, where PowerBuilder served as the front-end development tool complementing Sybase's backend database technologies.[5][4] During the Sybase era, PowerBuilder underwent significant technical advancements through major version releases that enhanced its enterprise capabilities. Version 5.0, released in 1996, introduced the PowerBuilder Foundation Classes (PFC) library, a set of reusable object-oriented components that accelerated development by providing pre-built services for data management, error handling, and user interface consistency. Subsequent releases built on this foundation: version 6.0 in 1997 previewed web deployment options and included integration with Power++ Enterprise for C++ code generation, while version 9.0 in 2003 added robust XML support for data exchange in distributed environments. The lineup culminated in version 12.5 in 2011, which incorporated .NET framework compatibility for hybrid applications and migrated the IDE to the Eclipse platform for improved extensibility and plugin support.[16][17][18][19] Sybase emphasized enterprise-grade features to address distributed computing needs, such as the integration of Jaguar Component Transaction Server (CTS) in 1998, which enabled scalable n-tier architectures using CORBA for component-based deployment of PowerBuilder applications. This allowed developers to build and manage server-side components that interfaced with PowerBuilder clients, supporting high-volume transaction processing in multi-tier setups. Despite these innovations, PowerBuilder faced market challenges in the late 1990s from emerging Java-based tools, which gained traction for cross-platform web applications amid the dot-com boom. Nevertheless, PowerBuilder maintained strong adoption in financial services and government sectors, where its reliability for mission-critical, database-intensive applications proved enduring, powering systems at organizations like major banks and federal agencies.[20][21][22][23][24]SAP Acquisition and Appeon Partnership
In 2010, SAP acquired Sybase for $5.8 billion, bringing PowerBuilder into its portfolio as a key tool for enterprise application development.[25] This move integrated PowerBuilder's client-server capabilities with SAP's broader ecosystem, emphasizing its role in building scalable business applications.[26] Under SAP's ownership, PowerBuilder saw the release of version 12.6 in 2014, which introduced OData support, 64-bit applications, and expanded platform compatibility including Oracle 12c.[27] However, direct investment in PowerBuilder declined as SAP prioritized its proprietary tools, such as SAPUI5 and Fiori, leading to version 12.6 as the final major release from SAP and a shift away from active innovation in the product.[28] In 2016, SAP entered a licensing agreement with Appeon, granting the company rights to develop, sell, and innovate PowerBuilder, ensuring its continued evolution beyond SAP's primary focus.[7] Appeon subsequently released version 2017 in June 2017, which added support for RESTful APIs to enable modern web services integration, followed by version 2019 in May 2019 with C# development support, version 2021 in December 2021 enhancing security and productivity, and version 2022 in September 2022 introducing long-term support features and IDE improvements.[9] Appeon's stewardship has emphasized modernization, particularly through PowerServer, a cloud deployment platform that allows PowerBuilder applications to run as web and mobile apps while preserving backward compatibility with legacy codebases built on earlier versions like 12.6.[29] In 2025, PowerBuilder received significant updates with version 2025 released on May 7, 2025, including a revamped integrated development environment (IDE) with a new code editor for enhanced productivity, an ultra-fast multi-threaded compiler, automatic REST API generation from DataWindows, and codeless UI theming options to simplify interface customization. A maintenance release followed on November 12, 2025, adding high DPI support and improved PostgreSQL connectivity via ADO.NET.[30][31] These advancements position PowerBuilder for contemporary enterprise needs, such as cloud-native scalability, without disrupting existing deployments.[32]Core Components
PowerScript Programming Language
PowerScript is a high-level, event-driven programming language integral to PowerBuilder, designed to facilitate rapid application development by blending procedural and object-oriented paradigms with a syntax reminiscent of BASIC.[33] It enables developers to write scripts that respond to user interactions and system events, supporting both standalone procedural code and integration within an object-oriented framework.[33] At its core, PowerScript employs event-driven programming where scripts are associated with specific events on controls and objects. For instance, theclicked() event triggers when a user clicks a button, allowing code to execute in response, such as validating input or updating displays.[34] Similarly, the open() event fires upon the initialization of a window or menu, providing an opportunity to set initial properties or load data.[35] This mechanism supports over 149 predefined events, each with arguments like coordinates or return codes to inform the script of contextual details.[36]
PowerScript includes built-in system objects that simplify common operations. The Message object captures details of Windows events not natively defined in PowerBuilder, such as low-level system notifications, enabling custom handling of mouse movements or keyboard inputs. The Transaction object serves as the communication link between the application and databases, managing connections, SQL execution, and error states through properties like SQLCode and SQLErrText.
The language supports a range of standard data types to handle diverse data needs. Blobs store unbounded binary data, such as images or raw files, without size limits beyond memory constraints.[37] Date types represent calendar dates from the year 1000 to 3000, using literals in YYYY-MM-DD format (e.g., 2001-12-25).[37] Decimal types accommodate signed numbers with up to 28 digits of precision, ideal for financial calculations, with literals like 12.34 or -6500.[37] Other types include booleans for true/false logic, bytes for 8-bit unsigned integers (0-255), characters for single Unicode symbols, and strings for variable-length text up to approximately 1 GB.[37]
Control structures in PowerScript provide familiar constructs for logic and flow. Conditional execution uses IF...THEN...ELSEIF...ELSE...END IF to branch based on boolean expressions.[38] Loops include FOR for fixed iterations (e.g., FOR i = 1 TO 10), DO WHILE for condition-based repetition until false, and DO UNTIL for continuation until a condition holds true.[38] Exception handling employs TRY...CATCH...FINALLY...END TRY to gracefully manage runtime errors, with the CATCH block processing specific exceptions and FINALLY ensuring cleanup regardless of success.[38]
PowerScript integrates seamlessly with SQL for database interactions, supporting both embedded and dynamic approaches. Embedded SQL allows direct inclusion of statements like SELECT, INSERT, UPDATE, and DELETE within scripts, using colon-prefixed variables (e.g., INSERT INTO EMPLOYEE (SALARY) VALUES (:Sal_var);) to bind PowerScript variables to SQL parameters.[39] Indicator variables, such as :IndVar1, detect nulls (-1) or conversion errors (-2), enhancing data integrity.[39] For flexibility, dynamic SQL uses cursors declared with DECLARE Emp_cur CURSOR FOR SELECT... and manipulated via OPEN, FETCH, and CLOSE statements, or stored procedures invoked with DECLARE...PROCEDURE FOR and EXECUTE.[39] These operations typically leverage the Transaction object for connection management.[39]
Introduced with PowerBuilder 1.0 in 1991 as a basic scripting tool for client-server applications, PowerScript has evolved to support modern development needs, with enhancements in later versions focusing on improved syntax flexibility, array handling, and integration capabilities.[40] By PowerBuilder 12.0, it incorporated array enhancements for better .NET compatibility, and recent releases like 2025 introduce new functions in the Application object for cloud-specific tasks, such as cookie management in installable cloud apps, alongside refined error handling in runtime environments.[40][41]
Object-Oriented Framework
PowerBuilder employs a class-based object-oriented programming model that enables developers to create modular and reusable applications through inheritable classes such as windows, menus, user objects, and controls. These classes encapsulate both data and behavior, allowing for the construction of complex systems with a focus on maintainability and extensibility. Visual classes like windows and menus support user interface components, while user objects and controls provide building blocks for custom functionality, all inheriting from system-defined ancestors to promote code reuse.[42] The inheritance hierarchy in PowerBuilder is structured around ancestor-descendant relationships, where descendant objects can extend or modify ancestor behaviors through method overriding and polymorphism achieved via dynamic dispatching. Developers can create a chain of inheritance, for instance, deriving a custom window from a standard window ancestor and then further specializing it in subsequent descendants, ensuring consistent implementation across the application. Polymorphism allows functions with the same name to exhibit different behaviors based on the object type or inheritance level, supporting both operational polymorphism (via function overloading) and inclusional polymorphism (through inheritance). This mechanism facilitates flexible, type-safe code that adapts at runtime.[42] Encapsulation is enforced through access modifiers—private, protected, and public—along with properties that enable data hiding and controlled interaction between objects. Private and protected members restrict direct access to internal state, exposing only necessary interfaces via public methods or properties, which helps maintain object integrity and reduce coupling in large applications. For example, a user object might define private instance variables for sensitive data, accessible only through public getter and setter functions, promoting the principle of information hiding.[42] Non-visual objects, such as standard class user objects and custom non-visual user objects, are designed to encapsulate business logic and services without a graphical interface, allowing for the separation of concerns in application design. These objects handle tasks like data processing, transaction management, and validation, often instantiated dynamically to support modular architectures. Complementing this, global functions serve as utility methods accessible across the application, providing shared operations without the overhead of object instantiation.[42] The PowerBuilder Foundation Class (PFC) library extends the core object-oriented framework by offering a collection of reusable, inheritable classes and services that implement standardized patterns for common application needs, including error handling and security. Developed originally by Sybase, PFC includes concrete objects for windows and data services, as well as abstract service classes that can be inherited and customized, ensuring consistent error propagation through exception services and role-based access control via security services. This framework leverages PowerBuilder's inheritance and encapsulation to reduce development time while enforcing best practices for robust, scalable applications.[43]DataWindow Technology
The DataWindow serves as PowerBuilder's core technology for handling data presentation, manipulation, and reporting, functioning as a composite control that integrates a data source—typically SQL queries or stored procedures—with various presentation styles and embedded scripting capabilities. A DataWindow object defines the layout and logic, including the data retrieval syntax and visual elements like columns, labels, and graphics, while the DataWindow control embeds this object into a window or user interface for runtime interaction. This separation allows developers to design reusable objects in the DataWindow painter and associate them with controls via PowerScript, enabling dynamic data handling without custom coding for basic operations. Data binding in the DataWindow occurs through methods like Retrieve, which fetches rows from the database using specified arguments to parameterize queries, such as filtering by user input or date ranges. Updates are managed via the Update method, which applies changes from the DataWindow's buffers—primary for current data, filter for temporary subsets, and delete for removed rows—generating SQL statements with WHERE clauses to target only modified records and prevent overwriting unrelated data. This buffering mechanism supports offline editing by storing changes locally until explicitly committed, reducing database round-trips and enhancing performance in disconnected scenarios.[44][45] Built-in presentation styles include Grid for editable tabular views, Tabular for fixed reports, and Graph for visual summaries, each customizable with expressions for computed fields that derive values like sums or concatenations from other columns. Validation rules enforce data integrity using boolean expressions, such as checking numeric ranges or required fields, while conditional formatting applies styles like bold text or color changes based on data values, all defined in the DataWindow painter without external code. These features leverage PowerScript for runtime adjustments, allowing expressions likeIf(GetItemNumber(1) > 100, "High", "Low") in computed fields.
Export and import functionalities enable seamless data exchange, with the SaveAs method supporting formats like PDF for printable reports and Excel for spreadsheet integration. PowerBuilder 2025 introduces the SaveDisplayedDataAs method, which exports displayed data values (such as formatted text from Edit columns) to Excel, though without support for advanced visual elements like fonts, borders, or graphical objects.[46] ImportFile loads data from CSV, tab-delimited text, or Excel files via OLE automation, populating the DataWindow buffers for further manipulation. For visualization, the Graph style integrates charts like bar or pie representations directly from DataWindow data, with options to customize axes and legends through properties.
Advanced capabilities extend the DataWindow's versatility, including the Crosstab style for dynamic pivot tables that aggregate data across rows and columns based on runtime values, and Freeform layouts for flexible, label-adjacent designs suitable for forms or invoices. In PowerBuilder 2025, enhancements include improved update property persistence, where settings in the Specify Update Properties dialog are retained when modifying updatable tables in DataWindow SQL (e.g., adding or deleting columns), helping prevent data loss during migrations, alongside enhanced high-DPI support for the UI including DataWindow controls, though with limitations such as potential blurriness in bitmap images and sizing issues during dynamic DPI changes.[47][48] These features can be extended via the object-oriented framework by inheriting from base DataWindow objects to customize behaviors like event handling.
