Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

how to force data into SP and recognized by crystal report

Status
Not open for further replies.

francesguan

Technical User
Jan 26, 2006
52
CA
Hi,
I am creating Order Verification report(OV) which for shooting out automatically by Visual Cut. in the Stored procedure for OV,I am trying to force the data into a table:FR_OVLog and delete the data from another table:FR_OV; so every time report running, it will delete data from table FR_OV and add whatever shown in the report to table FR_OVLog;

please note in the following whenever I add insert and delete lines inside, crystal report won't be able to recognize the sp any more, but sql could be excuted successfully.

any comments would be greatly appreciated.

Frances

---------------------------------------



the structure in this SP:

open CoAllcrs --cursor for co_all table
.....
open coItemAllcrs--cursor for coitem_all table
.....
insert into FR_OVLog(co_num,co_line,co_release)
select @CoCoNum, @CoitemCoLine, @CoitemCorelease from @ReportSet
delete from FR_OrderVerification where FR_OrderVerification.co_num=@CoCoNum and FR_OrderVerification.co_line=@CoitemCoLine and FR_OrderVerification.co_release=@CoitemCorelease
....

close coItemAllcrs
.....
close CoAllcrs

SELECT *
FROM @ReportSet
.....
EXIT_SP:
....
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top