Sybase NNTP forums - End Of Life (EOL)

The NNTP forums from Sybase - forums.sybase.com - are now closed.

All new questions should be directed to the appropriate forum at the SAP Community Network (SCN).

Individual products have links to the respective forums on SCN, or you can go to SCN and search for your product in the search box (upper right corner) to find your specific developer center.

DataWindow Updates

14 posts in DataWindow .NET Last posting was on 2005-01-05 21:27:00.0Z
Jon D Posted on 2004-09-14 10:48:15.0Z
Sender: 3942.412e05d0.1804289383@sybase.com
From: Jon D
Newsgroups: sybase.public.datawindow.net
Subject: DataWindow Updates
X-Mailer: WebNews to Mail Gateway v1.1t
Message-ID: <4146cc6f.7e0.1681692777@sybase.com>
NNTP-Posting-Host: 10.22.241.41
X-Original-NNTP-Posting-Host: 10.22.241.41
Date: 14 Sep 2004 03:48:15 -0700
X-Trace: forums-1-dub 1095158895 10.22.241.41 (14 Sep 2004 03:48:15 -0700)
X-Original-Trace: 14 Sep 2004 03:48:15 -0700, 10.22.241.41
Lines: 24
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub sybase.public.datawindow.net:354
Article PK: 124785

Hi, Should I be able to update my database with stored
procedures when I originally retrieved the data via a stored
procedure ?

This does not seem to work ! I've defined my update SP's but
get an error when trying to do an UpdateDate method.

This is a realistic thing that one would want to do isn't
it?

The reason I've got a doubt in my mind is the statement on
page 188 of the DataWindow Designer User guide which says :

'If the datasource is a stored proceedure or external, you
can use the FindNextModifiedRowmethod to write your own
update code.'

Surely if you retrieve via a stored procedure , you should
be able to specify update SP's and use the UpdateData
method.

Thanks

Jon


Bruce Armstrong [TeamSybase] Posted on 2004-09-14 13:12:17.0Z
From: "Bruce Armstrong [TeamSybase]" <NOCANSPAM_bruce.armstrong@teamsybase.com>
Newsgroups: sybase.public.datawindow.net
Subject: Re: DataWindow Updates
Organization: TeamSybase
Reply-To: NOCANSPAM_bruce.armstrong@teamsybase.com
Message-ID: <ntpdk0hrkhvsp60sjrsom8qlif5cevipv4@4ax.com>
References: <4146cc6f.7e0.1681692777@sybase.com>
X-Newsreader: Forte Agent 2.0/32.646
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
NNTP-Posting-Host: 68-190-226-38.la-cbi.charterpipeline.net
X-Original-NNTP-Posting-Host: 68-190-226-38.la-cbi.charterpipeline.net
Date: 14 Sep 2004 06:12:17 -0700
X-Trace: forums-1-dub 1095167537 68.190.226.38 (14 Sep 2004 06:12:17 -0700)
X-Original-Trace: 14 Sep 2004 06:12:17 -0700, 68-190-226-38.la-cbi.charterpipeline.net
Lines: 61
X-Authenticated-User: TeamSybase
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub sybase.public.datawindow.net:358
Article PK: 124787

In Datawindow Designer, did you map the update specs to the stored
procedure using the Rows->Stored Procedure Update... dialog?

On 14 Sep 2004 03:48:15 -0700, Jon D wrote:

>Hi, Should I be able to update my database with stored
>procedures when I originally retrieved the data via a stored
>procedure ?
>
>This does not seem to work ! I've defined my update SP's but
>get an error when trying to do an UpdateDate method.
>
>This is a realistic thing that one would want to do isn't
>it?
>
>The reason I've got a doubt in my mind is the statement on
>page 188 of the DataWindow Designer User guide which says :
>
>'If the datasource is a stored proceedure or external, you
>can use the FindNextModifiedRowmethod to write your own
>update code.'
>
>Surely if you retrieve via a stored procedure , you should
>be able to specify update SP's and use the UpdateData
>method.
>
>Thanks
>
>Jon

Bruce Armstrong [TeamSybase]
http://www.teamsybase.com

TeamSybase blogs:
http://www.teamsybase.net/blogs

Two 3rd party books on developing with PowerBuilder
http://www.pb9books.com?source=newsgroups

Need code sample? Check out CodeXchange:
http://www.codexchange.sybase.com

Preach the gospel at all times. If necessary, use words. - Francis of Assisi
http://www.needhim.org

---------------------------------------------------------------------
DISCLAIMER:

This newsgroup message is only intended for the recipient. Given that it
is a posting to a public newsgroup, that means if you can read this
message then you are the recipient. This message may contain information
that is confidential and protected from disclosure. And then again,
it may not.

Given that TeamSybase members are not employees of Sybase, the contents
of this message do not necessarily represent the views or policies of
Sybase. Given that TeamSybase is a diverse group of users of Sybase
products, the contents of this message do not necessarily represent the
views of a significant number of the members of TeamSybase. Given that the
author has multiple personalities and hears voices in his head, the contents
of this message do not necessarily represent his own views.


