Showing posts with label copied. Show all posts
Showing posts with label copied. Show all posts

Wednesday, March 28, 2012

moving a project to another machine

Hey,
I have copied a C# express edition project from another machine and have opened the project up and changed the connection string but the project is not updating the database when I try to insert values from textboxes in forms. They seem do be getting into the dataset but not the sql datatabase.
I am getting alot of messages saying that it could not find the schema information for the dataset. Could these errors have anything to do with the project?
What else do I have to change in the project?

Thanks in advance.

Hi, Yorick85

What kind of database were you using?

In general, please check the database permission to your local machine. And make sure that connection has been correct.

Thanks

|||Hi,

I am using SQL server 2005 on both machines. How do I check the database permission on my local machine?
Thanks
|||

It depends on what is your connection string security mode, windows Authentication or sql server Authentication?

If it need user name or password in the Authentication, you should check the user and role in Sql Server Management Studio for particular database.

Thanks

sql

moving a project to another machine

Hey,
I have copied a C# express edition project from another machine and have opened the project up and changed the connection string but the project is not updating the database when I try to insert values from textboxes in forms. They seem do be getting into the dataset but not the sql datatabase.
I am getting alot of messages saying that it could not find the schema information for the dataset. Could these errors have anything to do with the project?
What else do I have to change in the project?

Thanks in advance.

Hi, Yorick85

What kind of database were you using?

In general, please check the database permission to your local machine. And make sure that connection has been correct.

Thanks

|||Hi,

I am using SQL server 2005 on both machines. How do I check the database permission on my local machine?
Thanks
|||

It depends on what is your connection string security mode, windows Authentication or sql server Authentication?

If it need user name or password in the Authentication, you should check the user and role in Sql Server Management Studio for particular database.

Thanks

Monday, March 26, 2012

Moving a Database

Hi

I want to transfer a database from one PC to another. (Both running SQL Server 2005 express)

I have copied the files (SQL Server Database Primary Data File and SQL Server Database Transaction Log File) from the C:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\Data folder of the source PC to the destination PC (Same folder).

I was under the impression that using Microsoft SQL Server 2005 - SQL Server Management Studio Express these files would be picked up and could be used, do I infact need to do something to attach the files/database so that they will appear in SQL Server management?

If you are moving the db;s you need to'detach' them first, then copy the files to the new location, then'attach' them back. check out BOL on how to attach/detach DB's.|||

Thanks

I have just tried doing this, I opened a sql command window on (local)SQLEXPRESS.master - SQLQuery1.sql and than this script:

EXEC

sp_attach_db @.dbname='pramsetc',

@.filename1

='C:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\Data\blog.mdf',

@.filename2

='C:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\Data\blog_log.ldf'

This seemed to run okay, but I cant now find my database anywhere in Object Explorer in Management Studio, however the database must of been created somwhere as when I try running the sql again I get:

Msg 1801, Level 16, State 3, Line 1

Database 'blog' already exists.

Any pointers as to where I am going wrong?FONT>

|||

Apologies correction:

Thanks

I have just tried doing this, I opened a sql command window on (local)SQLEXPRESS.master - SQLQuery1.sql and than this script:

EXEC

sp_attach_db @.dbname='blog',

@.filename1

='C:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\Data\blog.mdf',

@.filename2

='C:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\Data\blog_log.ldf'

This seemed to run okay, but I cant now find my database anywhere in Object Explorer in Management Studio, however the database must of been created somwhere as when I try running the sql again I get:

Msg 1801, Level 16, State 3, Line 1

Database 'blog' already exists.

Any pointers as to where I am going wrong?

|||Did you detach the DB before attaching it? If you did, refresh your databases list and you could probably see the new db in the list.|||

No I didnt know I needed to do that when I copied them across. I will do that now, just as a matter of interest why does that make a difference, what does the detach do that affects the file being attached locally?

Thanks

|||I am puzzled as how it let you copy the files without getting an "Access denied" or "File in use" error. (2) On the server where you are restoring, refresh the databases on the enterprise maanger. Do you see the 'Blob' db? If you already have one, you need to give a different name while restoring.|||I will try detaching it first, thanks

Saturday, February 25, 2012

Move databases to a larger drive

