My Program Uses A Database. Does The End-user Have To Have SQL Server 2005?

Apr 1, 2007

My program uses a database. Does the end-user have to have SQL server 2005?

It uses it to keep track of members so the database is in the installation folder and does not need to be accessed remotely



http://i130.photobucket.com/albums/p247/tarkster2/screen.gif

the above shows this error on another persons computer. they do not have sql server.

View 3 Replies


ADVERTISEMENT

How To Deny Access To Sql Server 2005 Database Except One Special Program

Nov 2, 2007


We want to deny access to sql server 2005 database by the sql management studio or any other sql editor while our developed application can access the database even malicious user gets the login name and password by disassembling our code

View 1 Replies View Related

How To Run A Vb.net Program From SQL Server 2005?

Mar 15, 2008

Hi. First 3 paragraphs are about problem in general - this is for those who consider them well experienced and may have better ideas about how to solve this whole thing. In forth paragraph is the tehnical question.



Hi. First 3 paragraphs are about problem in general - this is for those who consider them well experienced and may have better ideas about how to solve this whole thing. In forth paragraph is the tehnical question.

Situation:
So me was trying to find out why files are saved in database incorrectly. First idea was to create a MD5 checksum of a file in my application and then create one with SQL script that saves data in database (data being the file, by the way).

On software side it worked fine 'cuz i'm developing in Visual Basic .NET 2005 which has a function that return a 32 byte array of hash from a data that you pass to it (like file) - GREAT!

SQL Server 2005 side - not so great. The only function that I have found so far that creates hash is HashBytes that is supposed to do it's job only there's a limintation to data size which means i cant make hash of say 4mb big file.

Problem:
So I figure maybe i could create a vb.net program that return a hash from a data passed to it and call it with SQL script (because hashbytes function doesnt work for me in case you didnt read the first 3 paragraphs)... but I don't know how:(
Any ideas?

View 4 Replies View Related

How To Run A Vb.net Program From SQL Server 2005?

Mar 15, 2008

Hi. First 3 paragraphs are about problem in general - this is for those who consider them well experienced and may have better ideas about how to solve this whole thing. In forth paragraph is the tehnical question.

Situation:
So me was trying to find out why files are saved in database incorrectly. First idea was to create a MD5 checksum of a file in my application and then create one with SQL script that saves data in database (data being the file, by the way).

On software side it worked fine 'cuz i'm developing in Visual Basic .NET 2005 which has a function that return a 32 byte array of hash from a data that you pass to it (like file) - GREAT!

SQL Server 2005 side - not so great. The only function that I have found so far that creates hash is HashBytes that is supposed to do it's job only there's a limintation to data size which means i cant make hash of say 4mb big file.

Problem:
So I figure maybe i could create a vb.net program that return a hash from a data passed to it and call it with SQL script (because hashbytes function doesnt work for me in case you didnt read the first 3 paragraphs)... but I don't know how
Any ideas?

View 14 Replies View Related

How To Write Batch Program In SQL Server 2005?

Sep 10, 2007



Hello All,
I want to write Batch Program which will insert Data into Table every day based on some conditions.
can anyone please let me know how to write Batch Process in SQL server 2005??
Thanks.

View 5 Replies View Related

SQL Server 2005: Question About Creating A User For A Database

Dec 12, 2005

I'm not a DBA, so I don't know where to look for information on this.

In SQL Server 2005, I can simply no longer create a user for the database I created. It asks that the user be associated with a login. That login is found in the Security folder of the database instance.

The question is: what is this instance security folder for? I don't recall having to do this in SQL Server 2000.

Any elaboration or links to such information would be appreciated.

View 3 Replies View Related

Do I Need CAL For A Customized Program Connect To SQL Server 2005 Express Edition?

Dec 27, 2005

Hi all,