Jon D Posted on 2004-09-14 15:10:57.0Z
Sender: 4b63.41470aba.1804289383@sybase.com
From: Jon D
Newsgroups: sybase.public.datawindow.net
Subject: Re: DataWindow Updates
X-Mailer: WebNews to Mail Gateway v1.1t
Message-ID: <41470bb8.4b76.1681692777@sybase.com>
References: <ntpdk0hrkhvsp60sjrsom8qlif5cevipv4@4ax.com>
X-Original-NNTP-Posting-Host: 10.22.241.42
X-Original-Trace: 14 Sep 2004 08:18:16 -0700, 10.22.241.42
Lines: 69
X-Original-NNTP-Posting-Host: forums-2-dub.sybase.com
X-Original-Trace: 14 Sep 2004 07:58:55 -0700, forums-2-dub.sybase.com
NNTP-Posting-Host: forums-master.sybase.com
X-Original-NNTP-Posting-Host: forums-master.sybase.com
Date: 14 Sep 2004 08:10:57 -0700
X-Trace: forums-1-dub 1095174657 10.22.108.75 (14 Sep 2004 08:10:57 -0700)
X-Original-Trace: 14 Sep 2004 08:10:57 -0700, forums-master.sybase.com
X-Authenticated-User: ngsysop
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub sybase.public.datawindow.net:360
Article PK: 124789

Hi Guys,
Thanks for the speedy response.

Here is the error message I'm getting:

"System.NullReferenceException: Object reference not set to
an instance of an object.
at DataWindowInterop.SemanticFunctions.Update(IntPtr
given_DW, Boolean AcceptData, Boolean ResetUpdateFlags)
at Sybase.DataWindow.Shared.UpdateData(IntPtr pDW,
Boolean AcceptData, Boolean ResetUpdateFlags)
at Sybase.DataWindow.DataWindowControl.UpdateData(Boolean
AcceptData)
at project1.frmDyeStocksDispensary.btnSave_Click(Object
sender, EventArgs e) in C:\Documents and
Settings\jdenton.ACFIBRES\My Documents\VB Net
2003\DataWindowTest2\Test2\project1\frmDyeStocksDispensary.vb:line
124"

yes i had mapped the update specs to SP's as specified.

