Dddw and retrieve

Hi everyone,

    I have a problem retrieving a record. Here's my scenario:

    I have a DW that has a dddw on the key column (employee id). When I
select an emp. ID from the dddw, it displays the right info in the
remaining entries. Outside the DW I have 4 picture buttons from
retrieving the records in the DW (first, previous, next and last). My
problem is right there - when I use these buttons it does not display
the employee info although it goes through the table (I see this in the
debugger). Any ideas?

Thanks,
Marina

0
Marina
11/13/1998 4:40:34 PM
sybase.powerbuilder.datawindow 28057 articles. 4 followers. Follow

8 Replies
351 Views

Similar Articles

[PageSpeed] 47

In article <364C6101.2F38F5DF@bellatlantic.net>, msadiko@bellatlantic.net 
says...
> Hi everyone,
> 
>     I have a problem retrieving a record. Here's my scenario:
> 
>     I have a DW that has a dddw on the key column (employee id). When I
> select an emp. ID from the dddw, it displays the right info in the
> remaining entries. 

Keep in mind that by having a dddw on a key that you are changing the 
current record not the entire record. It is the same as changing any 
other field. You will need to code in the itemchanged to move to a new 
record. 

In any case, I would suggest not allowing the user to change a key field. 
Not sure why you would do that.

Mark

-- 
Mark J. Pfeifer        Corporate Technology Partners, Inc.
Team Powersoft            Emerging Technology Solutions
mpfeifer@ sprynet.com           www.ctpartners.com

       "The first one was only the beginning!"
0
see_msg
11/13/1998 11:02:11 PM
Thanks Mark for your response. My problem is outside the DW where I have the
dddw. Namely, I have 4 picture buttons to access the first record, previous,
next and the last record in the DW. I have an instance variable called
index_no, which contains the row number of the selected row in the dddw. The
problem is displaying the info for that row, although the index_no contains
the correct row number (I see this in the debbuger). How can I display info
in a dddw outside the DW?

Thanks,
Marina

Mark J. Pfeifer wrote:

> In article <364C6101.2F38F5DF@bellatlantic.net>, msadiko@bellatlantic.net
> says...
> > Hi everyone,
> >
> >     I have a problem retrieving a record. Here's my scenario:
> >
> >     I have a DW that has a dddw on the key column (employee id). When I
> > select an emp. ID from the dddw, it displays the right info in the
> > remaining entries.
>
> Keep in mind that by having a dddw on a key that you are changing the
> current record not the entire record. It is the same as changing any
> other field. You will need to code in the itemchanged to move to a new
> record.
>
> In any case, I would suggest not allowing the user to change a key field.
> Not sure why you would do that.
>
> Mark
>
> --
> Mark J. Pfeifer        Corporate Technology Partners, Inc.
> Team Powersoft            Emerging Technology Solutions
> mpfeifer@ sprynet.com           www.ctpartners.com
>
>        "The first one was only the beginning!"



0
Marina
11/16/1998 3:23:53 PM
In article <36504389.8932D704@bellatlantic.net>, msadiko@bellatlantic.net 
says...
> Thanks Mark for your response. My problem is outside the DW where I have the
> dddw. Namely, I have 4 picture buttons to access the first record, previous,
> next and the last record in the DW. I have an instance variable called
> index_no, which contains the row number of the selected row in the dddw. The
> problem is displaying the info for that row, although the index_no contains
> the correct row number (I see this in the debbuger). How can I display info
> in a dddw outside the DW?
> 
> Thanks,
> Marina

I am lost. How can you have the DDDW outside the dw?  Not sure what you 
need?

Mark

-- 
Mark J. Pfeifer        Corporate Technology Partners, Inc.
Team Powersoft            Emerging Technology Solutions
mpfeifer@ sprynet.com           www.ctpartners.com

       "The first one was only the beginning!"
0
see_msg
11/17/1998 2:49:57 AM
I'm sorry for the confusion, but I'll try and explain what I have.

I have a DW called dw_user_data which accesses the employee table. One of the
columns in that DW, the user_id column, is set to be a dddw. When I select a user
id from the dddw, the rest of the info for that user id is displayed in the
remaining entries of the dw_user_data (first and last name etc).

