Re: delete row query doesn't remove all row when run from access (ms sql)
- From: "Xav" <xavier.goulay@xxxxxxxxxxxxxxxxxxxxxxxx>
- Date: 9 Aug 2006 10:24:41 -0700
This is the procedure run:
ALTER PROCEDURE usp_delete_dataByDate
@dDate AS SMALLDATETIME
AS
DELETE FROM _settings_date WHERE [date] = @dDate
and there is a trigger on _settings_date:
ALTER TRIGGER [Trigger Update _settings_date]
ON _settings_date
FOR DELETE
AS
SET NOCOUNT ON
DECLARE @dDate AS SMALLDATETIME
SELECT @dDate = [date] FROM deleted
DELETE FROM ut_t1 WHERE [data_date] = @dDate
DELETE FROM ut_t2 WHERE [data_date] = @dDate
DELETE FROM ut_t3 WHERE [data_date] = @dDate
DELETE FROM ut_t4 WHERE [data_date] = @dDate
If the proc is run from Query Analyzer it works fine but form access
some entries matching the date criteria still appear.
[MVP] S.Clark wrote:
Post the SQL. The joins and the WHERE clause dictate what records are
involved, so that should give us a hint.
--
Steve Clark, Access MVP
FMS, Inc
http://www.fmsinc.com/consulting
Professional Access Database Repair
*FREE* Access Tips: http://www.fmsinc.com/free/tips.html
<xavier.goulay@xxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:1154602559.476921.175370@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Hi,
I have a stored procedure which delete rows from a table for a specific
date. When I run the query from Query Analyzer it does work perfectly.
But when I run the query from the corresponding adp project some rows
matching the delete criteria (by date) are still existing. It seems
that adp apply the query only to the visible rows (the ones we can see
in the datagrid). Is there any way to get it applied on the all set of
rows from access?
Thanks
.
- References:
- delete row query doesn't remove all row when run from access (ms sql)
- From: xavier . goulay
- Re: delete row query doesn't remove all row when run from access (ms sql)
- From: [MVP] S.Clark
- delete row query doesn't remove all row when run from access (ms sql)
- Prev by Date: Query Return Reocrds for only the current Date.
- Next by Date: Re: Join Problem
- Previous by thread: Re: delete row query doesn't remove all row when run from access (ms sql)
- Next by thread: Re: why do I get all fields from table, not just the ones requested ?
- Index(es):
Relevant Pages
|