my update code is as follows :
Try
dwDispensary.UpdateData(True)
Catch ex As Sybase.DataWindow.DbErrorException
MessageBox.Show(ex.SqlErrorText, "DataWindow
Operation Failed", MessageBoxButtons.OK,
MessageBoxIcon.Stop)
Catch ex As Exception
MessageBox.Show(ex.ToString(), "Unexpected
Exception", MessageBoxButtons.OK, MessageBoxIcon.Stop)
End Try

The database is MS SQLServer 2000.

Hope this info helps

Jon

> In Datawindow Designer, did you map the update specs to
> the stored procedure using the Rows->Stored Procedure
> Update... dialog?
>
> On 14 Sep 2004 03:48:15 -0700, Jon D wrote:
>
> >Hi, Should I be able to update my database with stored
> >procedures when I originally retrieved the data via a
> stored >procedure ?
> >
> >This does not seem to work ! I've defined my update SP's
> but >get an error when trying to do an UpdateDate method.
> >
> >This is a realistic thing that one would want to do isn't
> >it?
> >
> >The reason I've got a doubt in my mind is the statement
> on >page 188 of the DataWindow Designer User guide which
> says : >
> >'If the datasource is a stored proceedure or external,
> you >can use the FindNextModifiedRowmethod to write your
> own >update code.'
> >
> >Surely if you retrieve via a stored procedure , you
> should >be able to specify update SP's and use the
> UpdateData >method.
> >
> >Thanks
> >
> >Jon


Jon D Posted on 2004-09-14 15:12:38.0Z
Sender: 4b63.41470aba.1804289383@sybase.com
From: Jon D
Newsgroups: sybase.public.datawindow.net
Subject: Re: DataWindow Updates
X-Mailer: WebNews to Mail Gateway v1.1t
Message-ID: <41470c1c.4b7f.1681692777@sybase.com>
References: <ntpdk0hrkhvsp60sjrsom8qlif5cevipv4@4ax.com>
X-Original-NNTP-Posting-Host: 10.22.241.42
X-Original-Trace: 14 Sep 2004 08:19:56 -0700, 10.22.241.42
Lines: 69
X-Original-NNTP-Posting-Host: forums-2-dub.sybase.com
X-Original-Trace: 14 Sep 2004 08:00:35 -0700, forums-2-dub.sybase.com
NNTP-Posting-Host: forums-master.sybase.com
X-Original-NNTP-Posting-Host: forums-master.sybase.com
Date: 14 Sep 2004 08:12:38 -0700
X-Trace: forums-1-dub 1095174758 10.22.108.75 (14 Sep 2004 08:12:38 -0700)
X-Original-Trace: 14 Sep 2004 08:12:38 -0700, forums-master.sybase.com
X-Authenticated-User: ngsysop
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub sybase.public.datawindow.net:361
Article PK: 124791

Hi Guys,
Thanks for the speedy response.

Here is the error message I'm getting:

"System.NullReferenceException: Object reference not set to
an instance of an object.
at DataWindowInterop.SemanticFunctions.Update(IntPtr
given_DW, Boolean AcceptData, Boolean ResetUpdateFlags)
at Sybase.DataWindow.Shared.UpdateData(IntPtr pDW,
Boolean AcceptData, Boolean ResetUpdateFlags)
at Sybase.DataWindow.DataWindowControl.UpdateData(Boolean
AcceptData)
at project1.frmDyeStocksDispensary.btnSave_Click(Object
sender, EventArgs e) in C:\Documents and
Settings\jdenton.ACFIBRES\My Documents\VB Net
2003\DataWindowTest2\Test2\project1\frmDyeStocksDispensary.vb:line
124"

yes i had mapped the update specs to SP's as specified.

my update code is as follows :
Try
dwDispensary.UpdateData(True)
Catch ex As Sybase.DataWindow.DbErrorException
MessageBox.Show(ex.SqlErrorText, "DataWindow
Operation Failed", MessageBoxButtons.OK,
MessageBoxIcon.Stop)
Catch ex As Exception
MessageBox.Show(ex.ToString(), "Unexpected
Exception", MessageBoxButtons.OK, MessageBoxIcon.Stop)
End Try

The database is MS SQLServer 2000.

Hope this info helps

Jon

> In Datawindow Designer, did you map the update specs to
> the stored procedure using the Rows->Stored Procedure
> Update... dialog?
>
> On 14 Sep 2004 03:48:15 -0700, Jon D wrote:
>
> >Hi, Should I be able to update my database with stored
> >procedures when I originally retrieved the data via a
> stored >procedure ?
> >
> >This does not seem to work ! I've defined my update SP's
> but >get an error when trying to do an UpdateDate method.
> >
> >This is a realistic thing that one would want to do isn't
> >it?
> >
> >The reason I've got a doubt in my mind is the statement
> on >page 188 of the DataWindow Designer User guide which
> says : >
> >'If the datasource is a stored proceedure or external,
> you >can use the FindNextModifiedRowmethod to write your
> own >update code.'
> >
> >Surely if you retrieve via a stored procedure , you
> should >be able to specify update SP's and use the
> UpdateData >method.
> >
> >Thanks
> >
> >Jon


Jim O'Neil [Sybase] Posted on 2004-09-14 13:02:23.0Z
From: "Jim O'Neil [Sybase]" <joneil_at_sybase_dot_com>
Newsgroups: sybase.public.datawindow.net
Subject: Re: DataWindow Updates
Message-ID: <e4qdk0tbol47ernp3o4vorou09u9eugsn3@4ax.com>
References: <4146cc6f.7e0.1681692777@sybase.com>
X-Newsreader: Forte Agent 2.0/32.652
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
NNTP-Posting-Host: joneilw2k.sybase.com
X-Original-NNTP-Posting-Host: joneilw2k.sybase.com
Date: 14 Sep 2004 06:02:23 -0700
X-Trace: forums-1-dub 1095166943 10.18.63.187 (14 Sep 2004 06:02:23 -0700)
X-Original-Trace: 14 Sep 2004 06:02:23 -0700, joneilw2k.sybase.com
Lines: 36
X-Authenticated-User: teamsybase
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub sybase.public.datawindow.net:357
Article PK: 124788

Absolutely, this should work. Can you be more specific about the
error that you receive on UpdateData, specifically what message is
caught in the DbErrorException?

As for the documentation on pg. 188, that seems to be an unfortunate
holdover from a previous versions of the DataWindow technology where
there was no automatic specification of stored procedures for updates,
only for retrieves.

On 14 Sep 2004 03:48:15 -0700, Jon D wrote:

>Hi, Should I be able to update my database with stored
>procedures when I originally retrieved the data via a stored
>procedure ?
>
>This does not seem to work ! I've defined my update SP's but
>get an error when trying to do an UpdateDate method.
>
>This is a realistic thing that one would want to do isn't
>it?
>
>The reason I've got a doubt in my mind is the statement on
>page 188 of the DataWindow Designer User guide which says :
>
>'If the datasource is a stored proceedure or external, you
>can use the FindNextModifiedRowmethod to write your own
>update code.'
>
>Surely if you retrieve via a stored procedure , you should
>be able to specify update SP's and use the UpdateData
>method.
>
>Thanks
>
>Jon


Evdin N. URSAN Posted on 2004-09-14 14:57:00.0Z
From: "Evdin N. URSAN" <evdin.ursan@aectra.ro>
Newsgroups: sybase.public.datawindow.net
References: <4146cc6f.7e0.1681692777@sybase.com> <e4qdk0tbol47ernp3o4vorou09u9eugsn3@4ax.com>
Subject: Re: DataWindow Updates
Lines: 79
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1437
X-MIMEOLE: Produced By Microsoft MimeOLE V6.00.2800.1441
X-Original-NNTP-Posting-Host: aectracatv1.mediasat.ro
Message-ID: <41470872$1@forums-2-dub>
X-Original-Trace: 14 Sep 2004 08:04:18 -0700, aectracatv1.mediasat.ro
X-Original-NNTP-Posting-Host: forums-2-dub.sybase.com
X-Original-Trace: 14 Sep 2004 07:44:57 -0700, forums-2-dub.sybase.com
NNTP-Posting-Host: forums-master.sybase.com
X-Original-NNTP-Posting-Host: forums-master.sybase.com
Date: 14 Sep 2004 07:57:00 -0700
X-Trace: forums-1-dub 1095173820 10.22.108.75 (14 Sep 2004 07:57:00 -0700)
X-Original-Trace: 14 Sep 2004 07:57:00 -0700, forums-master.sybase.com
X-Authenticated-User: ngsysop
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub sybase.public.datawindow.net:359
Article PK: 124790

Hi!


I have the same problem! I mapped correctly the columns in Stored Procedure
Update and even in the Datawindow Designer it's working, in Runtime the
program crash with no DB Error Exception but with NULL Reference Exeption on
UpdateData.

I have used the datawindow object with a datawindow control and with a
datastore object and I got the same error.

Find below the used lines:

Sybase.DataWindow.DataStore dsImpachetari = new
Sybase.DataWindow.DataStore();
dsImpachetari.LibraryList =@"C:\ProiecteNet\Contracte Agro
2005\Contracte AGRO\ContracteAgro2005\LibrarieDW\dw.pbl";
dsImpachetari.DataWindowObject = "d_adauga_impachetari_ds";
dsImpachetari.SetTransaction (this.SQLCA);
dsImpachetari.InsertRow(0);
dsImpachetari.SetItemDouble (1, "nrpachete",this.nrProd -1);
dsImpachetari.SetItemDouble (1,
"idpachet",dwIntroducere.GetItemDouble(dwIntroducere.RowCount,
"idimpachetare"));
dsImpachetari.UpdateData();

--



======================
Evdin N. URSAN
T&IT Manager
Aectra ROMANIA
Tel: +(4/021)312.27.89
Fax: +(4/021)312.08.29
Mobil: +(4) 0742.14.80.09
Email: evdin.ursan@aectra.ro
Web: http://www.aectra.ro

"Jim O'Neil [Sybase]" <joneil_at_sybase_dot_com> wrote in message
news:e4qdk0tbol47ernp3o4vorou09u9eugsn3@4ax.com...
> Absolutely, this should work. Can you be more specific about the
> error that you receive on UpdateData, specifically what message is
> caught in the DbErrorException?
>
> As for the documentation on pg. 188, that seems to be an unfortunate
> holdover from a previous versions of the DataWindow technology where
> there was no automatic specification of stored procedures for updates,
> only for retrieves.
>
> On 14 Sep 2004 03:48:15 -0700, Jon D wrote:
>
> >Hi, Should I be able to update my database with stored
> >procedures when I originally retrieved the data via a stored
> >procedure ?
> >
> >This does not seem to work ! I've defined my update SP's but
> >get an error when trying to do an UpdateDate method.
> >
> >This is a realistic thing that one would want to do isn't
> >it?
> >
> >The reason I've got a doubt in my mind is the statement on
> >page 188 of the DataWindow Designer User guide which says :
> >
> >'If the datasource is a stored proceedure or external, you
> >can use the FindNextModifiedRowmethod to write your own
> >update code.'
> >
> >Surely if you retrieve via a stored procedure , you should
> >be able to specify update SP's and use the UpdateData
> >method.
> >
> >Thanks
> >
> >Jon
>


Jim O'Neil [Sybase] Posted on 2004-09-14 15:25:51.0Z
From: "Jim O'Neil [Sybase]" <joneil_at_sybase_dot_com>
Newsgroups: sybase.public.datawindow.net
Subject: Re: DataWindow Updates
Message-ID: <lk2ek05k7k3ehf7qmlrk7qjci5m6f3ol1u@4ax.com>
References: <4146cc6f.7e0.1681692777@sybase.com> <e4qdk0tbol47ernp3o4vorou09u9eugsn3@4ax.com> <41470872$1@forums-2-dub>
X-Newsreader: Forte Agent 2.0/32.652
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
X-Original-NNTP-Posting-Host: joneilw2k.sybase.com
X-Original-Trace: 14 Sep 2004 08:33:10 -0700, joneilw2k.sybase.com
Lines: 31
X-Original-NNTP-Posting-Host: forums-2-dub.sybase.com
X-Original-Trace: 14 Sep 2004 08:13:49 -0700, forums-2-dub.sybase.com
NNTP-Posting-Host: forums-master.sybase.com
X-Original-NNTP-Posting-Host: forums-master.sybase.com
Date: 14 Sep 2004 08:25:51 -0700
X-Trace: forums-1-dub 1095175551 10.22.108.75 (14 Sep 2004 08:25:51 -0700)
X-Original-Trace: 14 Sep 2004 08:25:51 -0700, forums-master.sybase.com
X-Authenticated-User: ngsysop
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub sybase.public.datawindow.net:362
Article PK: 124793

Can you do the update successfully within DataWindow Designer?

On 14 Sep 2004 07:57:00 -0700, "Evdin N. URSAN"

<evdin.ursan@aectra.ro> wrote:

>Hi!
>
>
>I have the same problem! I mapped correctly the columns in Stored Procedure
>Update and even in the Datawindow Designer it's working, in Runtime the
>program crash with no DB Error Exception but with NULL Reference Exeption on
>UpdateData.
>
>I have used the datawindow object with a datawindow control and with a
>datastore object and I got the same error.
>
>Find below the used lines:
>
>Sybase.DataWindow.DataStore dsImpachetari = new
>Sybase.DataWindow.DataStore();
> dsImpachetari.LibraryList =@"C:\ProiecteNet\Contracte Agro
>2005\Contracte AGRO\ContracteAgro2005\LibrarieDW\dw.pbl";
> dsImpachetari.DataWindowObject = "d_adauga_impachetari_ds";
> dsImpachetari.SetTransaction (this.SQLCA);
> dsImpachetari.InsertRow(0);
> dsImpachetari.SetItemDouble (1, "nrpachete",this.nrProd -1);
> dsImpachetari.SetItemDouble (1,
>"idpachet",dwIntroducere.GetItemDouble(dwIntroducere.RowCount,
>"idimpachetare"));
>dsImpachetari.UpdateData();


Evdin N. URSAN Posted on 2004-09-15 06:32:43.0Z
From: "Evdin N. URSAN" <evdin.ursan@aectra.ro>
Newsgroups: sybase.public.datawindow.net
References: <4146cc6f.7e0.1681692777@sybase.com> <e4qdk0tbol47ernp3o4vorou09u9eugsn3@4ax.com> <41470872$1@forums-2-dub> <lk2ek05k7k3ehf7qmlrk7qjci5m6f3ol1u@4ax.com>
Subject: Re: DataWindow Updates
Lines: 77
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1437
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1441
NNTP-Posting-Host: aectracatv1.mediasat.ro
X-Original-NNTP-Posting-Host: aectracatv1.mediasat.ro
Message-ID: <4147e20b$1@forums-1-dub>
Date: 14 Sep 2004 23:32:43 -0700
X-Trace: forums-1-dub 1095229963 193.108.55.137 (14 Sep 2004 23:32:43 -0700)
X-Original-Trace: 14 Sep 2004 23:32:43 -0700, aectracatv1.mediasat.ro
X-Authenticated-User: pbtenbeta
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub sybase.public.datawindow.net:365
Article PK: 124795

Yes! In the Datawindow designer, the update process works just fine.

The full error is (I think is the same as JonD's):

System.NullReferenceException: Object reference not set to an instance of an
object.
at DataWindowInterop.SemanticFunctions.Update(IntPtr given_DW, Boolean
AcceptData, Boolean ResetUpdateFlags)
at Sybase.DataWindow.Shared.UpdateData(IntPtr pDW, Boolean AcceptData,
Boolean ResetUpdateFlags)
at Sybase.DataWindow.DataWindowControl.UpdateData()
at ContracteAgro2005.frmImpachetari.button1_Click(Object sender,
EventArgs e) in c:\proiectenet\contracte agro 2005\contracte
agro\contracteagro2005\frmimpachetari.cs:line 340
at System.Windows.Forms.Control.OnClick(EventArgs e)
at System.Windows.Forms.Button.OnClick(EventArgs e)
at System.Windows.Forms.Button.OnMouseUp(MouseEventArgs mevent)
at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons
button, Int32 clicks)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.ButtonBase.WndProc(Message& m)
at System.Windows.Forms.Button.WndProc(Message& m)
at System.Windows.Forms.ControlNativeWindow.OnMessage(Message& m)
at System.Windows.Forms.ControlNativeWindow.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg,
IntPtr wparam, IntPtr lparam)

--



======================
Evdin N. URSAN
T&IT Manager
Aectra ROMANIA
Tel: +(4/021)312.27.89
Fax: +(4/021)312.08.29
Mobil: +(4) 0742.14.80.09
Email: evdin.ursan@aectra.ro
Web: http://www.aectra.ro

"Jim O'Neil [Sybase]" <joneil_at_sybase_dot_com> wrote in message
news:lk2ek05k7k3ehf7qmlrk7qjci5m6f3ol1u@4ax.com...
> Can you do the update successfully within DataWindow Designer?
>
> On 14 Sep 2004 07:57:00 -0700, "Evdin N. URSAN"
> <evdin.ursan@aectra.ro> wrote:
>
> >Hi!
> >
> >
> >I have the same problem! I mapped correctly the columns in Stored
Procedure
> >Update and even in the Datawindow Designer it's working, in Runtime the
> >program crash with no DB Error Exception but with NULL Reference Exeption
on
> >UpdateData.
> >
> >I have used the datawindow object with a datawindow control and with a
> >datastore object and I got the same error.
> >
> >Find below the used lines:
> >
> >Sybase.DataWindow.DataStore dsImpachetari = new
> >Sybase.DataWindow.DataStore();
> > dsImpachetari.LibraryList =@"C:\ProiecteNet\Contracte Agro
> >2005\Contracte AGRO\ContracteAgro2005\LibrarieDW\dw.pbl";
> > dsImpachetari.DataWindowObject = "d_adauga_impachetari_ds";
> > dsImpachetari.SetTransaction (this.SQLCA);
> > dsImpachetari.InsertRow(0);
> > dsImpachetari.SetItemDouble (1, "nrpachete",this.nrProd -1);
> > dsImpachetari.SetItemDouble (1,
> >"idpachet",dwIntroducere.GetItemDouble(dwIntroducere.RowCount,
> >"idimpachetare"));
> >dsImpachetari.UpdateData();
>


Jim O'Neil [Sybase] Posted on 2004-09-16 02:09:36.0Z
From: "Jim O'Neil [Sybase]" <joneil_at_sybase_dot_com>
Newsgroups: sybase.public.datawindow.net
Subject: Re: DataWindow Updates
Message-ID: <fmshk0de3cuujipuk6695imr3f210bbh2g@4ax.com>
References: <4146cc6f.7e0.1681692777@sybase.com> <e4qdk0tbol47ernp3o4vorou09u9eugsn3@4ax.com> <41470872$1@forums-2-dub> <lk2ek05k7k3ehf7qmlrk7qjci5m6f3ol1u@4ax.com> <4147e20b$1@forums-1-dub>
X-Newsreader: Forte Agent 2.0/32.652
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
NNTP-Posting-Host: vpn-concord-098.sybase.com
X-Original-NNTP-Posting-Host: vpn-concord-098.sybase.com
Date: 15 Sep 2004 19:09:36 -0700
X-Trace: forums-1-dub 1095300576 158.159.8.98 (15 Sep 2004 19:09:36 -0700)
X-Original-Trace: 15 Sep 2004 19:09:36 -0700, vpn-concord-098.sybase.com
Lines: 34
X-Authenticated-User: teamsybase
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub sybase.public.datawindow.net:379
Article PK: 124808

Ok, I've reproduced this - although I get a different exception, which
seems a bit odd, and engineering is seeing it too. I'm not quite sure
when we'd have a fix available though.

On 14 Sep 2004 23:32:43 -0700, "Evdin N. URSAN"

<evdin.ursan@aectra.ro> wrote:

>Yes! In the Datawindow designer, the update process works just fine.
>
>The full error is (I think is the same as JonD's):
>
>System.NullReferenceException: Object reference not set to an instance of an
>object.
> at DataWindowInterop.SemanticFunctions.Update(IntPtr given_DW, Boolean
>AcceptData, Boolean ResetUpdateFlags)
> at Sybase.DataWindow.Shared.UpdateData(IntPtr pDW, Boolean AcceptData,
>Boolean ResetUpdateFlags)
> at Sybase.DataWindow.DataWindowControl.UpdateData()
> at ContracteAgro2005.frmImpachetari.button1_Click(Object sender,
>EventArgs e) in c:\proiectenet\contracte agro 2005\contracte
>agro\contracteagro2005\frmimpachetari.cs:line 340
> at System.Windows.Forms.Control.OnClick(EventArgs e)
> at System.Windows.Forms.Button.OnClick(EventArgs e)
> at System.Windows.Forms.Button.OnMouseUp(MouseEventArgs mevent)
> at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons
>button, Int32 clicks)
> at System.Windows.Forms.Control.WndProc(Message& m)
> at System.Windows.Forms.ButtonBase.WndProc(Message& m)
> at System.Windows.Forms.Button.WndProc(Message& m)
> at System.Windows.Forms.ControlNativeWindow.OnMessage(Message& m)
> at System.Windows.Forms.ControlNativeWindow.WndProc(Message& m)
> at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg,
>IntPtr wparam, IntPtr lparam)


