You are currently browsing the Programming category

Easy ANSI Join Conversion

Posted on July 26, 2010 at 8:10 pm in

Like many MS SQL users way back when I learned the standard syntax for selectstatements: SELECT customer.custId , customer.custName , address.addrType , address.addrAddress1 , address.addrSddress2 , csz.cszCity , csz.cszState , csz.cszZip , order.ordOrderNo , order.ordOrderDate , order.partId , part.partDesc FROM customer , address , csz , order , part WHERE address.custId = customer.custId AND csz.cszId…

Easy ANSI Join Conversion - the full story »

Tools I use to get my work done.

Posted on July 20, 2010 at 8:22 pm in

This is a listing of the tools I use frequently at my job to get things done faster and more effectively. Notepad++ (www.notepad-plus-plus.org) – editorA great open source editor with great deal of customization and functionality built in.  Might as well get the ‘Poor Mans SQL Formatter’ plug in while you are at it. SSMS…

Tools I use to get my work done. - the full story »

PowerBuilder ‘Gotcha’ – Datawindow retrieval arguments

Posted on July 16, 2010 at 8:22 pm in

So I’m working on a scheduling process and I have a datawindow object which takes a number of arguments.I have them set up as al_pro_id (long), adt_end (datetime), adt_start (datetime), al_resource_id[] (long array), and al_dept_id (long). To save from maintaining two separate objects, I used this object for a datawindow as well as for datastores…

PowerBuilder ‘Gotcha’ – Datawindow retrieval arguments - the full story »

PowerBuilder – ‘Plug in’ Applications

Posted on July 9, 2010 at 8:38 pm in

I helped develop a special order processing application which was both a stand alone application as well as a ‘plug in’ into a couple of existing apps. By ‘plug in’ I mean the same windows and functionality was brought into the existing applications without any significant changes. Part of the trick in doing this is…

PowerBuilder – ‘Plug in’ Applications - the full story »

PowerBuilder – Method to add minutes to a Datetime

Posted on July 7, 2010 at 8:20 pm in

This is a method to add any number of minutes to a datetime to obtain a second datetime. Although not as ‘elegant’ as the SQL Server cursor methods, it does avoid any database calls. global type f_add_time_to_datetime from function_object end type forward prototypes global function datetime f_add_time_to_datetime (datetime adtm_start, long al_minutes) end prototypes global function…

PowerBuilder – Method to add minutes to a Datetime - the full story »

PowerBuilder & MS SQLServer datetime methods

Posted on July 6, 2010 at 8:37 pm in

If you have scheduling functionality in your application sooner or later you are faced with spanning dates. By this I mean starting something on one day and ending it on another. Powerbuilder is not very good at this, especially if you have something which starts before midnight and ends after midnight. SQL Server provides good…

PowerBuilder & MS SQLServer datetime methods - the full story »

PowerBuilder ‘Gotcha’ – dddw Edit Type

Posted on July 2, 2010 at 8:20 pm in

Be careful when you change the columns in a datawindow object referenced in another datawindow object when using the DropDownDatawindow Edit Type.  If you change the column name which is referenced in the DDDW Edit Type of another you won’t get a compile error when saving – but you will get runtime errors.  This happened…

PowerBuilder ‘Gotcha’ – dddw Edit Type - the full story »

Comment on PowerBuilder ‘Gotcha’ – dddw Edit Type »

PowerBuilder – Simple datawindow column sort by click

Posted on July 1, 2010 at 8:20 pm in

This sample is for sorting the rows in a grid datawindow ascending or descending based on the user clicking the column header. It only allows for a single column sort at a time. //Clicked event of datawindow // You need an instance variable (string is_sort_column) // This script first checks to see if we've clicked…

PowerBuilder – Simple datawindow column sort by click - the full story »

Frogpond – A Child’s Game

Posted on June 22, 2010 at 8:20 pm in

I created this simple game in PowerBuilder as an intellectual exercise as well as to give to my kids.  This first version is very basic – you move the frog around to eat the flies. I plan on enhancing it as time permits. Instructions are included in a text file included in the Zip archive.…

Frogpond – A Child’s Game - the full story »

PowerBuilder ‘Gotcha’ – pbm_dwnmousemove

Posted on June 22, 2010 at 8:20 pm in

If you are using ancestry in your application (and who doesn’t unless it’s really, really, really simple) verify that there isn’t an event mapped to pbm_dwnmousemove (or any other event ID for that matter).  If there is an ancestor event mapped to this and it has no code you will be able to create a…

PowerBuilder ‘Gotcha’ – pbm_dwnmousemove - the full story »

Top