Showing posts with label supports. Show all posts
Showing posts with label supports. Show all posts

Friday, February 24, 2012

deploy sql server express to ISP

To deploy sql server express to an ISP that supports Sql Server, I backed up the .mdf and .ldf files.

I can connect to the ISP database with Sql Server Mangement Studio Express. That connection requires a password.

When I try to execute 'restore', I get an error for no permission.

Any ideas why I have no permission after a password has already been entered?

I sure appreciate any help.

You will need to contact your ISP to discover what permissions you have on thier server. If you're getting a no permission error, it means that you don't have permission to perform a RESTORE on the server. SQL security is not all or nothing, you can be assigned a whole range of permissions that each imply certain rights.

Is RESTORE the way your ISP recomends putting databases on thier system? I'd actually be kind of surprised if it was, most ISP do not give this level of permissions to thier users.

Regards,

Mike Wachal
SQL Express team

-
Check out my tips for getting your answer faster and how to ask a good question: http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=307712&SiteID=1

|||

Finally --

I found a solution.

The problem was the ISP. They were not helpful at all. I quit and went to discountasp.net (yea) -- they have a tool to convert sql server express over to sql server 2005 and they have answered all of my questions within just an hour or so.

Thanks for your help Mike.

|||

Glad that it worked out for you CK. I'm also glad the discountasp.net has a tool to upload your database easily.

I'll make one minor nit just so it's mentioned in the thread. I think it's important for folks to understand that SQL Express is SQL Server 2005. There is not difference between the database files, all the same data types are supported, etc. SQL Express has fewer functions, but that's all. This is pretty normal, think about all the applications that offer a "lite" or "personal" edition with reduced functionaltiy, and then when you pay, you get additional functionality, same thing here.

You don't need to convert the SQL Express database, it's already exactly the same. The confusion stems from two issues:

Some Hosters allow you to move your database to the site using the Import/Export wizard, which isn't currently in SQL Express. This makes it hard to get your database on the server and we're working with Hosters to get the whole upload story working for SQL Express users.|||

Hi Mike, very pleased to find your post. I have a website built in VWD express, where deployment to an isp fails with this:

... (provider: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified) ...

After a rather frustrating 2 days I've arrived at the same conclusion as you suggest, that isp's do not really support sql express, and they annoyingly avoid saying so in their blurb. Yet the VWD Express deployment went just fine, so I just have to fix the SQL stuff.

From your post are you saying that SQL Express is Enterprise ManagerLite, but under the hood, its still system tables like sysobjects and so on, just inaccessible. Or is SQL Express reduced in actual scope and reach, regardless of accessibilty. I cannot find a SQL express query window on its own, it seems that the only interface is from within VWD which is sufficient, although much reduced from Enterprise Manager. This must be Lite.

Reason I ask is so that I can understand better what happens when i transfer my database (at least its contents) from my local machine to my isp. Following your logic, do my SQL Express .mdf (with or without .ldf) files attach/detach seamlessly between SQL Express and SQL 2005 and back. In which case I just have to find an isp who will allow attach/detach. Then I alter the connection string in web.config to use the server/database on the isp's machine as per MSDN. Then it should work?

Hope this brightens your day, then maybe you can shed some light ...

Charlie

|||

Charlie,

I'm sorry about your 2 days of frustration. I know exactly what you are going through. The ISP that caused me 3 weeks of frustration (1) told me on the phone before I signed up that VWD/SQL Server Express would work fine (2) sent me solutions from multiple techs that required Enterprise Manager - which is NOT available from SQL Express and (3) would not admit they didn't know.

Of course I bought into the idea that VWD is for hobbyists and lite-weights, forcing me to pass my frustrations on to this forum(!), but now that is behind me and I am a happy camper.

Here's an article that helped me: http://aspnet.4guysfromrolla.com/articles/040506-1.aspx

Deploy SMO project

Hi,
I'm writting a tools with SMO that supports SQL Server 2005 and 2000 and I'm wondering wich components do I have to include in my setup to support both versions ?

With SQLServer 2000 my application throws a following message :

"Could not load type ‘Microsoft.sqlServer.Management.Smo.TriggerBaseCollection’ from assembly ‘Microsoft.sqlServer.Management.Smo’, version = 9.0.242.0"
Thank you.You should obtain the "Microsoft SQL Server 2005 Management Objects Collection", which contains SMO. See http://www.microsoft.com/downloads/details.aspx?FamilyID=d09c1d60-a13c-4479-9b91-9e8b9d835cdc&DisplayLang=en

Peter

Sunday, February 19, 2012

Deploy .MDF to a web host

Hi all,

I'm new to SQLServer (Express edition) so I was wondering: if the web
host supports SQLServer 2005 do I just need to move the .MDF file to my
directory on the web host to be able to use it?