I have a SQL 6.5 server running on WinNTthat was recently upgraded. The
SQLServer service was stopped, the physical files were manually copied to
the new larger drives, and the SQLServer service was restarted. The problem
is that now when I go to expand the databases (the entire purpose of the
upgrade) SQL Exec doesn't appear to see the larger drive capacity. The
drive lettering was adjusted such that the new larger drives containing the
databases have the drive letters of the original drives, and SQL Exec sees
the databases and brings them online. Is there some other process I should
have used? Is there a way to get SQL Exec to recognize the empty space on
the new drive? Any and all help is greatly appreciated.
One must ask..
What the hell are you still doing on 6.5!
"Jason Rosenblum" <jrosenblum@.wcmh.org> wrote in message
news:O$i6htcfEHA.4092@.TK2MSFTNGP10.phx.gbl...
> I have a SQL 6.5 server running on WinNTthat was recently upgraded. The
> SQLServer service was stopped, the physical files were manually copied to
> the new larger drives, and the SQLServer service was restarted. The
problem
> is that now when I go to expand the databases (the entire purpose of the
> upgrade) SQL Exec doesn't appear to see the larger drive capacity. The
> drive lettering was adjusted such that the new larger drives containing
the
> databases have the drive letters of the original drives, and SQL Exec sees
> the databases and brings them online. Is there some other process I
should
> have used? Is there a way to get SQL Exec to recognize the empty space on
> the new drive? Any and all help is greatly appreciated.
>
|||Hi,
Have a look into the below link. ( Describes the various methods to load XML
to SQl 2000 tables)
http://www.perfectxml.com/articles/xml/importxmlsql.asp
Thanks
Hari
MCDBA
"Jason Rosenblum" <jrosenblum@.wcmh.org> wrote in message
news:O$i6htcfEHA.4092@.TK2MSFTNGP10.phx.gbl...
> I have a SQL 6.5 server running on WinNTthat was recently upgraded. The
> SQLServer service was stopped, the physical files were manually copied to
> the new larger drives, and the SQLServer service was restarted. The
problem
> is that now when I go to expand the databases (the entire purpose of the
> upgrade) SQL Exec doesn't appear to see the larger drive capacity. The
> drive lettering was adjusted such that the new larger drives containing
the
> databases have the drive letters of the original drives, and SQL Exec sees
> the databases and brings them online. Is there some other process I
should
> have used? Is there a way to get SQL Exec to recognize the empty space on
> the new drive? Any and all help is greatly appreciated.
>
|||Sorry I posted.. wrongly...
Thanks
Hari
"Hari Prasad" <hari_prasad_k@.hotmail.com> wrote in message
news:OfImQ8dfEHA.592@.TK2MSFTNGP11.phx.gbl...
> Hi,
> Have a look into the below link. ( Describes the various methods to load
XML[vbcol=seagreen]
> to SQl 2000 tables)
> http://www.perfectxml.com/articles/xml/importxmlsql.asp
> Thanks
> Hari
> MCDBA
>
> "Jason Rosenblum" <jrosenblum@.wcmh.org> wrote in message
> news:O$i6htcfEHA.4092@.TK2MSFTNGP10.phx.gbl...
to[vbcol=seagreen]
> problem
> the
sees[vbcol=seagreen]
> should
on
>

Move databases to a larger drive

I have a SQL 6.5 server running on WinNTthat was recently upgraded. The
SQLServer service was stopped, the physical files were manually copied to
the new larger drives, and the SQLServer service was restarted. The problem
is that now when I go to expand the databases (the entire purpose of the
upgrade) SQL Exec doesn't appear to see the larger drive capacity. The
drive lettering was adjusted such that the new larger drives containing the
databases have the drive letters of the original drives, and SQL Exec sees
the databases and brings them online. Is there some other process I should
have used? Is there a way to get SQL Exec to recognize the empty space on
the new drive? Any and all help is greatly appreciated.One must ask..
What the hell are you still doing on 6.5!
"Jason Rosenblum" <jrosenblum@.wcmh.org> wrote in message
news:O$i6htcfEHA.4092@.TK2MSFTNGP10.phx.gbl...
> I have a SQL 6.5 server running on WinNTthat was recently upgraded. The
> SQLServer service was stopped, the physical files were manually copied to
> the new larger drives, and the SQLServer service was restarted. The
problem
> is that now when I go to expand the databases (the entire purpose of the
> upgrade) SQL Exec doesn't appear to see the larger drive capacity. The
> drive lettering was adjusted such that the new larger drives containing
the
> databases have the drive letters of the original drives, and SQL Exec sees
> the databases and brings them online. Is there some other process I
should
> have used? Is there a way to get SQL Exec to recognize the empty space on
> the new drive? Any and all help is greatly appreciated.
>|||Hi,
Have a look into the below link. ( Describes the various methods to load XML
to SQl 2000 tables)
http://www.perfectxml.com/articles/xml/importxmlsql.asp
Thanks
Hari
MCDBA
"Jason Rosenblum" <jrosenblum@.wcmh.org> wrote in message
news:O$i6htcfEHA.4092@.TK2MSFTNGP10.phx.gbl...
> I have a SQL 6.5 server running on WinNTthat was recently upgraded. The
> SQLServer service was stopped, the physical files were manually copied to
> the new larger drives, and the SQLServer service was restarted. The
problem
> is that now when I go to expand the databases (the entire purpose of the
> upgrade) SQL Exec doesn't appear to see the larger drive capacity. The
> drive lettering was adjusted such that the new larger drives containing
the
> databases have the drive letters of the original drives, and SQL Exec sees
> the databases and brings them online. Is there some other process I
should
> have used? Is there a way to get SQL Exec to recognize the empty space on
> the new drive? Any and all help is greatly appreciated.
>|||Sorry I posted.. wrongly...
Thanks
Hari
"Hari Prasad" <hari_prasad_k@.hotmail.com> wrote in message
news:OfImQ8dfEHA.592@.TK2MSFTNGP11.phx.gbl...
> Hi,
> Have a look into the below link. ( Describes the various methods to load
XML
> to SQl 2000 tables)
> http://www.perfectxml.com/articles/xml/importxmlsql.asp
> Thanks
> Hari
> MCDBA
>
> "Jason Rosenblum" <jrosenblum@.wcmh.org> wrote in message
> news:O$i6htcfEHA.4092@.TK2MSFTNGP10.phx.gbl...
to[vbcol=seagreen]
> problem
> the
sees[vbcol=seagreen]
> should
on[vbcol=seagreen]
>