Savita Bangera Posted on 2005-01-05 13:47:23.0Z
Sender: 7df2.41dbef8e.1804289383@sybase.com
From: Savita Bangera
Newsgroups: sybase.public.datawindow.net
Subject: Re: DataWindow Updates
X-Mailer: WebNews to Mail Gateway v1.1t
Message-ID: <41dbefe6.7df9.1681692777@sybase.com>
References: <fmshk0de3cuujipuk6695imr3f210bbh2g@4ax.com>
X-Original-NNTP-Posting-Host: 10.22.241.42
X-Original-Trace: 5 Jan 2005 05:47:18 -0800, 10.22.241.42
Lines: 51
X-Original-NNTP-Posting-Host: forums-2-dub.sybase.com
X-Original-Trace: 5 Jan 2005 05:47:19 -0800, forums-2-dub.sybase.com
NNTP-Posting-Host: forums-master.sybase.com
X-Original-NNTP-Posting-Host: forums-master.sybase.com
Date: 5 Jan 2005 05:47:23 -0800
X-Trace: forums-1-dub 1104932843 10.22.108.75 (5 Jan 2005 05:47:23 -0800)
X-Original-Trace: 5 Jan 2005 05:47:23 -0800, forums-master.sybase.com
X-Authenticated-User: ngsysop
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub sybase.public.datawindow.net:1209
Article PK: 125633

