Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 help in Visual basic

Author  Topic 

bashka_abdyli
Starting Member

15 Posts

Posted - 2003-07-16 : 03:02:35
This statement doesnt give back any result in Visual Basic on SQL
QUERY ANALYZER it returns "select * from @tab" how to make this a stored procedure


declare @tab table (idur int, data_val smalldatetime, [description] char(200), debi numeric(16,2), kredi numeric(8,2), cum numeric(8,2))
insert into @tab select idur,data_val,description,debi,kredi,0 as cum from transaksionet where partia = '0001' order by data_val,idur,brloc
declare @cum numeric(16,2)
set @cum = 0
update @tab
set @cum = cum = @cum + kredi - debi
select * from @tab

mr_mist
Grunnio

1870 Posts

Posted - 2003-07-16 : 03:07:24

set nocount on
declare @tab table (idur int, data_val smalldatetime, [description] char(200), debi numeric(16,2), kredi numeric(8,2), cum numeric(8,2))
insert into @tab select idur,data_val,description,debi,kredi,0 as cum from transaksionet where partia = '0001' order by data_val,idur,brloc
declare @cum numeric(16,2)
set @cum = 0
update @tab
set @cum = cum = @cum + kredi - debi
set nocount off
select * from @tab




-------
Moo. :)
Go to Top of Page

bashka_abdyli
Starting Member

15 Posts

Posted - 2003-07-16 : 03:26:32
thanks man

Go to Top of Page
   

- Advertisement -