Move databases to a larger drive

I have a SQL 6.5 server running on WinNTthat was recently upgraded. The
SQLServer service was stopped, the physical files were manually copied to
the new larger drives, and the SQLServer service was restarted. The problem
is that now when I go to expand the databases (the entire purpose of the
upgrade) SQL Exec doesn't appear to see the larger drive capacity. The
drive lettering was adjusted such that the new larger drives containing the
databases have the drive letters of the original drives, and SQL Exec sees
the databases and brings them online. Is there some other process I should
have used? Is there a way to get SQL Exec to recognize the empty space on
the new drive? Any and all help is greatly appreciated.One must ask..
What the hell are you still doing on 6.5!
"Jason Rosenblum" <jrosenblum@.wcmh.org> wrote in message
news:O$i6htcfEHA.4092@.TK2MSFTNGP10.phx.gbl...
> I have a SQL 6.5 server running on WinNTthat was recently upgraded. The
> SQLServer service was stopped, the physical files were manually copied to
> the new larger drives, and the SQLServer service was restarted. The
problem
> is that now when I go to expand the databases (the entire purpose of the
> upgrade) SQL Exec doesn't appear to see the larger drive capacity. The
> drive lettering was adjusted such that the new larger drives containing
the
> databases have the drive letters of the original drives, and SQL Exec sees
> the databases and brings them online. Is there some other process I
should
> have used? Is there a way to get SQL Exec to recognize the empty space on
> the new drive? Any and all help is greatly appreciated.
>|||Hi,
Have a look into the below link. ( Describes the various methods to load XML
to SQl 2000 tables)
http://www.perfectxml.com/articles/xml/importxmlsql.asp
Thanks
Hari
MCDBA
"Jason Rosenblum" <jrosenblum@.wcmh.org> wrote in message
news:O$i6htcfEHA.4092@.TK2MSFTNGP10.phx.gbl...
> I have a SQL 6.5 server running on WinNTthat was recently upgraded. The
> SQLServer service was stopped, the physical files were manually copied to
> the new larger drives, and the SQLServer service was restarted. The
problem
> is that now when I go to expand the databases (the entire purpose of the
> upgrade) SQL Exec doesn't appear to see the larger drive capacity. The
> drive lettering was adjusted such that the new larger drives containing
the
> databases have the drive letters of the original drives, and SQL Exec sees
> the databases and brings them online. Is there some other process I
should
> have used? Is there a way to get SQL Exec to recognize the empty space on
> the new drive? Any and all help is greatly appreciated.
>|||Sorry I posted.. wrongly...
Thanks
Hari
"Hari Prasad" <hari_prasad_k@.hotmail.com> wrote in message
news:OfImQ8dfEHA.592@.TK2MSFTNGP11.phx.gbl...
> Hi,
> Have a look into the below link. ( Describes the various methods to load
XML
> to SQl 2000 tables)
> http://www.perfectxml.com/articles/xml/importxmlsql.asp
> Thanks
> Hari
> MCDBA
>
> "Jason Rosenblum" <jrosenblum@.wcmh.org> wrote in message
> news:O$i6htcfEHA.4092@.TK2MSFTNGP10.phx.gbl...
> > I have a SQL 6.5 server running on WinNTthat was recently upgraded. The
> > SQLServer service was stopped, the physical files were manually copied
to
> > the new larger drives, and the SQLServer service was restarted. The
> problem
> > is that now when I go to expand the databases (the entire purpose of the
> > upgrade) SQL Exec doesn't appear to see the larger drive capacity. The
> > drive lettering was adjusted such that the new larger drives containing
> the
> > databases have the drive letters of the original drives, and SQL Exec
sees
> > the databases and brings them online. Is there some other process I
> should
> > have used? Is there a way to get SQL Exec to recognize the empty space
on
> > the new drive? Any and all help is greatly appreciated.
> >
> >
>