Doe sthis mean that till next EBF releases, datawindow.net
can be used only with direct table updates and will not
support updates using stored procedures?

Please Reply ASAP

Thanks in advance.

-Savita

> Ok, I've reproduced this - although I get a different
> exception, which seems a bit odd, and engineering is
> seeing it too. I'm not quite sure when we'd have a fix
> available though.
>
> On 14 Sep 2004 23:32:43 -0700, "Evdin N. URSAN"
> <evdin.ursan@aectra.ro> wrote:
>
> >Yes! In the Datawindow designer, the update process works
> just fine. >
> >The full error is (I think is the same as JonD's):
> >
> >System.NullReferenceException: Object reference not set
> to an instance of an >object.
> > at DataWindowInterop.SemanticFunctions.Update(IntPtr
> given_DW, Boolean >AcceptData, Boolean ResetUpdateFlags)
> > at Sybase.DataWindow.Shared.UpdateData(IntPtr pDW,
> Boolean AcceptData, >Boolean ResetUpdateFlags)
> > at Sybase.DataWindow.DataWindowControl.UpdateData()
> > at
> ContracteAgro2005.frmImpachetari.button1_Click(Object
> sender, >EventArgs e) in c:\proiectenet\contracte agro
> 2005\contracte
> > >agro\contracteagro2005\frmimpachetari.cs:line 340 at
> > System.Windows.Forms.Control.OnClick(EventArgs e) at
> > System.Windows.Forms.Button.OnClick(EventArgs e) at
> System.Windows.Forms.Button.OnMouseUp(MouseEventArgs
> > mevent) at
> System.Windows.Forms.Control.WmMouseUp(Message& m,
> MouseButtons >button, Int32 clicks)
> > at System.Windows.Forms.Control.WndProc(Message& m)
> > at System.Windows.Forms.ButtonBase.WndProc(Message& m)
> > at System.Windows.Forms.Button.WndProc(Message& m)
> > at
> System.Windows.Forms.ControlNativeWindow.OnMessage(Message
> > & m) at
> System.Windows.Forms.ControlNativeWindow.WndProc(Message&
> > m) at
> System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd,
> Int32 msg, >IntPtr wparam, IntPtr lparam)
>