Thanks,
LorenzoIf you have rights attaching a user database to a SQL Server and the
instance has access to your upload directory you can do this.

HTH, Jens Suessmeyer.

--
http://www.sqlserver2005.de
--|||Jens wrote:
> If you have rights attaching a user database to a SQL Server and the
> instance has access to your upload directory you can do this.

Thanks for the answer, Jens

Lorenzo|||lbolognini@.gmail.com (lbolognini@.gmail.com) writes:
> I'm new to SQLServer (Express edition) so I was wondering: if the web
> host supports SQLServer 2005 do I just need to move the .MDF file to my
> directory on the web host to be able to use it?

You should probably talk to your web host about this. Jens suggested that
you may rights to attach databases. I say that the likelyhood for this is
nil, as this requires hefty rights on the server.

A little more likely is that they create an empty database for you,
and then you may be permitted to overwrite that database with a backup
of your database.

--
Erland Sommarskog, SQL Server MVP, esquel@.sommarskog.se

Books Online for SQL Server 2005 at
http://www.microsoft.com/technet/pr...oads/books.mspx
Books Online for SQL Server 2000 at
http://www.microsoft.com/sql/prodin...ions/books.mspx

Friday, February 17, 2012

Dependant IDENTITY columns

Anyone know if MS-SQL Server supports IDENTITY columns that are incremented for each new value of the column it depends on.

For exameple:
Let's say I have a client table with a ClientID column as it's PRIMARY KEY.
This column can be an auto-incrementing IDENTITY column.

Then I have an orders table. The PRIMARY KEY for the orders table is composed of (ClientID, OrderID). I would like the OrderID to be an IDENTITY field that increments by an arbitrary value (1 in this case) for every new value of ClientID...therefore creating a unique PRIMARY KEY.

The contents of the table would look like this

ClientID OrderID
--- ---
1 0
1 1
2 0
1 2
2 1
2 2
1 3

and so on...

MySQL (and maybe other RDMS's...I haven't checked) seems to do this automatically when you set a column as AUTOINCREMENT and then define a composite PRIMARY KEY on two fields.
I know this can be done manually using triggers, but I was wondering if there was a better way...

Thanks in advanceYou are only allowed 1 IDENTITY Column per table...

How do you plan to INSERT the data in to the table?|||MySQL will do that? I'm skeptical...

Yes, you can do this using triggers, but it seems as if you are going to be using these values and their order as part of your application logic. That's generally not a good idea. An autoincrementing ID is a surrogate key, and should not have any inherent relationship to the data it represents.

What are you planning to use these values for?|||I know.

In an INSERT into the Orders table, I would supply the ClientID (and all the other fields I didn't mention in the orginal post) and the OrderID "for that client" would be incremented. Maybe you thought I meant that in the orders table the ClientID and OrderID are IDENTITY columns...|||BlindMan:
I wasn't planning on using it for anything (for now anyways), I was just curious. The Clients/Orders table was just a commonly used example.

As for it being possible with MySQL, I checked it again (since I first discovered this a while back), and yes it is possible. The syntax under MySQL would roughly be:

CREATE TABLE Clients (
ClientID INT AUTO_INCREMENT PRIMARY KEY);

CREATE TABLE Orders (
ClientID INT,
OrderID INT AUTO_INCREMENT,
CONSTRAINT PK_SomeName PRIMARY KEY (ClientID, OrderID));

Obviously there would be a foreign key set on Orders.ClientID...but I just want to show the example..

After populating Clients with a few values, you can insert a few into orders
like so:

INSERT INTO Orders (ClientID) VALUES (SomeValues);

and the OrderID field will increment like I mentionned in the original post,
except that the default AUTO_INCREMENT seed is "1", not "0".

Like I said, I was just curious if it was possible to use this with MS-SQL
without using a workaround.

Thanks for the information!!|||MySQL will do that? I'm skeptical...

oh ye of little faith, yes, it certainly can (as afx2029 so nicely illustrated)

mysql can do several things that make sense when you see them

other databases could learn from some of what they're doing

and before y'all jump all over me, i did not say mysql was better than other databases, just that they actually do some neat things

i'm still undecided about whether i like the ability to store 2004-05-00 and 2002-00-00 as perfectly valid datetime values (there's a good reason for it), but i am aghast at them allowing 2003-02-29 and 2001-02-31|||Rudy, what would be a good reason for allowing (2002-00-00) or (2004-05-00 ) as valid datetime?|||Yeah Rudy! If you love MySQL so much, why don't you just MARRY it? Huh? Well, why dontcha? If it's so much BETTER? :p|||GDMI, to allow you to use a single date column to record an event (birthday, battle, etc.) and be able to store partial information, e.g. if all you know about great-great-grand-uncle Fritz is that he was born in 1903 but you don't know the month or year, put 1903-00-00