I am developing a program to connect to SQL 2005 Express. I don't know if I need any CAL license in order to make the connection. If it is not necessary for the Express Edition case, how about if my client upgrate to SQL 2005 in the future? Do I need CAL license for SQL 2005?

Thanks for any advice given.

View 1 Replies View Related

How To Delete User From A SQL Server 2000 Database In SQL Server 2005?

Feb 1, 2007

Hi,

I have a database created in server 2000, and now I have moved it to server 2005.

All works do fine, but there is a user which cannot be removed.

In the user properties window, the assigned schema is empty. The user is a db_owner of the database. When I was trying to update the user, it asked me for the login. The login is empty, but the field is disabled.

So my question is, how to remove this user?

Thank you.

Jensan

View 1 Replies View Related

Updating SQL Server 2005 Mobile Edition From Command-line Program

May 16, 2007

Is here any way to update Mobile database from command-line program that ie;

reads sql commands from text file, run query analyzer, insert readed data to SQL tab and deploy these commands?

Or any other way to do this?

View 3 Replies View Related

How Can I Insert Date In SQL Server 2000 Database (table )from ASP.NET 1.1. Program??

Feb 1, 2006

hi ALL !!!
How can I insert Date in SQL Server 2000 database(table ) from ASP.NET 1.1. Program??
pls send me code if u can
pls help me ..

View 2 Replies View Related

Using User Defined Data Type (UDT) In A Sql Server 2005 Database + Window Application.

Feb 18, 2006

Hi,

I am using VS2005 C# + sql server 2005 Express edition.

I need to using a database that uses my own defined data types to define its tables columns.

I already have designed a Database projact and create the new UDT as follows:



Create a new Database project in the Visual C# language nodes.


Add a reference to the SQL Server 2005 database that will contain the UDT.


Add a User-Defined Type class.


Write code to implement the UDT.


Select Deploy from the Build menu.

Now I need to ask some quistions:

1- When I try to add a new query to a table that contains my new data type in its columns,if I try to exexute the query the next message appears:

'Execution of user code in the .Net framework is disabled. Enable "clr enabled" configuration option'.

How can I doing that??

2- I need to use that database - which has the new data type - in a traditional ' Visual C# Windows Application' instead of 'Database', but:

when I try to add a new Data Source that contains the tables that have the new data types in its definitions, the next message appears:

'<AyaDatabase.dbo.MyNewUDTTable>

User-defined types(UDTs)are not supported in the Dataset Designer.'

So, how can I resolve that problem??

please help me.

Thanks in advance for any help.

Aya.



View 4 Replies View Related

Do Sqlexception Breaks The Functionality Of The Program? (program Flow)

May 23, 2007

why we use sql exceptions ...

what the program will do if we caught that exception .. i need some suggestions ... i got this exception(String or binary data would be truncated.
The statement has been terminated.).. will it affect the functionality of the program...

hiow can i avoid this exception..

View 1 Replies View Related

MSSQL 2005 User Database Now Shows Up In System Database Folder

Dec 10, 2007

While attempting to set up sql replication in MSSQL 2005 one of my user databases is now in the systems database folder. I need to move it back to the user databases folder. Any help would be greatly appreciated.

View 16 Replies View Related

SQL Server 2005: User Security Management: User Ch

Jun 25, 2007

How do you handle user level security with SQL Server 2005?

Say I have an HR database.

In Active Directory I have two groups: Managers, Employees.

Now in this HR Database I want to setup permissions in such a way that Managers can see all employees under them (but not other managers) and the employees can only see themselves.