Jim O'Neil [Sybase] Posted on 2005-01-05 21:27:00.0Z
From: "Jim O'Neil [Sybase]" <joneil_at_sybase_dot_com>
Newsgroups: sybase.public.datawindow.net
Subject: Re: DataWindow Updates
Message-ID: <nrmot09udbgs5gicgi6clo1h969ilhffhq@4ax.com>
References: <fmshk0de3cuujipuk6695imr3f210bbh2g@4ax.com> <41dbefe6.7df9.1681692777@sybase.com>
X-Newsreader: Forte Agent 2.0/32.652
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
X-Original-NNTP-Posting-Host: joneilw2k.sybase.com
X-Original-Trace: 5 Jan 2005 13:26:58 -0800, joneilw2k.sybase.com
Lines: 57
X-Original-NNTP-Posting-Host: forums-2-dub.sybase.com
X-Original-Trace: 5 Jan 2005 13:26:59 -0800, forums-2-dub.sybase.com
NNTP-Posting-Host: forums-master.sybase.com
X-Original-NNTP-Posting-Host: forums-master.sybase.com
Date: 5 Jan 2005 13:27:00 -0800
X-Trace: forums-1-dub 1104960420 10.22.108.75 (5 Jan 2005 13:27:00 -0800)
X-Original-Trace: 5 Jan 2005 13:27:00 -0800, forums-master.sybase.com
X-Authenticated-User: ngsysop
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub sybase.public.datawindow.net:1211
Article PK: 125637