Outside the DW, I have 4 picture buttons for 'first', 'previous' record (arrow
pointing to the left), then 'next', 'last' record (arrow pointing to the right).
When I click, say 'next' button, I want to retrieve and display next record from
employee table into my DW (next record is relative to the current record). When I
debug, I see I get the right info for the next record, but I cannot display it in
my DW. That's my problem.. I hope this is clearer than the previous message. Thank
you for your efforts in trying to help me.

Marina

Mark J. Pfeifer wrote:

> I am lost. How can you have the DDDW outside the dw?  Not sure what you
> need?
>
> Mark
>
> --
> Mark J. Pfeifer        Corporate Technology Partners, Inc.
> Team Powersoft            Emerging Technology Solutions
> mpfeifer@ sprynet.com           www.ctpartners.com
>
>        "The first one was only the beginning!"



0
Marina
11/17/1998 7:15:03 PM
What process are you doing to display the data when the user selects the
DDDW entry, and what process are you doing in the 'Next' button?  Where are
you seeing the next record when you debug?

Marina Sadikoska <msadiko@bellatlantic.net> wrote in article
<3651CB37.477F1C04@bellatlantic.net>...
> I'm sorry for the confusion, but I'll try and explain what I have.
> 
> I have a DW called dw_user_data which accesses the employee table. One of
the
> columns in that DW, the user_id column, is set to be a dddw. When I
select a user
> id from the dddw, the rest of the info for that user id is displayed in
the
> remaining entries of the dw_user_data (first and last name etc).
> 
> Outside the DW, I have 4 picture buttons for 'first', 'previous' record
(arrow
> pointing to the left), then 'next', 'last' record (arrow pointing to the
right).
> When I click, say 'next' button, I want to retrieve and display next
record from
> employee table into my DW (next record is relative to the current
record). When I
> debug, I see I get the right info for the next record, but I cannot
display it in
> my DW. That's my problem.. I hope this is clearer than the previous
message. Thank
> you for your efforts in trying to help me.
> 
> Marina
> 
> Mark J. Pfeifer wrote:
> 
> > I am lost. How can you have the DDDW outside the dw?  Not sure what you
> > need?
> >
> > Mark
> >
> > --
> > Mark J. Pfeifer        Corporate Technology Partners, Inc.
> > Team Powersoft            Emerging Technology Solutions
> > mpfeifer@ sprynet.com           www.ctpartners.com
> >
> >        "The first one was only the beginning!"
> 
> 
> 
> 
0
J
11/17/1998 7:16:25 PM
In article <3651CB37.477F1C04@bellatlantic.net>, msadiko@bellatlantic.net 
says...
> I'm sorry for the confusion, but I'll try and explain what I have.
> 
> I have a DW called dw_user_data which accesses the employee table. One of the
> columns in that DW, the user_id column, is set to be a dddw. When I select a user
> id from the dddw, the rest of the info for that user id is displayed in the
> remaining entries of the dw_user_data (first and last name etc).
> 
> Outside the DW, I have 4 picture buttons for 'first', 'previous' record (arrow
> pointing to the left), then 'next', 'last' record (arrow pointing to the right).
> When I click, say 'next' button, I want to retrieve and display next record from
> employee table into my DW (next record is relative to the current record). When I
> debug, I see I get the right info for the next record, but I cannot display it in
> my DW. That's my problem.. I hope this is clearer than the previous message. Thank
> you for your efforts in trying to help me.
> 
> Marina
> 

Again, I would not assign a few field to be a DDDW. I would display the 
names in a list on the left and then the details on the right. 

With that said...  What methods are you using to navigate the DW from the 
buttons and the DDDW?

Mark

-- 
Mark J. Pfeifer        Corporate Technology Partners, Inc.
Team Powersoft            Emerging Technology Solutions
mpfeifer@ sprynet.com           www.ctpartners.com

       "The first one was only the beginning!"
0
see_msg
11/17/1998 11:32:03 PM
Hi guys,

    Thanks for the response. Here's what I have in the clicked event of my pb_next
button:

string user_no
long row_no
row_no = index_no + 1     // point to the next record - index_no points to current
record

IF row_no = no_of_rows THEN   // check to see if passed the last record
 pb_first.enabled = true
 pb_prior.enabled = true
 pb_next.enabled = false
 pb_last.enabled = false
ELSEIF row_no < no_of_rows THEN
 pb_first.enabled = true
 pb_prior.enabled = true
 pb_next.enabled = true
 pb_last.enabled = true
END IF

user_no = dw_user_data.object.data[row_no,1]
dw_user_data.retrieve(user_no)

index_no = index_no + 1      // increment index_no


    Please, don't mind my ignorance, I have read only one PB book so far. Thanks again.

Marina

Mark J. Pfeifer wrote:

> With that said...  What methods are you using to navigate the DW from the
> buttons and the DDDW?
>
> Mark
>



0
Marina
11/18/1998 3:41:00 PM
I don't have enough info. here to correct your problem, but I can tell you
an easy solution I have used in the past to do something like you want to
do.

I created two DW objects, both with the exact same SQL.  One (dw_all) shows
all the columns I want to display/update for 1 row.  The other (dw_one)
shows only the key column for 1 row.
Change the key colunm on dw_all to display as a DDDW and use dw_one.  
In the 'Open' of the window, get the dwchild of the key column on dw_all,
store in an instance variable (iv_dwc) and retrieve.
Share data with the dw child to dw_all.
In the itemchanged event of dw_all, do something like:

if dwo.name = 'key column name' then
      this.Scrolltorow(iv_dwc.GetRow())
end if

In the 'First' button, script:

iv_dwc.SetRow(1)
iv_dwc.scrolltorow(1)
dw_all.SetRow(1)
dw_all.scrolltorow(1)

The 'Last' button would scroll to the max row (iv_dwc.rowcount())
The 'next' and 'previous' buttons would scroll to iv_dwc.GetRow() plus or
minus 1

I know this is kinda rough, but it gives you the basic idea.  This
eliminates extra retrieves everytime you select a new key value.

HTH

Marina Sadikoska <msadiko@bellatlantic.net> wrote in article
<3652EA8B.6BFA272A@bellatlantic.net>...
> Hi guys,
> 
>     Thanks for the response. Here's what I have in the clicked event of
my pb_next
> button:
> 
> string user_no
> long row_no
> row_no = index_no + 1     // point to the next record - index_no points
to current
> record
> 
> IF row_no = no_of_rows THEN   // check to see if passed the last record
>  pb_first.enabled = true
>  pb_prior.enabled = true
>  pb_next.enabled = false
>  pb_last.enabled = false
> ELSEIF row_no < no_of_rows THEN
>  pb_first.enabled = true
>  pb_prior.enabled = true
>  pb_next.enabled = true
>  pb_last.enabled = true
> END IF
> 
> user_no = dw_user_data.object.data[row_no,1]
> dw_user_data.retrieve(user_no)
> 
> index_no = index_no + 1      // increment index_no
> 
> 
>     Please, don't mind my ignorance, I have read only one PB book so far.
Thanks again.
> 
> Marina
> 
> Mark J. Pfeifer wrote:
> 
> > With that said...  What methods are you using to navigate the DW from
the
> > buttons and the DDDW?
> >
> > Mark
> >
> 
> 
> 
> 
0
J
11/18/1998 3:50:09 PM
Reply:

Similar Artilces:

Powerbuilder Datawindow Retrieve
I would like to create a dynamic datawindow retrieve. I have a list of datawindows with various types of retrieval arguments--some are arrays. I would like to pass a program the parameter and parameter type and have it dynamically build the retrieve. I've tried using the ANY variable type, but it doesn't work when the argument is an array. Does any one know of a way to "build" the retrieve statement on the fly, or something else to do? Thanks JBachman jbachman@worldnet.att.net -----== Posted via Deja News, The Leader in Internet Discussion ==----- http://www.d...

how to retrieve dddw (datawindow child) at run time
Hi Jerry, I've managed to specify filtervalue column datawindow to dddw_customer using your suggestion. dddw_customer has a retrieval argument "company_id" that will perform select * from customer where company_id = :ll_coid the following code has been added to pfc_populateddw("filtervalue", ldwc) : ---> Return adwc_obj.Retrieve(gnv_app.of_getcompany()) The dialog box that prompts to specify retrieval argument pops out a bit earlier when the program executes: --> dw_1.object.filtervalue.dddw.name = "dddw_customer" after entering the cor...

Powerbuilder API call to stop datawindow retrieval
When I used SQLNET v1.x with Powerbuilder v4.x, I was able to stop a datawindow retrieve in my apps with a key combination of <CTRL>-<C>. This was a very nice feature to have, especially, with a datawindow retrieval lasting several minutes. With Powerbuilder v5.0.0.3 and SQLNET v2.0, the <CTRL>-<C> feature does not work. Powersoft tech support says that Oracle SQLNET v2.0 does not support this feature. But, SQLNET v2.0 documentation says that it does support this feature. I tested this successfully via SQLPLUS. I could use the RetrieveRow datawindow eve...

Powerbuilder API call to stop datawindow retrieval
When I used SQLNET v1.x with Powerbuilder v4.x, I was able to stop a datawindow retrieve in my apps with a key combination of <CTRL>-<C>. This was a very nice feature to have, especially, with a datawindow retrieval lasting several minutes. With Powerbuilder v5.0.0.3 and SQLNET v2.0, the <CTRL>-<C> feature does not work. Powersoft tech support says that Oracle SQLNET v2.0 does not support this feature. But, SQLNET v2.0 documentation says that it does support this feature. I tested this successfully via SQLPLUS. I could use the RetrieveRow datawindow eve...

Retrieving into Datawindow with dddw's containing arguments.
Hi. I have a datawindow that contains two DDDW's. The first DDDW is for choosing the office. The second DDDW is for choosing the person who works for the office. This DDDW has an argument of office_id. It is the "Person-Office" field that is actually updated, however this field is not visual and is manually set when the person is selected. The datawindow itself also contains an argument. When the datawindow is first opened, I am performing an insert row, so I am retrieving first into the dddw for person, and then doing an insert row on the datawindow. I have a...

powerbuilder 10 build 8075 datawindow dddw bug.
If the datawindow column type is money and has dddw, I get error message "Expression is invalid". If I replace dot with comma in regional settings, I can solve the problem. I am using Turkish Charset. thanks We also get the same error message when we apply a filter that has a dash '-' in the expression (using setFilter()). We went back to 8050. Larry "Murat Yelkovan" <muratyelkovan@yahoo.com> wrote in message news:43181629$1@forums-2-dub... > If the datawindow column type is money and has dddw, I get error message > "Expressi...

Web Datawindow & DDDW's with Retrieval Arguments
For anyone that is interested, this can be accomplished with the following. 1) Customize the HTMLGenerator component to add a method to load the dddw's before retrieving. 2) Use the SelfLink & SelfLinkArguments on the datawindow object 3) Set syntax to set the SelfLinkArguments is not simple, so beware! There will be a future article on how to implement this appearing on the SDN. -- Build Your Future With PowerBuilder 7.0 www.ctpartners.com/asp/iowa.asp Larry Cermak [Team Sybase] Corporate Technology Partners, Inc. www.ctpartners.com ...

Powerbuilder Datawindow Retrieve is unusually slow. What's wrong?
We are using powerbuilder with Sybase SQL Anywhere 5.5. An issue we are having is that datawindows that have records 10000+ slow down almost exponentially during a retrieve the higher amount of records there is. A 40000 record datawindow should not take 5-10 minutes to retrieve on a 1ghz machine. Have any of you experienced a similar problem? Please let me know any suggestions you have. Please email me at johnowens50@hotmail.com John Owens johnowens50@hotmail.com Two possibilities: 1) your computer is memory-starved. Is the paging rate going up as the retrieval progre...

Error in datawindow when retrieve with retrieval arguments
Hi, I have a Table and a View created from that proxy table with certain criteria.. i have created a datawindow by joining the table and view... when i pass the retrieval arguments, it is showing an error as follows... Select error: SQLSTATE = 07002 [Sybase][ODBC Driver][Adaptive Server Anywhere]Not enough values for host variables if u r executing the same SQL in ISQL it is working fine... Please help thanks in advance... Danny Hi Danny Which PB version and ASA are you using? I have used retrieval arguments with no problem in datawindow with table and views Ch...

Web DataWindow Retrieve fails with retrieval arguments?
I am new to datawindow .net. In dwn0250releasebulletin.pdf, I find a list of known problems of datawindow.net 2.5 including "Web DataWindow Retrieve fails with retrieval arguments": When there are retrieval arguments, the Web DataWindow client-side Retrieve method returns -1 and fails to retrieve data. [CR 382988]. Has it been solved? Thanks. Vetacs ...

