What tool are you using?
>--Original Message--
>I have a table wherein previous entries on some rows were
deleted but the
>fields doesn't go away ex.
>tbl_name (one column table only)
>row1 name 1
>row2 (the entry is deleted but this is still showing a
blank space)
>row3 (the entry is deleted but this is still showing a
blank space)
>row4 (the entry is deleted but this is still showing a
blank space)
>row5 name 2
>How do i delete rows 2-4 in tbl_name so that it will only
show two entries
>row1 and row5 which should move into position 2 basically
deleting rows 2-4
>which contains no data and wont allow me to enter data in
them?
>thanks....
>.
>
When you delete the rows, it sounds to me like you are really only updating
the value of the data to a blank rather than actually removing the row.
The procedure in your application is probably doing an update like:
UPDATE tblName
SET columnName = ''
WHERE columnName = '<some criteria>'
The procedure in your application should be doing a DELETE like:
DELETE tblName
WHERE columnName = '<some criteria>'
To get rid of the currently empty rows, you could run something like:
DELETE tblName
WHERE LENGTH(columnName) = 0
HTH
Rick Sawtell
MCT, MCSD, MCDBA
"ChrisR" <anonymous@.discussions.microsoft.com> wrote in message
news:08ff01c47afa$4c7e3a10$a301280a@.phx.gbl...[vbcol=seagreen]
> What tool are you using?
> deleted but the
> blank space)
> blank space)
> blank space)
> show two entries
> deleting rows 2-4
> them?
sql
Showing posts with label previous. Show all posts
Showing posts with label previous. Show all posts
Thursday, March 29, 2012
Deleting rows
Labels:
database,
deleting,
entries,
message-gti,
microsoft,
mysql,
oracle,
previous,
rows,
server,
sql,
table,
thegtfields,
tool,
usinggt-original,
weredeleted,
wherein
Deleting rows
What tool are you using?
>--Original Message--
>I have a table wherein previous entries on some rows were
deleted but the
>fields doesn't go away ex.
>tbl_name (one column table only)
>row1 name 1
>row2 (the entry is deleted but this is still showing a
blank space)
>row3 (the entry is deleted but this is still showing a
blank space)
>row4 (the entry is deleted but this is still showing a
blank space)
>row5 name 2
>How do i delete rows 2-4 in tbl_name so that it will only
show two entries
>row1 and row5 which should move into position 2 basically
deleting rows 2-4
>which contains no data and wont allow me to enter data in
them?
>thanks....
>.
>When you delete the rows, it sounds to me like you are really only updating
the value of the data to a blank rather than actually removing the row.
The procedure in your application is probably doing an update like:
UPDATE tblName
SET columnName = ''
WHERE columnName = '<some criteria>'
The procedure in your application should be doing a DELETE like:
DELETE tblName
WHERE columnName = '<some criteria>'
To get rid of the currently empty rows, you could run something like:
DELETE tblName
WHERE LENGTH(columnName) = 0
HTH
Rick Sawtell
MCT, MCSD, MCDBA
"ChrisR" <anonymous@.discussions.microsoft.com> wrote in message
news:08ff01c47afa$4c7e3a10$a301280a@.phx.gbl...[vbcol=seagreen]
> What tool are you using?
>
> deleted but the
> blank space)
> blank space)
> blank space)
> show two entries
> deleting rows 2-4
> them?
>--Original Message--
>I have a table wherein previous entries on some rows were
deleted but the
>fields doesn't go away ex.
>tbl_name (one column table only)
>row1 name 1
>row2 (the entry is deleted but this is still showing a
blank space)
>row3 (the entry is deleted but this is still showing a
blank space)
>row4 (the entry is deleted but this is still showing a
blank space)
>row5 name 2
>How do i delete rows 2-4 in tbl_name so that it will only
show two entries
>row1 and row5 which should move into position 2 basically
deleting rows 2-4
>which contains no data and wont allow me to enter data in
them?
>thanks....
>.
>When you delete the rows, it sounds to me like you are really only updating
the value of the data to a blank rather than actually removing the row.
The procedure in your application is probably doing an update like:
UPDATE tblName
SET columnName = ''
WHERE columnName = '<some criteria>'
The procedure in your application should be doing a DELETE like:
DELETE tblName
WHERE columnName = '<some criteria>'
To get rid of the currently empty rows, you could run something like:
DELETE tblName
WHERE LENGTH(columnName) = 0
HTH
Rick Sawtell
MCT, MCSD, MCDBA
"ChrisR" <anonymous@.discussions.microsoft.com> wrote in message
news:08ff01c47afa$4c7e3a10$a301280a@.phx.gbl...[vbcol=seagreen]
> What tool are you using?
>
> deleted but the
> blank space)
> blank space)
> blank space)
> show two entries
> deleting rows 2-4
> them?
Labels:
database,
deleting,
entries,
message-gti,
microsoft,
mysql,
oracle,
previous,
rows,
server,
sql,
table,
thegtfields,
tool,
usinggt-original,
weredeleted,
wherein
Friday, February 17, 2012
Delete previous backup in append mode sql 2000
i have set backup of userdatabases in append mode every day
its possible to remove backups of a previous date using a stored
procedureAre you saying that you append to the same backup device and now want to ove
rwrite only some of the
backups on that backup device? If so, the answer is "no". It is all or nothi
ng.
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"Arejan" <areejan2000@.yahoo.com> wrote in message
news:1165601458.685473.96490@.j72g2000cwa.googlegroups.com...
>i have set backup of userdatabases in append mode every day
> its possible to remove backups of a previous date using a stored
> procedure
>
its possible to remove backups of a previous date using a stored
procedureAre you saying that you append to the same backup device and now want to ove
rwrite only some of the
backups on that backup device? If so, the answer is "no". It is all or nothi
ng.
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"Arejan" <areejan2000@.yahoo.com> wrote in message
news:1165601458.685473.96490@.j72g2000cwa.googlegroups.com...
>i have set backup of userdatabases in append mode every day
> its possible to remove backups of a previous date using a stored
> procedure
>
Delete previous backup in append mode sql 2000
i have set backup of userdatabases in append mode every day
its possible to remove backups of a previous date using a stored
procedure
writing the backup daily to hdd
whats the better option so that the file size is maintained ,can only
use append mode
as i might want to restore to 2/ 3 days previous data
its possible to remove backups of a previous date using a stored
procedure
writing the backup daily to hdd
whats the better option so that the file size is maintained ,can only
use append mode
as i might want to restore to 2/ 3 days previous data
Delete previous backup in append mode sql 2000
i have set backup of userdatabases in append mode every day
its possible to remove backups of a previous date using a stored
procedureAre you saying that you append to the same backup device and now want to overwrite only some of the
backups on that backup device? If so, the answer is "no". It is all or nothing.
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"Arejan" <areejan2000@.yahoo.com> wrote in message
news:1165601458.685473.96490@.j72g2000cwa.googlegroups.com...
>i have set backup of userdatabases in append mode every day
> its possible to remove backups of a previous date using a stored
> procedure
>|||writing the backup daily to hdd
whats the better option so that the file size is maintained ,can only
use append mode
as i might want to restore to 2/ 3 days previous data|||Using Append you will never be able to keep exactly three (or two, or
six) copies of your backup. Rather than using append modeUse a
different file name each day, perhaps with the date as part of the
file name.
Roy
On 10 Dec 2006 21:15:08 -0800, "Arejan" <areejan2000@.yahoo.com> wrote:
>writing the backup daily to hdd
>whats the better option so that the file size is maintained ,can only
>use append mode
>as i might want to restore to 2/ 3 days previous data
its possible to remove backups of a previous date using a stored
procedureAre you saying that you append to the same backup device and now want to overwrite only some of the
backups on that backup device? If so, the answer is "no". It is all or nothing.
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"Arejan" <areejan2000@.yahoo.com> wrote in message
news:1165601458.685473.96490@.j72g2000cwa.googlegroups.com...
>i have set backup of userdatabases in append mode every day
> its possible to remove backups of a previous date using a stored
> procedure
>|||writing the backup daily to hdd
whats the better option so that the file size is maintained ,can only
use append mode
as i might want to restore to 2/ 3 days previous data|||Using Append you will never be able to keep exactly three (or two, or
six) copies of your backup. Rather than using append modeUse a
different file name each day, perhaps with the date as part of the
file name.
Roy
On 10 Dec 2006 21:15:08 -0800, "Arejan" <areejan2000@.yahoo.com> wrote:
>writing the backup daily to hdd
>whats the better option so that the file size is maintained ,can only
>use append mode
>as i might want to restore to 2/ 3 days previous data
Subscribe to:
Posts (Atom)