I'm pretty sure this is resovled in the 10.0.1 EBF for PowerBuilder,
within which you can get the DW.NET EBF as well.

On 5 Jan 2005 05:47:23 -0800, Savita Bangera wrote:

>Doe sthis mean that till next EBF releases, datawindow.net
>can be used only with direct table updates and will not
>support updates using stored procedures?
>
>Please Reply ASAP
>
>Thanks in advance.
>
>-Savita
>
>> Ok, I've reproduced this - although I get a different
>> exception, which seems a bit odd, and engineering is
>> seeing it too. I'm not quite sure when we'd have a fix
>> available though.
>>
>> On 14 Sep 2004 23:32:43 -0700, "Evdin N. URSAN"
>> <evdin.ursan@aectra.ro> wrote:
>>
>> >Yes! In the Datawindow designer, the update process works
>> just fine. >
>> >The full error is (I think is the same as JonD's):
>> >
>> >System.NullReferenceException: Object reference not set
>> to an instance of an >object.
>> > at DataWindowInterop.SemanticFunctions.Update(IntPtr
>> given_DW, Boolean >AcceptData, Boolean ResetUpdateFlags)
>> > at Sybase.DataWindow.Shared.UpdateData(IntPtr pDW,
>> Boolean AcceptData, >Boolean ResetUpdateFlags)
>> > at Sybase.DataWindow.DataWindowControl.UpdateData()
>> > at
>> ContracteAgro2005.frmImpachetari.button1_Click(Object
>> sender, >EventArgs e) in c:\proiectenet\contracte agro
>> 2005\contracte
>> > >agro\contracteagro2005\frmimpachetari.cs:line 340 at
>> > System.Windows.Forms.Control.OnClick(EventArgs e) at
>> > System.Windows.Forms.Button.OnClick(EventArgs e) at
>> System.Windows.Forms.Button.OnMouseUp(MouseEventArgs
>> > mevent) at
>> System.Windows.Forms.Control.WmMouseUp(Message& m,
>> MouseButtons >button, Int32 clicks)
>> > at System.Windows.Forms.Control.WndProc(Message& m)
>> > at System.Windows.Forms.ButtonBase.WndProc(Message& m)
>> > at System.Windows.Forms.Button.WndProc(Message& m)
>> > at
>> System.Windows.Forms.ControlNativeWindow.OnMessage(Message
>> > & m) at
>> System.Windows.Forms.ControlNativeWindow.WndProc(Message&
>> > m) at
>> System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd,
>> Int32 msg, >IntPtr wparam, IntPtr lparam)
>>