Datawindow retrieve rows in dev, retrieves no rows deployed
I created a datawindow in PB10 and given parameters it retrieves the appropriate rows when running from development. After deploying the application, given the exact same parameters (hard coded) the datawindow does not retrieve any rows. I have seen this once before where if we had comment lines inside of the SQL select for the DW it would not retrieve only when deployed. This time, I have no comments and can not find any reason why the exact same program would retrieve differently when run in dev as opposed to deployed. (Both being run on the same machine) Any ideas?? Is the ...

datawindow.retrieve()
Hi, is there any possibility to find out, why datawindow.retrieve() returns -1 ? We don't get any error event (namely dberror and error). That datawindow is based on the MS SQL stored procedure, but this procedure is not proceeded (we checked it in the MS SQL Trace). We tried to call this procedure directly in the same script like datawindow.Retreive() using the same transaction object and also in the painter of the datawindow and it was OK. Thank's for your attention. Jakub Maxa (jakubm@empire.cz) This is a multi-part message in MIME format. --------------D61B...

Datawindow Retrieve
Two questions: 1. After Retrieve is performed on a datawindow, is it possible to prevent the first row to become the current row? I want the current row to only change when the user click on a row, and thereby prevent the RowFocusChanged-event to be fired for each retrieve. 2. I have a table which changes often and I therby call Retrive often. Is it possible to prevent the datawindow to be redrawed for each retrieve? Can this be done by only retrieve some colomns? I use Power++ and the datawindow builder. Thanks in advance Kenneth Herskedal www.trafsys.no In articl...

Datawindow Retrieves
Does anyone no of a size limit to a retrieve i.e. 32k say. I'm running win95 and win2k workstations NT servers running Oracle 8.1.7 DB PB 7.03 Thanks in advance -- You are limited to the resources available on the client machine. Are you having problems? "Chris" <cisaksen@mail.nysed.gov> wrote in message news:77dZrANCCHA.81@forums.sybase.com... > Does anyone no of a size limit to a retrieve i.e. 32k say. > > I'm running win95 and win2k workstations > NT servers running Oracle 8.1.7 DB > > PB 7.03 > > Thanks i...

Web resources about - Dddw and retrieve - sybase.powerbuilder.datawindow

Facebook Developers Can Retrieve Users’ Profile Pictures In Different Sizes
Facebook introduced a way for developers to retrieve users’ profile pictures for use within their applications in different sizes, rather than ...

Winston retrieves the news
... food and losing weight. Three months ago, we were told he had lymphosarcoma of the GI tract. On March 10, 2008, Winston was called to go retrieve ...

Gizzard uses a rope to retrieve a submerged gift, 10 second retrieval from noticing the rope - YouTube ...
This is the second attempt, and the second occurrence he has ever seen this contraption. Without the rope, he would probably drown to retrieve ...

Dutch backpacker paid $5 an hour to retrieve golf balls from lakes
A Dutch backpacker claims he was paid as little as $5 an hour to wade through murky ponds and lakes retrieving thousands of lost golf balls. ...

People Are Willing To Go To Extreme Lengths To Retrieve Their Stolen Smartphones
People are willing to pay a ton of money and potentially put themselves in danger to retrieve their stolen smartphones, a new survey has found. ...

Police officer shot at 'very large' shark to retrieve body of swimmer
A policeman who shot a shark in a bid to retrieve the body of a swimmer it had killed says his first bullets disintegrated as they hit the water ...

Divers retrieve body from NSW floodwaters
A woman's body has been retrieved from a submerged car in a creek in Maitland.

Tourist plunges to death from Potts Point rooftop park trying to retrieve football: police
A French tourist who fell to his death from a rooftop park in Potts Point in inner Sydney was attempting to retrieve a football that had gone ...

The art of war: Quest to retrieve what Nazis stole
Susan Fisher Sullam tells of learning her father was a wartime treasure hunter, tracking down what the Nazis had plundered from Holocaust victims. ...

Investigators retrieve more human remains at MH17 crash site in eastern Ukraine but wreckage cannot yet ...
Dutch forensic experts recover further human remains at the crash site of downed flight MH17.

Resources last updated: 11/26/2015 4:04:42 PM