473,412 Members | 2,051 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,412 software developers and data experts.

rename of logical file name

Hi,
If I will rename the logical file name in production will it create any issues.(sql server 2000).

I am getting the problem while restore the production database to other server. So,that I am planning to rename the logical name. The restoration is automated job for all the databases. That restoration script is working fine execpt for 3 databases because the logical names are different for these databases
Any advice.
Regards
Bharat
Jul 23 '07 #1
2 4493
hariharanmca
1,977 1GB
Hi,
If I will rename the logical file name in production will it create any issues.(sql server 2000).

I am getting the problem while restore the production database to other server. So,that I am planning to rename the logical name. The restoration is automated job for all the databases. That restoration script is working fine execpt for 3 databases because the logical names are different for these databases
Any advice.
Regards
Bharat

can you explain your problem little bit more.
Jul 23 '07 #2
Hi,
Thanks 4 ur response.

I have taken the backups from production and copy to other server ,then I will execute this restoration automated script for all the databases.
My script is given below.
----
-----
set @logical_data_name =@db_name + '_' + 'data'
set @logial_log_name =@db_name + '_' + 'log'
---
---
RESTORE DATABASE @db_name
FROM DISK = @backup_filename
with replace,
MOVE @logical_data_name to @phsical_data_name
MOVE @logial_log_name TO @physical_ldf_filename

So,my script supports if the logicalname and physical names are same.
ex:: logical names are abc_data,abc_log
phsyical names are abc_data.mdf,abc_log.ldf

But for 3 databases say dbname is test.
logical names are test1_data,test1_log
phsyical names TEST_DATA.MDF,TEST_LOG.LDF

so, I am planning to rename the logical names to(test_data,test_log) in production. My question is will it creates any issues.
Thanks
Bharat
Jul 23 '07 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: Venkat | last post by:
Hi All, Currently i guess rename and remove are not supported using fstream. How do i rename or remove a file? regards, Venkat
16
by: dudufigueiredo | last post by:
I have one folder containing mp3 files, the folder is: C:\My Shared Folder\Rubber Soul And the files are: 01 drive my car.mp3 02 norwegian wood.mp3 03 you won't see me.mp3 04 nowhere man.mp3...
5
by: jez123456 | last post by:
Hi, I’ve written a c# program to compact certain msaccess databases. The way this works is to compact say C:\test1.mdb to C:\temp.mdb, then delete C:\test1.mdb and rename C:\temp.mdb as...
1
by: Jay at SCA | last post by:
I've been having the following issue with a windows service I've created in vb.net (.net fw 1.1): Basically, my service monitors a folder for the creation of any new files of a particular type...
5
by: VB Programmer | last post by:
My web hoster says that I have to rename my ASPNETDB.MDF SqlExpress db for my 2.0 site to work. Is this accurate? If so, how can I rename it without breaking anything on my site? FYI: This is...
12
by: mantrid | last post by:
Im trying to move a file but am having luck my code is below. The temp and target paths are valid as they echo correctly. but I cant get the copy() function to work, or the rename() function ...
1
by: jonathan184 | last post by:
trying to rename filenames and extensions then add a header in line1 of each file if the header existed in line 1 to go to the next file. but i am getting error explciti errors Here is my...
14
by: blueboy | last post by:
Hi, I am planning to automate a nighty restore of a DB on another server can someone point me in the right direction with the SQL script to modify the logical file names to the correct path and...
1
by: achotto | last post by:
hi, i try to upload a multiple image files. after that i will rename the files name. the problem is when i upload a 2 or more same files name exp-goal.jpg, it will return "files already exist". ok...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.