is there any way of opening an MDf file into some sort of
readable format? we had our server crash on us and the
backup/ restore is not working. I only have the mdf file
for the database and was wondering if i could get this
into some sort of formatting i could open and manually add
our old database back in as it only had a few details in.
thanks
simon
Hi
No. Have you tried sp_attach_single_file_db?
Failing that, phone MS PSS.
Regards
Mike Epprecht, Microsoft SQL Server MVP
Zurich, Switzerland
IM: mike@.epprecht.net
MVP Program: http://www.microsoft.com/mvp
Blog: http://www.msmvps.com/epprecht/
"Simon" <simon@.talktalk.net> wrote in message
news:13d001c515ac$a8337530$a401280a@.phx.gbl...
> is there any way of opening an MDf file into some sort of
> readable format? we had our server crash on us and the
> backup/ restore is not working. I only have the mdf file
> for the database and was wondering if i could get this
> into some sort of formatting i could open and manually add
> our old database back in as it only had a few details in.
> thanks
> simon
|||thanks mike, i have tried sp_attach_single_file_db but
without joy.
we have had to reinstall the OS and SQL and this was the
only file we had a good copy of.
i will try Ms PSS thanks.[vbcol=seagreen]
>--Original Message--
>Hi
>No. Have you tried sp_attach_single_file_db?
>Failing that, phone MS PSS.
>Regards
>--
>Mike Epprecht, Microsoft SQL Server MVP
>Zurich, Switzerland
>IM: mike@.epprecht.net
>MVP Program: http://www.microsoft.com/mvp
>Blog: http://www.msmvps.com/epprecht/
>"Simon" <simon@.talktalk.net> wrote in message
>news:13d001c515ac$a8337530$a401280a@.phx.gbl...
of[vbcol=seagreen]
add[vbcol=seagreen]
in.
>
>.
>
|||Just out of curiosity, what problem do you encounter when you try to
re-attach the MDF? The following article explains other issues related to
restoring a DB on another server install:
http://support.microsoft.com/kb/314546#10
<anonymous@.discussions.microsoft.com> wrote in message
news:13f201c515b2$0691fd40$a401280a@.phx.gbl...[vbcol=seagreen]
> thanks mike, i have tried sp_attach_single_file_db but
> without joy.
> we have had to reinstall the OS and SQL and this was the
> only file we had a good copy of.
> i will try Ms PSS thanks.
> of
> add
> in.
|||Hi Johnny
An sp_attach_single_file_db is only guarenteed to work is
an sp_detach_db is used, otherwise its a bit of a lottery
whether it works or not.
http://msdn.microsoft.com/library/default.asp?
url=/library/en-us/tsqlref/ts_sp_ae-az_4wrm.asp
Peter
"I may be drunk, Miss, but in the morning I will be sober
and you will still be ugly."
Winston Churchill
>--Original Message--
>Just out of curiosity, what problem do you encounter when
you try to
>re-attach the MDF? The following article explains other
issues related to[vbcol=seagreen]
>restoring a DB on another server install:
>http://support.microsoft.com/kb/314546#10
><anonymous@.discussions.microsoft.com> wrote in message
>news:13f201c515b2$0691fd40$a401280a@.phx.gbl...
sort[vbcol=seagreen]
the[vbcol=seagreen]
file[vbcol=seagreen]
this[vbcol=seagreen]
manually
>
>.
>
Showing posts with label sort. Show all posts
Showing posts with label sort. Show all posts
Friday, March 23, 2012
Read MDF
is there any way of opening an MDf file into some sort of
readable format? we had our server crash on us and the
backup/ restore is not working. I only have the mdf file
for the database and was wondering if i could get this
into some sort of formatting i could open and manually add
our old database back in as it only had a few details in.
thanks
simonHi
No. Have you tried sp_attach_single_file_db?
Failing that, phone MS PSS.
Regards
--
Mike Epprecht, Microsoft SQL Server MVP
Zurich, Switzerland
IM: mike@.epprecht.net
MVP Program: http://www.microsoft.com/mvp
Blog: http://www.msmvps.com/epprecht/
"Simon" <simon@.talktalk.net> wrote in message
news:13d001c515ac$a8337530$a401280a@.phx.gbl...
> is there any way of opening an MDf file into some sort of
> readable format? we had our server crash on us and the
> backup/ restore is not working. I only have the mdf file
> for the database and was wondering if i could get this
> into some sort of formatting i could open and manually add
> our old database back in as it only had a few details in.
> thanks
> simon|||thanks mike, i have tried sp_attach_single_file_db but
without joy.
we have had to reinstall the OS and SQL and this was the
only file we had a good copy of.
i will try Ms PSS thanks.
>--Original Message--
>Hi
>No. Have you tried sp_attach_single_file_db?
>Failing that, phone MS PSS.
>Regards
>--
>Mike Epprecht, Microsoft SQL Server MVP
>Zurich, Switzerland
>IM: mike@.epprecht.net
>MVP Program: http://www.microsoft.com/mvp
>Blog: http://www.msmvps.com/epprecht/
>"Simon" <simon@.talktalk.net> wrote in message
>news:13d001c515ac$a8337530$a401280a@.phx.gbl...
>> is there any way of opening an MDf file into some sort
of
>> readable format? we had our server crash on us and the
>> backup/ restore is not working. I only have the mdf file
>> for the database and was wondering if i could get this
>> into some sort of formatting i could open and manually
add
>> our old database back in as it only had a few details
in.
>> thanks
>> simon
>
>.
>|||Just out of curiosity, what problem do you encounter when you try to
re-attach the MDF? The following article explains other issues related to
restoring a DB on another server install:
http://support.microsoft.com/kb/314546#10
<anonymous@.discussions.microsoft.com> wrote in message
news:13f201c515b2$0691fd40$a401280a@.phx.gbl...
> thanks mike, i have tried sp_attach_single_file_db but
> without joy.
> we have had to reinstall the OS and SQL and this was the
> only file we had a good copy of.
> i will try Ms PSS thanks.
> >--Original Message--
> >Hi
> >
> >No. Have you tried sp_attach_single_file_db?
> >Failing that, phone MS PSS.
> >
> >Regards
> >--
> >Mike Epprecht, Microsoft SQL Server MVP
> >Zurich, Switzerland
> >
> >IM: mike@.epprecht.net
> >
> >MVP Program: http://www.microsoft.com/mvp
> >
> >Blog: http://www.msmvps.com/epprecht/
> >
> >"Simon" <simon@.talktalk.net> wrote in message
> >news:13d001c515ac$a8337530$a401280a@.phx.gbl...
> >> is there any way of opening an MDf file into some sort
> of
> >> readable format? we had our server crash on us and the
> >> backup/ restore is not working. I only have the mdf file
> >> for the database and was wondering if i could get this
> >> into some sort of formatting i could open and manually
> add
> >> our old database back in as it only had a few details
> in.
> >>
> >> thanks
> >>
> >> simon
> >
> >
> >.
> >|||Hi Johnny
An sp_attach_single_file_db is only guarenteed to work is
an sp_detach_db is used, otherwise its a bit of a lottery
whether it works or not.
http://msdn.microsoft.com/library/default.asp?
url=/library/en-us/tsqlref/ts_sp_ae-az_4wrm.asp
Peter
"I may be drunk, Miss, but in the morning I will be sober
and you will still be ugly."
Winston Churchill
>--Original Message--
>Just out of curiosity, what problem do you encounter when
you try to
>re-attach the MDF? The following article explains other
issues related to
>restoring a DB on another server install:
>http://support.microsoft.com/kb/314546#10
><anonymous@.discussions.microsoft.com> wrote in message
>news:13f201c515b2$0691fd40$a401280a@.phx.gbl...
>> thanks mike, i have tried sp_attach_single_file_db but
>> without joy.
>> we have had to reinstall the OS and SQL and this was the
>> only file we had a good copy of.
>> i will try Ms PSS thanks.
>> >--Original Message--
>> >Hi
>> >
>> >No. Have you tried sp_attach_single_file_db?
>> >Failing that, phone MS PSS.
>> >
>> >Regards
>> >--
>> >Mike Epprecht, Microsoft SQL Server MVP
>> >Zurich, Switzerland
>> >
>> >IM: mike@.epprecht.net
>> >
>> >MVP Program: http://www.microsoft.com/mvp
>> >
>> >Blog: http://www.msmvps.com/epprecht/
>> >
>> >"Simon" <simon@.talktalk.net> wrote in message
>> >news:13d001c515ac$a8337530$a401280a@.phx.gbl...
>> >> is there any way of opening an MDf file into some
sort
>> of
>> >> readable format? we had our server crash on us and
the
>> >> backup/ restore is not working. I only have the mdf
file
>> >> for the database and was wondering if i could get
this
>> >> into some sort of formatting i could open and
manually
>> add
>> >> our old database back in as it only had a few details
>> in.
>> >>
>> >> thanks
>> >>
>> >> simon
>> >
>> >
>> >.
>> >
>
>.
>
readable format? we had our server crash on us and the
backup/ restore is not working. I only have the mdf file
for the database and was wondering if i could get this
into some sort of formatting i could open and manually add
our old database back in as it only had a few details in.
thanks
simonHi
No. Have you tried sp_attach_single_file_db?
Failing that, phone MS PSS.
Regards
--
Mike Epprecht, Microsoft SQL Server MVP
Zurich, Switzerland
IM: mike@.epprecht.net
MVP Program: http://www.microsoft.com/mvp
Blog: http://www.msmvps.com/epprecht/
"Simon" <simon@.talktalk.net> wrote in message
news:13d001c515ac$a8337530$a401280a@.phx.gbl...
> is there any way of opening an MDf file into some sort of
> readable format? we had our server crash on us and the
> backup/ restore is not working. I only have the mdf file
> for the database and was wondering if i could get this
> into some sort of formatting i could open and manually add
> our old database back in as it only had a few details in.
> thanks
> simon|||thanks mike, i have tried sp_attach_single_file_db but
without joy.
we have had to reinstall the OS and SQL and this was the
only file we had a good copy of.
i will try Ms PSS thanks.
>--Original Message--
>Hi
>No. Have you tried sp_attach_single_file_db?
>Failing that, phone MS PSS.
>Regards
>--
>Mike Epprecht, Microsoft SQL Server MVP
>Zurich, Switzerland
>IM: mike@.epprecht.net
>MVP Program: http://www.microsoft.com/mvp
>Blog: http://www.msmvps.com/epprecht/
>"Simon" <simon@.talktalk.net> wrote in message
>news:13d001c515ac$a8337530$a401280a@.phx.gbl...
>> is there any way of opening an MDf file into some sort
of
>> readable format? we had our server crash on us and the
>> backup/ restore is not working. I only have the mdf file
>> for the database and was wondering if i could get this
>> into some sort of formatting i could open and manually
add
>> our old database back in as it only had a few details
in.
>> thanks
>> simon
>
>.
>|||Just out of curiosity, what problem do you encounter when you try to
re-attach the MDF? The following article explains other issues related to
restoring a DB on another server install:
http://support.microsoft.com/kb/314546#10
<anonymous@.discussions.microsoft.com> wrote in message
news:13f201c515b2$0691fd40$a401280a@.phx.gbl...
> thanks mike, i have tried sp_attach_single_file_db but
> without joy.
> we have had to reinstall the OS and SQL and this was the
> only file we had a good copy of.
> i will try Ms PSS thanks.
> >--Original Message--
> >Hi
> >
> >No. Have you tried sp_attach_single_file_db?
> >Failing that, phone MS PSS.
> >
> >Regards
> >--
> >Mike Epprecht, Microsoft SQL Server MVP
> >Zurich, Switzerland
> >
> >IM: mike@.epprecht.net
> >
> >MVP Program: http://www.microsoft.com/mvp
> >
> >Blog: http://www.msmvps.com/epprecht/
> >
> >"Simon" <simon@.talktalk.net> wrote in message
> >news:13d001c515ac$a8337530$a401280a@.phx.gbl...
> >> is there any way of opening an MDf file into some sort
> of
> >> readable format? we had our server crash on us and the
> >> backup/ restore is not working. I only have the mdf file
> >> for the database and was wondering if i could get this
> >> into some sort of formatting i could open and manually
> add
> >> our old database back in as it only had a few details
> in.
> >>
> >> thanks
> >>
> >> simon
> >
> >
> >.
> >|||Hi Johnny
An sp_attach_single_file_db is only guarenteed to work is
an sp_detach_db is used, otherwise its a bit of a lottery
whether it works or not.
http://msdn.microsoft.com/library/default.asp?
url=/library/en-us/tsqlref/ts_sp_ae-az_4wrm.asp
Peter
"I may be drunk, Miss, but in the morning I will be sober
and you will still be ugly."
Winston Churchill
>--Original Message--
>Just out of curiosity, what problem do you encounter when
you try to
>re-attach the MDF? The following article explains other
issues related to
>restoring a DB on another server install:
>http://support.microsoft.com/kb/314546#10
><anonymous@.discussions.microsoft.com> wrote in message
>news:13f201c515b2$0691fd40$a401280a@.phx.gbl...
>> thanks mike, i have tried sp_attach_single_file_db but
>> without joy.
>> we have had to reinstall the OS and SQL and this was the
>> only file we had a good copy of.
>> i will try Ms PSS thanks.
>> >--Original Message--
>> >Hi
>> >
>> >No. Have you tried sp_attach_single_file_db?
>> >Failing that, phone MS PSS.
>> >
>> >Regards
>> >--
>> >Mike Epprecht, Microsoft SQL Server MVP
>> >Zurich, Switzerland
>> >
>> >IM: mike@.epprecht.net
>> >
>> >MVP Program: http://www.microsoft.com/mvp
>> >
>> >Blog: http://www.msmvps.com/epprecht/
>> >
>> >"Simon" <simon@.talktalk.net> wrote in message
>> >news:13d001c515ac$a8337530$a401280a@.phx.gbl...
>> >> is there any way of opening an MDf file into some
sort
>> of
>> >> readable format? we had our server crash on us and
the
>> >> backup/ restore is not working. I only have the mdf
file
>> >> for the database and was wondering if i could get
this
>> >> into some sort of formatting i could open and
manually
>> add
>> >> our old database back in as it only had a few details
>> in.
>> >>
>> >> thanks
>> >>
>> >> simon
>> >
>> >
>> >.
>> >
>
>.
>
Read MDF
is there any way of opening an MDf file into some sort of
readable format? we had our server crash on us and the
backup/ restore is not working. I only have the mdf file
for the database and was wondering if i could get this
into some sort of formatting i could open and manually add
our old database back in as it only had a few details in.
thanks
simonHi
No. Have you tried sp_attach_single_file_db?
Failing that, phone MS PSS.
Regards
--
Mike Epprecht, Microsoft SQL Server MVP
Zurich, Switzerland
IM: mike@.epprecht.net
MVP Program: http://www.microsoft.com/mvp
Blog: http://www.msmvps.com/epprecht/
"Simon" <simon@.talktalk.net> wrote in message
news:13d001c515ac$a8337530$a401280a@.phx.gbl...
> is there any way of opening an MDf file into some sort of
> readable format? we had our server crash on us and the
> backup/ restore is not working. I only have the mdf file
> for the database and was wondering if i could get this
> into some sort of formatting i could open and manually add
> our old database back in as it only had a few details in.
> thanks
> simon|||thanks mike, i have tried sp_attach_single_file_db but
without joy.
we have had to reinstall the OS and SQL and this was the
only file we had a good copy of.
i will try Ms PSS thanks.
>--Original Message--
>Hi
>No. Have you tried sp_attach_single_file_db?
>Failing that, phone MS PSS.
>Regards
>--
>Mike Epprecht, Microsoft SQL Server MVP
>Zurich, Switzerland
>IM: mike@.epprecht.net
>MVP Program: http://www.microsoft.com/mvp
>Blog: http://www.msmvps.com/epprecht/
>"Simon" <simon@.talktalk.net> wrote in message
>news:13d001c515ac$a8337530$a401280a@.phx.gbl...
of[vbcol=seagreen]
add[vbcol=seagreen]
in.[vbcol=seagreen]
>
>.
>|||Just out of curiosity, what problem do you encounter when you try to
re-attach the MDF? The following article explains other issues related to
restoring a DB on another server install:
http://support.microsoft.com/kb/314546#10
<anonymous@.discussions.microsoft.com> wrote in message
news:13f201c515b2$0691fd40$a401280a@.phx.gbl...[vbcol=seagreen]
> thanks mike, i have tried sp_attach_single_file_db but
> without joy.
> we have had to reinstall the OS and SQL and this was the
> only file we had a good copy of.
> i will try Ms PSS thanks.
> of
> add
> in.|||Hi Johnny
An sp_attach_single_file_db is only guarenteed to work is
an sp_detach_db is used, otherwise its a bit of a lottery
whether it works or not.
http://msdn.microsoft.com/library/default.asp?
url=/library/en-us/tsqlref/ts_sp_ae-az_4wrm.asp
Peter
"I may be drunk, Miss, but in the morning I will be sober
and you will still be ugly."
Winston Churchill
>--Original Message--
>Just out of curiosity, what problem do you encounter when
you try to
>re-attach the MDF? The following article explains other
issues related to
>restoring a DB on another server install:
>http://support.microsoft.com/kb/314546#10
><anonymous@.discussions.microsoft.com> wrote in message
>news:13f201c515b2$0691fd40$a401280a@.phx.gbl...
sort[vbcol=seagreen]
the[vbcol=seagreen]
file[vbcol=seagreen]
this[vbcol=seagreen]
manually[vbcol=seagreen]
>
>.
>
readable format? we had our server crash on us and the
backup/ restore is not working. I only have the mdf file
for the database and was wondering if i could get this
into some sort of formatting i could open and manually add
our old database back in as it only had a few details in.
thanks
simonHi
No. Have you tried sp_attach_single_file_db?
Failing that, phone MS PSS.
Regards
--
Mike Epprecht, Microsoft SQL Server MVP
Zurich, Switzerland
IM: mike@.epprecht.net
MVP Program: http://www.microsoft.com/mvp
Blog: http://www.msmvps.com/epprecht/
"Simon" <simon@.talktalk.net> wrote in message
news:13d001c515ac$a8337530$a401280a@.phx.gbl...
> is there any way of opening an MDf file into some sort of
> readable format? we had our server crash on us and the
> backup/ restore is not working. I only have the mdf file
> for the database and was wondering if i could get this
> into some sort of formatting i could open and manually add
> our old database back in as it only had a few details in.
> thanks
> simon|||thanks mike, i have tried sp_attach_single_file_db but
without joy.
we have had to reinstall the OS and SQL and this was the
only file we had a good copy of.
i will try Ms PSS thanks.
>--Original Message--
>Hi
>No. Have you tried sp_attach_single_file_db?
>Failing that, phone MS PSS.
>Regards
>--
>Mike Epprecht, Microsoft SQL Server MVP
>Zurich, Switzerland
>IM: mike@.epprecht.net
>MVP Program: http://www.microsoft.com/mvp
>Blog: http://www.msmvps.com/epprecht/
>"Simon" <simon@.talktalk.net> wrote in message
>news:13d001c515ac$a8337530$a401280a@.phx.gbl...
of[vbcol=seagreen]
add[vbcol=seagreen]
in.[vbcol=seagreen]
>
>.
>|||Just out of curiosity, what problem do you encounter when you try to
re-attach the MDF? The following article explains other issues related to
restoring a DB on another server install:
http://support.microsoft.com/kb/314546#10
<anonymous@.discussions.microsoft.com> wrote in message
news:13f201c515b2$0691fd40$a401280a@.phx.gbl...[vbcol=seagreen]
> thanks mike, i have tried sp_attach_single_file_db but
> without joy.
> we have had to reinstall the OS and SQL and this was the
> only file we had a good copy of.
> i will try Ms PSS thanks.
> of
> add
> in.|||Hi Johnny
An sp_attach_single_file_db is only guarenteed to work is
an sp_detach_db is used, otherwise its a bit of a lottery
whether it works or not.
http://msdn.microsoft.com/library/default.asp?
url=/library/en-us/tsqlref/ts_sp_ae-az_4wrm.asp
Peter
"I may be drunk, Miss, but in the morning I will be sober
and you will still be ugly."
Winston Churchill
>--Original Message--
>Just out of curiosity, what problem do you encounter when
you try to
>re-attach the MDF? The following article explains other
issues related to
>restoring a DB on another server install:
>http://support.microsoft.com/kb/314546#10
><anonymous@.discussions.microsoft.com> wrote in message
>news:13f201c515b2$0691fd40$a401280a@.phx.gbl...
sort[vbcol=seagreen]
the[vbcol=seagreen]
file[vbcol=seagreen]
this[vbcol=seagreen]
manually[vbcol=seagreen]
>
>.
>
Tuesday, March 20, 2012
Re sort
Hi all
I Have Table Num As Int , Name As NvarChar(20) I Need Trigger to Resort The
Field Num When I Change The num
Num Name
1 aaaaa
2 bbbbb
3 cccccc
4 ddddd
I Want when I Change the Num 1 To 2 Came Like
Num Name
1 bbbbb
2 aaaaaa
3 cccccc
4 ddddd
Re sort The Num In Trigger
Thankswhat are you talking about? Sorting is done at query time, by specifying a
sort order.
"Taha" <taha105@.hotmail.com> wrote in message
news:%23%23nlsb9jGHA.4512@.TK2MSFTNGP04.phx.gbl...
> Hi all
>
> I Have Table Num As Int , Name As NvarChar(20) I Need Trigger to Resort
> The Field Num When I Change The num
>
> Num Name
> 1 aaaaa
> 2 bbbbb
> 3 cccccc
> 4 ddddd
>
> I Want when I Change the Num 1 To 2 Came Like
>
> Num Name
> 1 bbbbb
> 2 aaaaaa
> 3 cccccc
> 4 ddddd
>
> Re sort The Num In Trigger
>
> Thanks
>|||Let's make this problem more concrete. You want to put automobiles
into numbered parking spaces and move them around.
CREATE TABLE Motorpool
(parking_space INTEGER NOT NULL PRIMARY KEY
CHECK (parking_space > 0),
vin CHAR(170) NOT NULL);
Re-arrange the display order based on the parking_space column:
CREATE PROCEDURE SwapVehicles (@.old_parking_space INTEGER,
@.new_parking_space INTEGER)
AS
UPDATE Motorpool
SET parking_space
= CASE parking_space
WHEN @.old_parking_space
THEN @.new_parking_space
ELSE parking_space + SIGN(@.old_parking_space - @.new_pos)
END
WHERE parking_space BETWEEN @.old_parking_space AND @.new_parking_space
OR parking_space BETWEEN @.new_parking_space AND @.old_parking_space;
When you want to drop a few rows, remember to close the gaps with this:
CREATE PROCEDURE CloseMotorpoolGaps()
AS
UPDATE Motorpool
SET parking_space
= (SELECT COUNT (M1.parking_space)
FROM Motorpool AS M1
WHERE M1.parking_space <= Motorpool.parking_space);|||Thank you CELKO
"--CELKO--" <jcelko212@.earthlink.net> wrote in message
news:1150310619.762497.25420@.p79g2000cwp.googlegroups.com...
> Let's make this problem more concrete. You want to put automobiles
> into numbered parking spaces and move them around.
> CREATE TABLE Motorpool
> (parking_space INTEGER NOT NULL PRIMARY KEY
> CHECK (parking_space > 0),
> vin CHAR(170) NOT NULL);
> Re-arrange the display order based on the parking_space column:
> CREATE PROCEDURE SwapVehicles (@.old_parking_space INTEGER,
> @.new_parking_space INTEGER)
> AS
> UPDATE Motorpool
> SET parking_space
> = CASE parking_space
> WHEN @.old_parking_space
> THEN @.new_parking_space
> ELSE parking_space + SIGN(@.old_parking_space - @.new_pos)
> END
> WHERE parking_space BETWEEN @.old_parking_space AND @.new_parking_space
> OR parking_space BETWEEN @.new_parking_space AND @.old_parking_space;
> When you want to drop a few rows, remember to close the gaps with this:
> CREATE PROCEDURE CloseMotorpoolGaps()
> AS
> UPDATE Motorpool
> SET parking_space
> = (SELECT COUNT (M1.parking_space)
> FROM Motorpool AS M1
> WHERE M1.parking_space <= Motorpool.parking_space);
>
I Have Table Num As Int , Name As NvarChar(20) I Need Trigger to Resort The
Field Num When I Change The num
Num Name
1 aaaaa
2 bbbbb
3 cccccc
4 ddddd
I Want when I Change the Num 1 To 2 Came Like
Num Name
1 bbbbb
2 aaaaaa
3 cccccc
4 ddddd
Re sort The Num In Trigger
Thankswhat are you talking about? Sorting is done at query time, by specifying a
sort order.
"Taha" <taha105@.hotmail.com> wrote in message
news:%23%23nlsb9jGHA.4512@.TK2MSFTNGP04.phx.gbl...
> Hi all
>
> I Have Table Num As Int , Name As NvarChar(20) I Need Trigger to Resort
> The Field Num When I Change The num
>
> Num Name
> 1 aaaaa
> 2 bbbbb
> 3 cccccc
> 4 ddddd
>
> I Want when I Change the Num 1 To 2 Came Like
>
> Num Name
> 1 bbbbb
> 2 aaaaaa
> 3 cccccc
> 4 ddddd
>
> Re sort The Num In Trigger
>
> Thanks
>|||Let's make this problem more concrete. You want to put automobiles
into numbered parking spaces and move them around.
CREATE TABLE Motorpool
(parking_space INTEGER NOT NULL PRIMARY KEY
CHECK (parking_space > 0),
vin CHAR(170) NOT NULL);
Re-arrange the display order based on the parking_space column:
CREATE PROCEDURE SwapVehicles (@.old_parking_space INTEGER,
@.new_parking_space INTEGER)
AS
UPDATE Motorpool
SET parking_space
= CASE parking_space
WHEN @.old_parking_space
THEN @.new_parking_space
ELSE parking_space + SIGN(@.old_parking_space - @.new_pos)
END
WHERE parking_space BETWEEN @.old_parking_space AND @.new_parking_space
OR parking_space BETWEEN @.new_parking_space AND @.old_parking_space;
When you want to drop a few rows, remember to close the gaps with this:
CREATE PROCEDURE CloseMotorpoolGaps()
AS
UPDATE Motorpool
SET parking_space
= (SELECT COUNT (M1.parking_space)
FROM Motorpool AS M1
WHERE M1.parking_space <= Motorpool.parking_space);|||Thank you CELKO
"--CELKO--" <jcelko212@.earthlink.net> wrote in message
news:1150310619.762497.25420@.p79g2000cwp.googlegroups.com...
> Let's make this problem more concrete. You want to put automobiles
> into numbered parking spaces and move them around.
> CREATE TABLE Motorpool
> (parking_space INTEGER NOT NULL PRIMARY KEY
> CHECK (parking_space > 0),
> vin CHAR(170) NOT NULL);
> Re-arrange the display order based on the parking_space column:
> CREATE PROCEDURE SwapVehicles (@.old_parking_space INTEGER,
> @.new_parking_space INTEGER)
> AS
> UPDATE Motorpool
> SET parking_space
> = CASE parking_space
> WHEN @.old_parking_space
> THEN @.new_parking_space
> ELSE parking_space + SIGN(@.old_parking_space - @.new_pos)
> END
> WHERE parking_space BETWEEN @.old_parking_space AND @.new_parking_space
> OR parking_space BETWEEN @.new_parking_space AND @.old_parking_space;
> When you want to drop a few rows, remember to close the gaps with this:
> CREATE PROCEDURE CloseMotorpoolGaps()
> AS
> UPDATE Motorpool
> SET parking_space
> = (SELECT COUNT (M1.parking_space)
> FROM Motorpool AS M1
> WHERE M1.parking_space <= Motorpool.parking_space);
>
Friday, March 9, 2012
RDL
Hi
I currently use SSRS2005 and I develop reports, for use in our company. My
question is, I was wondering if it is possible to embedd some sort of tag,
which holds version information, since some of the reports that we develop
go through several iterations and it would be useful if we could have some
sort of tag, instead of altering the filename everytime.
Kind regards
Ricky
(SS2005/SSRS2005)On Jun 22, 2:51 pm, "Ricky" <r...@.msn.com> wrote:
> Hi
> I currently use SSRS2005 and I develop reports, for use in our company. My
> question is, I was wondering if it is possible to embedd some sort of tag,
> which holds version information, since some of the reports that we develop
> go through several iterations and it would be useful if we could have some
> sort of tag, instead of altering the filename everytime.
> Kind regards
> Ricky
> (SS2005/SSRS2005)
This is a long shot; but, you could try using a hidden parameter field
and setting it to a static value of some sort. Otherwise, you would
most likely be able to automate the file renaming process in a custom
application based on a timestamp of some kind. Sorry that I could not
be of greater assistance.
Regards,
Enrique Martinez
Sr. Software Consultant|||Hey Enrique
Thanks for the posting, no need to apologise, I thinking along the same
lines of using somesort of hidden object in the report itself...
Kind regards
Ricky
"EMartinez" <emartinez.pr1@.gmail.com> wrote in message
news:1182576891.242395.75490@.n60g2000hse.googlegroups.com...
> On Jun 22, 2:51 pm, "Ricky" <r...@.msn.com> wrote:
>> Hi
>> I currently use SSRS2005 and I develop reports, for use in our company.
>> My
>> question is, I was wondering if it is possible to embedd some sort of
>> tag,
>> which holds version information, since some of the reports that we
>> develop
>> go through several iterations and it would be useful if we could have
>> some
>> sort of tag, instead of altering the filename everytime.
>> Kind regards
>> Ricky
>> (SS2005/SSRS2005)
>
> This is a long shot; but, you could try using a hidden parameter field
> and setting it to a static value of some sort. Otherwise, you would
> most likely be able to automate the file renaming process in a custom
> application based on a timestamp of some kind. Sorry that I could not
> be of greater assistance.
> Regards,
> Enrique Martinez
> Sr. Software Consultant
>|||On Jun 23, 9:15 am, "Ricky" <r...@.msn.com> wrote:
> Hey Enrique
> Thanks for the posting, no need to apologise, I thinking along the same
> lines of using somesort of hidden object in the report itself...
> Kind regards
> Ricky
> "EMartinez" <emartinez...@.gmail.com> wrote in message
> news:1182576891.242395.75490@.n60g2000hse.googlegroups.com...
> > On Jun 22, 2:51 pm, "Ricky" <r...@.msn.com> wrote:
> >> Hi
> >> I currently use SSRS2005 and I develop reports, for use in our company.
> >> My
> >> question is, I was wondering if it is possible to embedd some sort of
> >> tag,
> >> which holds version information, since some of the reports that we
> >> develop
> >> go through several iterations and it would be useful if we could have
> >> some
> >> sort of tag, instead of altering the filename everytime.
> >> Kind regards
> >> Ricky
> >> (SS2005/SSRS2005)
> > This is a long shot; but, you could try using a hidden parameter field
> > and setting it to a static value of some sort. Otherwise, you would
> > most likely be able to automate the file renaming process in a custom
> > application based on a timestamp of some kind. Sorry that I could not
> > be of greater assistance.
> > Regards,
> > Enrique Martinez
> > Sr. Software Consultant
Let me know if I can be of further assistance.
Best Regards,
Enrique Martinez
Sr. Software Consultant|||Thanks Enrique, you've pointed me in the right direction, which helps .
Kind regards
Ricky
s
"EMartinez" <emartinez.pr1@.gmail.com> wrote in message
news:1182644372.225176.28640@.g4g2000hsf.googlegroups.com...
> On Jun 23, 9:15 am, "Ricky" <r...@.msn.com> wrote:
>> Hey Enrique
>> Thanks for the posting, no need to apologise, I thinking along the same
>> lines of using somesort of hidden object in the report itself...
>> Kind regards
>> Ricky
>> "EMartinez" <emartinez...@.gmail.com> wrote in message
>> news:1182576891.242395.75490@.n60g2000hse.googlegroups.com...
>> > On Jun 22, 2:51 pm, "Ricky" <r...@.msn.com> wrote:
>> >> Hi
>> >> I currently use SSRS2005 and I develop reports, for use in our
>> >> company.
>> >> My
>> >> question is, I was wondering if it is possible to embedd some sort of
>> >> tag,
>> >> which holds version information, since some of the reports that we
>> >> develop
>> >> go through several iterations and it would be useful if we could have
>> >> some
>> >> sort of tag, instead of altering the filename everytime.
>> >> Kind regards
>> >> Ricky
>> >> (SS2005/SSRS2005)
>> > This is a long shot; but, you could try using a hidden parameter field
>> > and setting it to a static value of some sort. Otherwise, you would
>> > most likely be able to automate the file renaming process in a custom
>> > application based on a timestamp of some kind. Sorry that I could not
>> > be of greater assistance.
>> > Regards,
>> > Enrique Martinez
>> > Sr. Software Consultant
>
> Let me know if I can be of further assistance.
> Best Regards,
> Enrique Martinez
> Sr. Software Consultant
>
I currently use SSRS2005 and I develop reports, for use in our company. My
question is, I was wondering if it is possible to embedd some sort of tag,
which holds version information, since some of the reports that we develop
go through several iterations and it would be useful if we could have some
sort of tag, instead of altering the filename everytime.
Kind regards
Ricky
(SS2005/SSRS2005)On Jun 22, 2:51 pm, "Ricky" <r...@.msn.com> wrote:
> Hi
> I currently use SSRS2005 and I develop reports, for use in our company. My
> question is, I was wondering if it is possible to embedd some sort of tag,
> which holds version information, since some of the reports that we develop
> go through several iterations and it would be useful if we could have some
> sort of tag, instead of altering the filename everytime.
> Kind regards
> Ricky
> (SS2005/SSRS2005)
This is a long shot; but, you could try using a hidden parameter field
and setting it to a static value of some sort. Otherwise, you would
most likely be able to automate the file renaming process in a custom
application based on a timestamp of some kind. Sorry that I could not
be of greater assistance.
Regards,
Enrique Martinez
Sr. Software Consultant|||Hey Enrique
Thanks for the posting, no need to apologise, I thinking along the same
lines of using somesort of hidden object in the report itself...
Kind regards
Ricky
"EMartinez" <emartinez.pr1@.gmail.com> wrote in message
news:1182576891.242395.75490@.n60g2000hse.googlegroups.com...
> On Jun 22, 2:51 pm, "Ricky" <r...@.msn.com> wrote:
>> Hi
>> I currently use SSRS2005 and I develop reports, for use in our company.
>> My
>> question is, I was wondering if it is possible to embedd some sort of
>> tag,
>> which holds version information, since some of the reports that we
>> develop
>> go through several iterations and it would be useful if we could have
>> some
>> sort of tag, instead of altering the filename everytime.
>> Kind regards
>> Ricky
>> (SS2005/SSRS2005)
>
> This is a long shot; but, you could try using a hidden parameter field
> and setting it to a static value of some sort. Otherwise, you would
> most likely be able to automate the file renaming process in a custom
> application based on a timestamp of some kind. Sorry that I could not
> be of greater assistance.
> Regards,
> Enrique Martinez
> Sr. Software Consultant
>|||On Jun 23, 9:15 am, "Ricky" <r...@.msn.com> wrote:
> Hey Enrique
> Thanks for the posting, no need to apologise, I thinking along the same
> lines of using somesort of hidden object in the report itself...
> Kind regards
> Ricky
> "EMartinez" <emartinez...@.gmail.com> wrote in message
> news:1182576891.242395.75490@.n60g2000hse.googlegroups.com...
> > On Jun 22, 2:51 pm, "Ricky" <r...@.msn.com> wrote:
> >> Hi
> >> I currently use SSRS2005 and I develop reports, for use in our company.
> >> My
> >> question is, I was wondering if it is possible to embedd some sort of
> >> tag,
> >> which holds version information, since some of the reports that we
> >> develop
> >> go through several iterations and it would be useful if we could have
> >> some
> >> sort of tag, instead of altering the filename everytime.
> >> Kind regards
> >> Ricky
> >> (SS2005/SSRS2005)
> > This is a long shot; but, you could try using a hidden parameter field
> > and setting it to a static value of some sort. Otherwise, you would
> > most likely be able to automate the file renaming process in a custom
> > application based on a timestamp of some kind. Sorry that I could not
> > be of greater assistance.
> > Regards,
> > Enrique Martinez
> > Sr. Software Consultant
Let me know if I can be of further assistance.
Best Regards,
Enrique Martinez
Sr. Software Consultant|||Thanks Enrique, you've pointed me in the right direction, which helps .
Kind regards
Ricky
s
"EMartinez" <emartinez.pr1@.gmail.com> wrote in message
news:1182644372.225176.28640@.g4g2000hsf.googlegroups.com...
> On Jun 23, 9:15 am, "Ricky" <r...@.msn.com> wrote:
>> Hey Enrique
>> Thanks for the posting, no need to apologise, I thinking along the same
>> lines of using somesort of hidden object in the report itself...
>> Kind regards
>> Ricky
>> "EMartinez" <emartinez...@.gmail.com> wrote in message
>> news:1182576891.242395.75490@.n60g2000hse.googlegroups.com...
>> > On Jun 22, 2:51 pm, "Ricky" <r...@.msn.com> wrote:
>> >> Hi
>> >> I currently use SSRS2005 and I develop reports, for use in our
>> >> company.
>> >> My
>> >> question is, I was wondering if it is possible to embedd some sort of
>> >> tag,
>> >> which holds version information, since some of the reports that we
>> >> develop
>> >> go through several iterations and it would be useful if we could have
>> >> some
>> >> sort of tag, instead of altering the filename everytime.
>> >> Kind regards
>> >> Ricky
>> >> (SS2005/SSRS2005)
>> > This is a long shot; but, you could try using a hidden parameter field
>> > and setting it to a static value of some sort. Otherwise, you would
>> > most likely be able to automate the file renaming process in a custom
>> > application based on a timestamp of some kind. Sorry that I could not
>> > be of greater assistance.
>> > Regards,
>> > Enrique Martinez
>> > Sr. Software Consultant
>
> Let me know if I can be of further assistance.
> Best Regards,
> Enrique Martinez
> Sr. Software Consultant
>
Subscribe to:
Posts (Atom)