(I'd have various levels of management defined in a table somewhere, so that each employee has a manager ID that links to another employee so that the CEO would be manager of everyone by working down the chain).

What I'm trying to understand is the best way to handle the permissions.

I'm not entirely clear on how to deal with that.

Would I use user chaining to do that, I wouldn't need impersonation (that's just for instances where you want dynamic SQL and it won't execute with user chaining, correct?)

Anyway, just looking for some general direction on this (obviously I need to get a good book it would seem).


Would I create a stored procedure that runs with EXECUTE AS permissions so that I'd have a non-interactive login it uses that has table access then all the other users have permission to execute the sproc?

So that sproc runs, pulls back a SELECT * FROM tbl_HRINFO and using a WHERE constraint limits who is returned WHERE SupervisorID = CurrentLoggedInEmployeeID ?

Also: How can I determine who is logged in and running the procedure, would the sproc use the SELECT USER_NAME command to see who was running it?

As you can see, I'm working from square one on all of this.
Not sure if my posting entirely made sense, but hopefully someone can get me pointed in the right direction, thanks!

View 3 Replies View Related

What's The Relationship Of Login,user And User In Sql Server 2005

Sep 19, 2007

what's the relationship of login,user and user in sql server 2005?
thanks

View 6 Replies View Related

Use Sql 2005 To Program Against Sql 2000

May 15, 2007

I have sql server 2005 (full version) installed on my local machine, while the databases (on the server) I want to program against are in sql 2000. Could I program against sql 2000 databases using sql 2005? If yes, what do I need to know before I start doing that? Any suggestions are welcome.

View 1 Replies View Related

Creating A Program That Uses A Database.

Mar 19, 2008

I am currently writing a program that will use a SQL database. I am use to writing programs that are used to connect over some type of a network, but for this project I need to be able to load the Database and it's tables to the system locally. If anyone has a suggestion it will be greatly appreciated, or any sites for documentation on it. Thank you.

View 6 Replies View Related

How To Update My Program With A Database

Dec 22, 2006

I need help to decide how to proceed.

I have written a program using vb 2005 express that will create menu items after the user presses a particular button. So if the user picks a mountain dew then inside the reciept window(list box) the user will see 1 MT DEW $1.00 also as the user selects more items the price is calculated and displayed also.

This part of the program works fine. After using the program for a while I realized that I will need to update prices and be able to add and subtract items from the menu that customers order from. The way I accompolish this now is to go back into my code and rewrite alot of code. From reading the forums I think that a database would be a good solution because what I have gathered so far is that by seperating the data into tables i.e price_table it would be easy to update anything in that table and not have to change the code anywhere else.

I have created a database that contains a table for menu items and each item has a menu_item ID,menu_Name and I also have a Price table and each price now has it's own price_ID

I would like to have code under the button click event like so:

createMenuItem(By Val Food_ID as Database object, By Val Price_ID As Database object)

display(Quantity,Food_Name,Food_Cost)

Food_Cost = Quantity * Price_ID



I know that this code does not work but If someone reading this has any ideas which part of database programming this falls under I could use a nudge in the right direction.

In a nutshell I would like to create menu items using the id's from the database

the data in the database would remain static and would only be used to supply arguements for my procedures and function that I use now.

Any help would be appreciated.

View 3 Replies View Related

Updating Database User SID In SQL 2005

Sep 27, 2006

Hi all

We're currently undertaking the development of our first SQL Server 2005 database and we've stumbled across a problem with our method of deployment from Development through System Test, UAT and, finally, to Production.

Under SQL Server 2000 we would build a new database in Development and assign permissions to a specific database user which was linked to an appropriate Windows Login - the whole build process was scripted. We would then hand the mdf and ldf files over to the Operations team who would attach the database to the System Test server, create a new Windows Login (appropriate for the environment), then run a script which would update the SID stored against the database user to the SID of the appropriate login.

e.g.

Database user (consistent through all environments) = AppDAL

Development: Windows Login = DOMAINAppDEVDAL

System Test: Windows Login = DOMAINAppSYSDAL

UAT: Windows Login = DOMAINAppUATDAL

Production: Windows Login = DOMAINAppLIVEDAL



The script, which directly updates the dbo.sysusers table in SQL 2000, links the AppDAL user to the appropriate Windows Login.



Is there any way to perform this task under SQL Server 2005? I'm aware of the sp_change_users_login stored proc, however this only works for SQL Server logins and not Windows logins. Also I'm aware that direct updates to system tables are not allowed under SQL Server 2005 and were not recommended under SQL Server 2000 so we were actually using an unsupported method during deployment. My guess is that we will have to change our method of deployment and rely on the Operations team to build the database in each enviroment from scripts, however I was wondering if there is another way before we go ahead.

Interestingly SQL Server 2005's sp_change_users_login stored proc contains SQL that does not run outside of the stored proc:

EXEC %%UserOrGroup(Name = @UserNamePattern).SetSID(SID = @loginsid, IsExternal = 0, IsGroup = 0)

SQL Server 2005 will not allow creation of a new stored proc that contains this SQL, wrapping the code in EXEC('') causes an error during runtime.

Is anyone familiar with the above syntax? Searching on Google has been fruitless.


Thanks

Chris

View 11 Replies View Related

Cannot Connect To Database After Exiting The Program.

Mar 6, 2008



Hello,

I have been writing this piece of software for quite a while. And as it got bigger and bigger (more forms, more datasets) I started experiencing the following problem.

Well, I use an MDF file as a database container that gets copied to the destination directory after each build.

Well here is what happens:
I launch my application, work with it, search the database and so on and so on.
Then I exit the application.
I launch it again and I get en exception saying that file counld not be located on the disk.
I close the app, and run it again. I get the same thing.
Somtimes after a couple of tries I get an error saying that my user does not have rights to access the default database. (I have windows authentication on SQL server)

Now here is the trick: I open SQL Server Management Studio Express detatch (Delete) the database from the default server (the only one in the system ".SQLEXPRESS") and the application runs again.

What am I doing wrong? How can I programatically detatch the database from the server (Maybe some sql command)? Do I need it though?

This is the connection string that I use for connection:



Code Snippet
Data Source=.\SQLEXPRESS;AttachDbFilename=|DataDirectory|\MyAppDB.mdf;Integrated Security=True;Connect Timeout=10;User Instance=False




But the confusing part of it is that it happend on my work computer and not on my home computer. I have the same User/Password/Workgroup/VS version/MS SQL versoion/Windows version on both machines.


Thank you.

View 4 Replies View Related

Error : Cannot Open User Default Database. Login Failed. Login Failed For User 'server/user'

Nov 22, 2007



i'm using the Enterpirse library logger to write logs into a database.
When choosing connection string i choose the database i want in the "connection properties" dialog box and
push 'Test connection' button.
everything goes well.

then i open the SQL Server Management studio express and connect to the databse to check some things,
from that point on , when i push the 'Test Connection' button in the Enterprise library i get the error:


"cannot open user default database. Login failed. login failed for user My'server/MyuserName'"


even when i close the sql server manager , it is still stuck - the connection test doesn't work anymore....
it only work when i restart the computer.

why ?

View 3 Replies View Related

How To Program A Button To Query Database On Another Page ?

Jan 16, 2008

hi.
When i click on the button, it will go to another page called fileB.aspx, it will query database based on textbox parameter from fileA.aspx and display gridview on fileB.aspx
It is based on sqldatasource. abit noob on programming visual basic.Protected Sub Button1_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles Button1.Click
'Code go here.End Sub
 
 

View 3 Replies View Related

When I Try To Restore A Database A Message Comes Up Saying That It Is Being Used By Another Program, How Do I Stop This?

Mar 17, 2008

I am reading a guide telling how to create a private server and it says I need to restore the database. So I go to File->Open->File->My Computer->Local Disk->Program Files->Microsoft SQL Server->MSSQL.1->MSSQL->Data->GunzDB. Then the following message comes up: "The file cannot be opened because it is being used by another process. Please close all applications that might access this file and try again."

The question is, how do I get past this? I need the answer as soon as possible, I am a newb with this program so I don't entirely know what I am doing. I have tried searching for the answer, but I cannot find anything.

Thank you.

View 3 Replies View Related

Error Msg: Login Failed For A User . For VS 2005 Websites With SQL Server 2005

May 30, 2008

Just installed SQL Server 2005 and tested my old VS 2005 ASPnet websites, which were connected toSQL Server 2000 databases before.  All my websites were created for local HTTP applications, coded with a connection string with User ID and Password.   The SQL Server 2000 was configured as mixed authentication (i.e. with User ID and Password).  These websites worked very well with SQL Server 2000 database server.Testing my old VS 2005 websites with SQL Server 2005 database, showed a 'Login failed for a User ''.' error msgalthough the 'Test Connection' on VS 2005 design showed a perfect query for e.g. a GridView control.  I have assured that the UserID/Password were correct for Management Studio Security object'slogin and Database Security's user.  The server instance was configured with mixed authentication mode.  One thing I am not sure of is, when clicking the Management Studio icon, a Connection dialog showed up, asking for a Windows or MIxed authentication?  I just stayed with the Windows authentication.  What does the authenticationmode have anything to do with the VS 2005 website connection?  Should I change to mixed authetnication mode?TIA,Jeffrey  

View 3 Replies View Related

How To Drop A User Defined Database Role In 2005?

Mar 9, 2007

Using Studio, I created a user defined database role but I can not delete it because



"TITLE: Microsoft SQL Server Management Studio
------------------------------

Drop failed for DatabaseRole 'test1'. (Microsoft.SqlServer.Smo)

ADDITIONAL INFORMATION:

An exception occurred while executing a Transact-SQL statement or batch. (Microsoft.SqlServer.ConnectionInfo)

------------------------------

The database principal owns a schema in the database, and cannot be dropped. (Microsoft SQL Server, Error: 15138)

I am quite annoyed because the "owned schema" is db_owner, which can not be unselected. Quite an innovation. How do I drop this relationship?

View 3 Replies View Related

Transact SQL :: Backup Database And A Folder From Some Program In One Bak File?

Jun 17, 2015

the idea is to put together a folder that is in some place in the computer, like "c:excel_fles" and the database full backup in a single .bak file, the database can be recovered with sql server management studio(but no the folder), the restoration of the program can be done with a program, I think it can be done with msdb, but I'm a little lost in the road.

View 4 Replies View Related

How Do We Determine Which User Database Tables Are Mostly Retrieved By User Or Modified By User?

May 22, 2008



Hi,
Please give the T-SQL script for this ? Thanks

Shanth


View 4 Replies View Related

A .NET Framework Error Occurred During Execution Of User-defined Routine Or Aggregate -While Creating A SQL SERVER 2005 Stored Prodecure In VS.NET 2005

Aug 15, 2007

 Running [dbo].[insertlogin] ( @log = hiten, @pas = hiten ).A .NET Framework error occurred during execution of user-defined routine or aggregate "insertlogin": System.Data.SqlClient.SqlException: Must declare the scalar variable "@Log".System.Data.SqlClient.SqlException:    at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection)   at System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection)   at System.Data.SqlClient.SqlInternalConnectionSmi.EventSink.ProcessMessagesAndThrow(Boolean ignoreNonFatalMessages)   at Microsoft.SqlServer.Server.SmiEventSink_Default.ProcessMessagesAndThrow(Boolean ignoreNonFatalMessages)   at System.Data.SqlClient.SqlCommand.RunExecuteNonQuerySmi(Boolean sendToPipe)   at System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(DbAsyncResult result, String methodName, Boolean sendToPipe)   at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()   at SqlServerProject1.StoredProcedures.insertlogin(SqlString log, SqlString pas).No rows affected.(0 row(s) returned)@RETURN_VALUE = Finished running [dbo].[insertlogin]. ***************************************************************all i am trying to do is :  creating a SP in VS using managed code and then trying to execute it. But every time i get the above error. If you can tell me how to edit connection string in this that would be very helpful. At present i am using :   Using conn As New SqlConnection("context connection=true") I tried to do "" ALTER ASSEMBLY SqlServerProject1 WITH PERMISSION_SET=EXTERNAL_ACCESS""but i get this error  ""  Msg 10327, Level 14, State 1, Line 1ALTER ASSEMBLY for assembly 'SqlServerProject1' failed because assembly 'SqlServerProject1' is not authorized for PERMISSION_SET = EXTERNAL_ACCESS.  The assembly is authorized when either of the following is true: the database owner (DBO) has EXTERNAL ACCESS ASSEMBLY permission and the database has the TRUSTWORTHY database property on; or the assembly is signed with a certificate or an asymmetric key that has a corresponding login with EXTERNAL ACCESS ASSEMBLY permission. If you have restored or attached this database, make sure the database owner is mapped to the correct login on this server. If not, use sp_changedbowner to fix the problem.""" *********************************************************************Plz help 

View 13 Replies View Related

Failed To Generate A User Instance Of SQL Server Due To Failure In Retrieving The User's Local Application Data Path. Please Make Sure The User Has A Local User Profile On The Computer. The Connection Will Be Closed

Dec 7, 2006

This is my first time to deploy an asp.net2 web site. Everything is working fine on my local computer but when i published the web site on a remote computer i get the error "Failed to generate a user instance of SQL Server due to failure in retrieving the user's local application data path. Please make sure the user has a local user profile on the computer. The connection will be closed" (only in pages that try to access the database)
Help pleaseee

View 3 Replies View Related

Can I Return A Value In A Variable From A SSIS Program Back To C# After The SSIS Program Is Run From C#?

May 21, 2007

Can I return a value in a variable from a SSIS program back to C# after the SSIS program is run from C#?

View 1 Replies View Related

Using Sql Server In DB Program

Oct 26, 2006

I am about to build a program that will require the use of DB. In the pass I used Access as my back end, but this time I would like to use Sql Server. I just have a few questions before I begin.

1. After deploying and installing my program, do I need to have sql server installed on users system or can the DB file exist on its own and just use ADO.NET to access the file? (As I done in the pass to access my Access mdb file)

2. If I can deploy a sql file -- can it be done with Sql Server Express?

3. If it can't be done, what db program should I use?

View 3 Replies View Related

Importing Database From Analysis Services 2005 To SQL Server 2005 Database

Jul 26, 2006

Hi all,

How can I Import a database from Analysis Services database to SQL SERVER using SQL SERVER 2005.

forexample the Adventure Works DW database from Analysis Services to SQL SERVER database.



Any ideas will be higly appreciated.

Thanx

View 3 Replies View Related

Fail To Install SQL Server 2005 (Clustering): SQL Server Setup Was Unable Add User

Oct 24, 2007

Hello all,

I have tried to install SQL Server 2005 Standard edition with CLUSTERING. I faced a problem and everything rolls back.

TITLE: Microsoft SQL Server 2005 Setup
------------------------------

SQL Server Setup was unable add user domain1xyz to local group domain1IT Security Admin-Group.

For help, click: http://go.microsoft.com/fwlink?LinkID=20476&ProdName=Microsoft+SQL+Server&ProdVer=9.00.1399.06&EvtSrc=setup.rll&EvtID=29512&EvtType=sqlca%5csqlsecurityca.cpp%40Do_sqlGroupMember%40Do_sqlGroupMember%40x6ba

I have refered to PostI=1659185 posted by Fly and it still won't be able to fix my problem.

I have added LOCAL SERVICE into the local group (SQLServer2005MSFTEUser$AAA$MSSQLSERVER), but it still can't work.

Please can someone help me on this. Thank a lot....

View 6 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved