Programming / SQL


Prompted SQL DDL Creation PDF Print E-mail
Programming - SQL
Written by Sam Lennon   
Wednesday, 01 February 2012 00:00

Not familiar with SQL CREATE TABLE syntax? No problem! There's a really easy way to create SQL DDL (Data Definition Language) statements.

sam_lennonWritten by Sam Lennon

IBM i developers are becoming more comfortable exploiting the power of SQL to retrieve and manipulate data. We regularly use the workhorse SELECT, UPDATE, and DELETE statements and can bang them out quickly with minimal syntax errors. Defining tables, indexes, constraints, and the like occurs less frequently, and consequently we are much less accomplished in the syntax.

Add a comment
Last Updated on Wednesday, 01 February 2012 00:00
Read more...
 
User Rating: / 7
PoorBest 
Get the Day of the Week, Full Text Date Values, and More Within RPG Using SQL PDF Print E-mail
Programming - SQL
Written by Thomas Snyder   
Wednesday, 18 January 2012 00:00

Create useful date-centric service programs with embedded SQL.

tom_snyderWritten by Tom Snyder

Welcome to 2012! All of our year-end processes are complete, and it's the beginning of a new year with a clean slate. 2011 was a very clean year date-wise because it ended on a Saturday. Typically, there is always special handling with the last week of the year for one reason or the other, which makes working with data a prevalent topic. For this article, I wanted to share a few handy little SQL functions that I've put into service programs to extend the existing RPG date resources. And this is all done with very minimal code in a reliable way that is highly reusable.

Add a comment
Last Updated on Wednesday, 18 January 2012 00:00
Read more...
 
User Rating: / 9
PoorBest 
What Are the Differences Between DB2 for i and SQL Server SQL Syntax? PDF Print E-mail
Programming - SQL
Written by Michael Sansoterra   
Wednesday, 11 January 2012 00:00

Avoid headaches and wasted time by learning the major differences between DB2 for i and T-SQL dialects.

Written by Michael Sansoterra

It's apparent by emails I've received that some SQL Server developers are having an opportunity to delve into the DB2 for i realm. Even though SQL would ideally be a platform-neutral, standards-based language, the truth is there are many SQL syntax and feature differences among the major database providers.

Add a comment
Last Updated on Monday, 09 January 2012 13:09
Read more...
 
User Rating: / 8
PoorBest 
Practical SQL: UDFs and Service Programs, Part II PDF Print E-mail
Programming - SQL
Written by Joe Pluta   
Wednesday, 07 December 2011 00:00

With a little creativity, SQL allows you to add a form of overloading to RPG that can really extend your toolkit.

joe_plutaWritten by Joe Pluta

In the previous article in this series, I created a simple user-defined function (UDF) that acted as an SQL interface to an RPG service program procedure. It was simple and easy to do, but the emphasis was on simple. The UDF simply passed parameters from the SQL environment straight through to the RPG procedure and returned the result. This is enough in many cases, but at other times, you might want a little more flexibility.

Add a comment
Last Updated on Monday, 05 December 2011 11:27
Read more...
 
User Rating: / 3
PoorBest 
Practical SQL: UDFs and Service Programs, Part I PDF Print E-mail
Programming - SQL
Written by Joe Pluta   
Wednesday, 02 November 2011 00:00

In this installment of our continuing series on using SQL in real business applications, we introduce the concept of invoking service programs from within SQL.

joe_plutaWritten by Joe Pluta

We continue to provide you with examples of integrating SQL with traditional RPG. In this article, we're going to focus on how we can use a service program to extend SQL and provide an essential feature that SQL is sorely lacking: converting binary data in a character field to numeric values. Note that this is the opposite of something like the HEX function, which returns the hexadecimal representation of a field. This function will take some alphanumeric data, either in packed or binary form, and return the numeric value the data represents. This practical extension to SQL can be used by any shop.

Add a comment
Last Updated on Wednesday, 02 November 2011 00:00
Read more...
 
User Rating: / 2
PoorBest 
Practical SQL: Three Ways to JOIN PDF Print E-mail
Programming - SQL
Written by Joe Pluta   
Wednesday, 05 October 2011 00:00

JOINing tables is one of the fundamental tasks in SQL, and this article explains three basic syntactical approaches.

joe_plutaWritten by Joe Pluta

SQL is the tool of choice for querying relational data, and the whole idea behind relational data is that the tables are related. What this means is that a common field in two tables can be used to tie rows from each table together into a coherent set of data. In SQL, this is performed via the JOIN, which has three distinct syntactical variations. This article will explain the differences, including a recent change that might catch you unaware.

Add a comment
Last Updated on Wednesday, 05 October 2011 00:00
Read more...
 
User Rating: / 4
PoorBest 
Practical SQL: Calling RPG from SQL, Part II PDF Print E-mail
Programming - SQL
Written by Joe Pluta   
Wednesday, 04 May 2011 00:00

This second article on combining the strengths of RPG and SQL shows how to turn a stored procedure into a user-defined function (UDF).

joe_plutaWritten by Joe Pluta

In my previous article, I showed you how to create a stored procedure that will invoke an RPG program (or COBOL or CL or any other program, ILE or non-ILE). I also showed you how to test it and even explained the primary shortcoming of stored procedures: they can't be used in SELECT statements. I explained that in order to use external business logic inside of a SELECT statement, you need to use the other SQL extension technique, the user-defined function (UDF). This article shows how to create a UDF that uses your stored procedure.

Add a comment
Last Updated on Wednesday, 04 May 2011 00:00
Read more...
 
User Rating: / 8
PoorBest 
Practical SQL: Calling RPG from SQL, Part I PDF Print E-mail
Programming - SQL
Written by Joe Pluta   
Wednesday, 06 April 2011 00:00

This first article on combining the strengths of RPG and SQL focuses on defining and testing stored procedures.

joe_plutaWritten by Joe Pluta

SQL and RPG are powerful and complementary tools. SQL does things well that are difficult or nearly impossible in RPG and vice versa. The trick is to develop programming strategies that take advantage of both. IBM recognized this and created the potent embedded RPG tooling, which allows you to easily take advantage of SQL from within RPG programs. This article is going to focus on the related technique of calling RPG from within SQL.

Add a comment
Last Updated on Wednesday, 06 April 2011 00:00
Read more...
 
User Rating: / 7
PoorBest 
<< Start < Prev 1 2 3 4 5 6 7 8 9 10 Next > End >>

Page 6 of 16

WEBCAST

MC Webcast CenterFEATURED WEBCAST

See What i Can Do With Modern RPG Development

Your applications deserve more than just a new look! Change the perception of the IBM i as “old” with modern development tips from IBM and Profound Logic Software.
Watch as Barbara Morris, Brian May and Alex Roytman dive beneath the GUI surface to show the benefits of:

 

  • Working with free-format RPG in IBM i TR7
  • Breaking free from “The Cycle” of traditional RPG development
  • Going beyond the 10 character limit in display and database files
  • And more!

You'll also see a live demonstration of these techniques as the presenters create a modern web application before your eyes! 

 

Watch the Webinar Now!

 

TRIAL SOFTWARE

MS Office Connector for Query/400

NGS' Qport Office enables Windows users to run IBM Query/400 queries to: 

 - Create and update Excel spreadsheets and Access databases

 - Create Word documents

 - Send to Windows screen and PC printers

No query conversion is required. Works with i5/OS V5R1 & above. Installs in minutes!

If you don’t have a budget to replace IBM Query/400, but want your users to have one click enhanced output of their queries.… Request the online license agreement and product download instructions today!

Offer good through December 31, 2013.

   MC-STORE.COM