Solved

Datawindow column change after database change

Posted on 2004-08-18
5
927 Views
Last Modified: 2013-12-26
Hi,
I have Powerbuilder 5.0 using a database in PostgreSQL. I have a datawindow column whose field width I set to 15 during creation. Now, I want to change it to 100. I can make this change on the database side, but the datawindow does not get updated with this. I tried to 'regenerate' the datawindow, but the change still does not take place. I also have the setting 'Retain Data to Design' checked on in the DataWindow options.
When I try to set the field value to something containing more than 15 characters, for the first time, it adds it. But when I try to add a second such value, it gives me the error that says 'Error Number 6. Error text = Invalid DataWindow row/column specified.' and it gives me the name of the object, function and line in script where it has a problem.
Is it even possible to make the field length change without creating a new datawindow? Incidentally, this works fine, without problem when a Oracle database is used.

Thanks in advance.
0
Comment
Question by:pcasxd0
  • 2
  • 2
5 Comments
 
LVL 8

Assisted Solution

by:Vikas_Dixit
Vikas_Dixit earned 125 total points
ID: 11835732
You can export the dw and do the change in the .srw file and import it back.
Please remember to take backup of your pbl before trying this.
Regards,
Vikas
0
 
LVL 18

Accepted Solution

by:
diasroshan earned 125 total points
ID: 11838405
hi,
the solution is kinda crude/funny but it always works and the problem u've posted is very common....

open ur datawindow and go to the sql view of the datawindow(SQL syntax)....
now u can see the sql statement of ur datawindow....
remove any comma and return...it would give an error of incorrect syntax...now add the comma and return to ur datawindow view...save the datawindow...ur problem is solved!!!


check the column specification of ur datawindow....now it should show 100 in the 'type'...

do ask if u need more assistance...

Cheers,
Rosh
0
 

Author Comment

by:pcasxd0
ID: 11843543
Hi VikasDixit,
Thanks for the answer. I'll try and do that.

Hi Rosh,
Thanks for the answer. The problem with PostgreSQL is that it does not open the SQL view in the PB datawindow. When we click on the SQL icon in the toolbar, it simply hangs. I don't know why this is. When the database is Oracle, the SQL Editor gets opened without problems.  Your solution does sound interesting, though! Thanks.

I'll try this out and grade pretty soon.
0
 
LVL 18

Expert Comment

by:diasroshan
ID: 11849404
hi,

the problem stated by u is a bug in PB5...
"The problem with PostgreSQL is that it does not open the SQL view in the PB datawindow. When we click on the SQL icon in the toolbar, it simply hangs"

DONT live with it... its a bug and many other such bugs which can be solved by applying the relevant patches...

go to www.sybase.com

---> go to the download option
---> in the download page there is a link EBFs/Maintenance
---> u will be asked to register once u go to that link....
---> register onto sybase(this will help in future)...its free
---> there will be a selection of time frame...select 'all'
---> now when u search u will find 'PowerBuilder - PowerBuilder 5.0.04 EBF#3
'---> Download it
Install this patch and many of ur errors will be solved...


do ask for more assistance...

Cheers,
Rosh
0
 

Author Comment

by:pcasxd0
ID: 11856752
Rosh:
Vow, really, that's a great tip. You might have guessed by now that I'm a total newbie here. I will certainly do that download. I thought that there was no way around it.
VikasDixit: Since I like both answers, I'm going to split the points.
Thanks.
0

Featured Post

Do You Know the 4 Main Threat Actor Types?

Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

Join & Write a Comment

Here is a helpful source code for C++ Builder programmers that allows you to manage and manipulate HTML content from C++ code, while also handling HTML events like onclick, onmouseover, ... Some objects defined and used in this source include: …
How to install Selenium IDE and loops for quick automated testing. Get Selenium IDE from http://seleniumhq.org (http://seleniumhq.org) Go to that link and select download selenium in the right hand columnThat will then direct you to their downlo…
THe viewer will learn how to use NetBeans IDE 8.0 for Windows to perform CRUD operations on a MySql database.
The viewer will learn how to use and create new code templates in NetBeans IDE 8.0 for Windows.

747 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now