Welcome
Welcome to <strong>Sybase Philippines</strong>.

You are currently viewing our boards as a guest, which gives you limited access to view most discussions and access our other features. By joining our free community, you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content, and access many other special features. Registration is fast, simple, and absolutely free, so please, <a href="/profile.php?mode=register">join our community today</a>!

Datawindow (Filter)

Updated with the latest technology, this powerful, industry-leading rapid application development tool offers tight integration between design, modeling, development and management. PowerBuilder enables developers to build anything from two-tier and Web applications to applications for a distributed architecture.

Datawindow (Filter)

Postby paul on Sat May 24, 2008 6:12 am

hi to all PB programmers:

In datawindow, how can i filter all the data with a month of january and with the year 2001 (regardless of days specified) if the selected criteria for Month is January and for Year is 2001.Assuming the equivalent
value for January is 1.

the data that was retrieve in the datawindow are:

Date
02/04/2007
01/08/2001
02/05/2004
01/09/2001
01/12/2001


and the output that i want should be look like this:

Date
01/08/2001
01/09/2001
01/12/2001

tnx in advance..
paul
 
Posts: 2
Joined: Mon Nov 26, 2007 12:50 pm

Postby crvinodraja on Mon May 26, 2008 7:28 am

Call an event with something like this:

String ls_filter

//supposing the column with the date is called "some_date"
//also assuming that some_date is of date or datetime type
ls_filter = "Year( some_date ) = 2001 AND Month( some_date ) = 1"

dw_test.SetFilter( ls_filter )
dw_test.Filter( )
crvinodraja
 
Posts: 1
Joined: Mon May 26, 2008 7:26 am


Return to PowerBuilder

Who is online

Users browsing this forum: No registered users and 0 guests

cron