David Avera Posted on 2004-09-17 15:55:31.0Z
From: "David Avera" <davera@sybase.com>
Newsgroups: sybase.public.datawindow.net
References: <4146cc6f.7e0.1681692777@sybase.com>
Subject: Re: DataWindow Updates
Lines: 29
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1437
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1441
X-Original-NNTP-Posting-Host: vpn-concord-193.sybase.com
Message-ID: <414b0ab4$1@forums-2-dub>
X-Original-Trace: 17 Sep 2004 09:03:00 -0700, vpn-concord-193.sybase.com
X-Original-NNTP-Posting-Host: forums-2-dub.sybase.com
X-Original-Trace: 17 Sep 2004 08:43:12 -0700, forums-2-dub.sybase.com
NNTP-Posting-Host: forums-master.sybase.com
X-Original-NNTP-Posting-Host: forums-master.sybase.com
Date: 17 Sep 2004 08:55:31 -0700
X-Trace: forums-1-dub 1095436531 10.22.108.75 (17 Sep 2004 08:55:31 -0700)
X-Original-Trace: 17 Sep 2004 08:55:31 -0700, forums-master.sybase.com
X-Authenticated-User: ngsysop
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub sybase.public.datawindow.net:394
Article PK: 124823

This bug has been fixed and should be available in the next available EBF

<Jon D> wrote in message news:4146cc6f.7e0.1681692777@sybase.com...
> Hi, Should I be able to update my database with stored
> procedures when I originally retrieved the data via a stored
> procedure ?
>
> This does not seem to work ! I've defined my update SP's but
> get an error when trying to do an UpdateDate method.
>
> This is a realistic thing that one would want to do isn't
> it?
>
> The reason I've got a doubt in my mind is the statement on
> page 188 of the DataWindow Designer User guide which says :
>
> 'If the datasource is a stored proceedure or external, you
> can use the FindNextModifiedRowmethod to write your own
> update code.'
>
> Surely if you retrieve via a stored procedure , you should
> be able to specify update SP's and use the UpdateData
> method.
>
> Thanks
>
> Jon


Datawindow update bug Posted on 2004-09-21 11:46:29.0Z
Sender: 95c.415002d8.1804289383@sybase.com
From: Datawindow update bug
Newsgroups: sybase.public.datawindow.net
Subject: Re: DataWindow Updates
X-Mailer: WebNews to Mail Gateway v1.1t
Message-ID: <41501495.afd.1681692777@sybase.com>
References: <414b0ab4$1@forums-2-dub>
NNTP-Posting-Host: 10.22.241.41
X-Original-NNTP-Posting-Host: 10.22.241.41
Date: 21 Sep 2004 04:46:29 -0700
X-Trace: forums-1-dub 1095767189 10.22.241.41 (21 Sep 2004 04:46:29 -0700)
X-Original-Trace: 21 Sep 2004 04:46:29 -0700, 10.22.241.41
Lines: 7
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub sybase.public.datawindow.net:413
Article PK: 124843

David,

Thanks for that info, look forward to the ebf release.

> This bug has been fixed and should be available in the
> next available EBF
>