you can't do that with a "normal" date column in other databases, which require an exact date, so you'd either have to carry separate year, month, day columns and allow nulls, or else fake it by putting 1903-01-01 (which, i hasten to point out, is wrong and misleading)

blindman, i've sworn off marriage, having gone through two of them

:cool:|||Rudy, Thanks for the explanation. I admit I haven't thought about that before ...|||Rudy, Thanks for the explanation. I admit I haven't thought about that before ...

I can't tell. Is he talking about your code or your marriages? I quit after one, so I guess that makes me a more efficient marriager than you. ;)|||I can't tell. Is he talking about your code or your marriages? I quit after one, so I guess that makes me a more efficient marriager than you. ;)Everybody should do it at least once. It helps promote the species, and it instills a real fear of the potential of hell.

This coming from a guy who's never found an eligible woman smart enough to be interesting and dumb enough to say "yes".

-PatP|||hell hath no fury like a woman with a divorce lawyer

but it is worth the pain

i have two fantastic boys from my first marriage, 32, and 30

and a fabulous daughter, 13, and son, 11, from my second

i would love to have even more kids, but i am broke, out of work, and too old and unattractive to have any hope of a third marriage

my only hope now is that one of my older boys has grandkids soon|||I can't tell. Is he talking about your code or your marriages?

Nope! I was talking about his code! ;)

But speaking about marriages .. I am preparing for my marriage .. hopefully it will be my first and last eventhough statistics are against that.

Blindman, Rudy you guys are great SQL consultants ;) in a "SQL World" that alone should qualify to get chicks! :p|||Careful, GDMI. Statistics shouw that just over half of the marriages in the US end in divorce. But just under half end in death!|||Nope! I was talking about his code! ;)

But speaking about marriages .. I am preparing for my marriage .. hopefully it will be my first and last eventhough statistics are against that.

Blindman, Rudy you guys are great SQL consultants ;) in a "SQL World" that alone should qualify to get chicks! :p

What IT offices have you been working in?|||a long time ago, i knew a woman who knew sql...

$expletive, was she ever hot!!!!!!!!!!

in my experience, IT has as many attractive women as any other vocation|||hell hath no fury like a woman with a divorce lawyer

but it is worth the pain

i have two fantastic boys from my first marriage, 32, and 30

and a fabulous daughter, 13, and son, 11, from my second

i would love to have even more kids, but i am broke, out of work, and too old and unattractive to have any hope of a third marriage

my only hope now is that one of my older boys has grandkids soonGood kids do help to ease the pain!

I can't comment on the "broke" part, and I don't see you as "unemployed" although I know that you'd debate that point. I'm not qualified to comment on unattractive (I only pay attention to females on that point), but somehow I still can't buy that one either.

Grandkids are great fun! They are even more fun than the first time around, and at least in my opinion give you your first real chance to "check your work"

-PatP|||I don't mean to be off-topic or anything....but is what I originally posted
possible with MS-SQL Server without resorting to triggers or another workaround?

:)|||Anyone know if MS-SQL Server supports IDENTITY columns that are incremented for each new value of the column it depends on.

For exameple:
Let's say I have a client table with a ClientID column as it's PRIMARY KEY.
This column can be an auto-incrementing IDENTITY column.

Then I have an orders table. The PRIMARY KEY for the orders table is composed of (ClientID, OrderID). I would like the OrderID to be an IDENTITY field that increments by an arbitrary value (1 in this case) for every new value of ClientID...therefore creating a unique PRIMARY KEY.

The contents of the table would look like this

ClientID OrderID
--- ---
1 0
1 1
2 0
1 2
2 1
2 2
1 3

and so on...

MySQL (and maybe other RDMS's...I haven't checked) seems to do this automatically when you set a column as AUTOINCREMENT and then define a composite PRIMARY KEY on two fields.
I know this can be done manually using triggers, but I was wondering if there was a better way...

Thanks in advance

No

I asked you how you plan to do the INSERT.

If you tell us, we might be able to suggest something...|||I don't mean to be off-topic or anything....but is what I originally posted
possible with MS-SQL Server without resorting to triggers or another workaround?

:)As Brett answered (twice), no. No truely relational database can support what you are looking for, since it is application specific and violates the single domain rule of first normal form as expressed in relational algebra.

The only way to add application specific code to SQL Server is via a trigger.

-PatP|||No truely relational database can support what you are looking for ...mysql can do it

or is that why you were so careful to qualify your statement? ;)

...since it is application specific and violates the single domain rule of first normal form as expressed in relational algebra.stop that! go to your room!

it's a feature

;)|||Just like

SELECT + 'This is a feature?'

Is a feature|||stop that! go to your room!

it's a feature

;)I just said that it wasn't relational, and pointed out how the feature could be simulated in a relational database. Was I naughty?

Just like

SELECT + 'This is a feature?'

Is a featureI see it that way!

-PatP