1. Andrew Davis
  2. PowerBuilder
  3. Wednesday, 7 February 2024 19:03 PM UTC

Hi 

 

I hope someone can help, I am having a weird error - with the simplest of datawindows and programmes

I have just installed pb2022 R3 - on windows 10

I have it connected to SQLexpress database - v14.

I have a very very simple 2 column table with a column = id type int and a column =name varchar(50)

i created a grid style datawindow - with just this table and the 2 columns

if i view and edit the data using the window in the IDE - i can insert lines and it updates correctly

when i run the programme - my insertrow(0) - adds the line - i can type in the id and as soon as i tab to the name the new line disappears. 

the datawindow is connected via the sqlca object and i retrieve it okay.

If at runtime instead of inserting a row , i use an insert into script in powerbuilder - it adds the record and can be retrieved in the datawindow 

 

What am i doing wrong - i have very little experience of MS Sql - normally user other dbs

thanks in advance 

Andrew

Andrew Davis Accepted Answer Pending Moderation
  1. Tuesday, 13 February 2024 17:03 PM UTC
  2. PowerBuilder
  3. # 1

The resolution was really stupid - there was some code in the itemchanged event on the datawindow which was causing the problem. I typed in or copied there by mistake at some point rather than the command button it was supposed to go on The only thing i can blame it on / excuse I have is my lack of being used to the new IDE

really sorry for the hassle but appreciate the support.

 

Comment
  1. John Fauss
  2. Tuesday, 13 February 2024 17:06 PM UTC
I'm glad to learn you found the cause of the issue, Andrew. No worries, because that's what we're here for. Thanks for the update!
  1. Helpful
There are no comments made yet.
Armeen Mazda @Appeon Accepted Answer Pending Moderation
  1. Thursday, 8 February 2024 14:01 PM UTC
  2. PowerBuilder
  3. # 2

Hi Andrew, Seems like you have a simple test case that reproduces the problem.  So please open a support ticket and our team will investigate: https://www.appeon.com/standardsupport/newbug

 

Comment
There are no comments made yet.
John Fauss Accepted Answer Pending Moderation
  1. Thursday, 8 February 2024 01:48 AM UTC
  2. PowerBuilder
  3. # 3

Hi, Andrew -

This sounds as if there might be some code or expression(s) at work, but it is difficult to say for sure. What version, release, build of PB are you using?

What database client interface (SQLCA.DBMS = "???") are you using? MSO? SNC? ODB (ODBC)? ADO? Have you tried enabling the database activity trace (SQLCA.DBMS = "TRACE ???") to see what SQL commands are being issued by the DataWindow Control?

Best regards, John

Comment
  1. Andrew Davis
  2. Thursday, 8 February 2024 11:55 AM UTC
So I am using dbms 14

Snc

Pb 2022 r3 latest build stable release



I think it might be to having just installed r3.



Is there a uninstall procedure ? Other than add remove programmes ?
  1. Helpful
  1. Andrew Davis
  2. Thursday, 8 February 2024 12:08 PM UTC
As for code and expressions. I created the app from the template. Ado type and have just one window. With the dw on it.

I settransobject to sqlca and retrieve

Insertrow(0)

Then when I try to type data the line disappears.



I will try to activate the trace

  1. Helpful
  1. John Fauss
  2. Thursday, 8 February 2024 14:32 PM UTC
I've used SQL Server with PB for nearly 15 years, so if you wish, I will be happy to test your sample app. Zip the PB workspace (.pbw), target (.pbt) and library (.pbl) into a zip file and attach it to a new response in this thread. I can't look at it now as I'm at work, but I can test it later tonight at home. Please include the table name, the column names and the data types of the table columns so that I can faithfully reproduce conditions on my end. Please also be sure to include the transaction object's properties if they are not hard-coded into the sample app (omit or X-out any sensitive values such as IP addresses and passwords).
  1. Helpful
There are no comments made yet.
Chris Pollach @Appeon Accepted Answer Pending Moderation
  1. Wednesday, 7 February 2024 21:17 PM UTC
  2. PowerBuilder
  3. # 4

Hi Andrew;

  The DBMS type has nothing to do with this behaviour (weird as it may seem).

  Does it work OK if you click on the columns & then do data entry?

Regards .. Chris

Comment
There are no comments made yet.
  • Page :
  • 1


There are no replies made for this question yet.
However, you are not allowed to reply to this question.
We use cookies which are necessary for the proper functioning of our websites. We also use cookies to analyze our traffic, improve your experience and provide social media features. If you continue to use this site, you consent to our use of cookies.