I have a SQL Server 2005 Express database that was designed to be used by one client. What is the best way to change the design so it can contain multiple clients that can only see data entered by users of each client organization?
Also I'm using the asp.net membership database to handle login and profiles. Can this be used with my multi client database?
Hi Everyone,I have one database file which needs to be accesable to both a .net website and a vb.net application.The application collects data from the 'real world', processes it and adds the data to the database. The Website reads data from the database and displays the data in a graphical format.Now for the problem; While the Application is connected to the database (adding data), the Website is denied acces to the database. All connections to the DB are disposed when the Application is not uploading data, but the Website continues to be locked out (making it pretty useless) Closing the Application makes the Website work fine, but of course this means no 'real world' data can be updated.Can anyone suggest what is happening here, and more importantly how to fix it? A walkthrough must be available for this problem somewhere,... I just can't find it :(Thanks all,*The Stressed One*
Hi all,I've got a question concerning synchronization of multiple database clients.Consider a database, accessed by two clients. Is it guarantted, that ifclient 1 succefully commits a transaction, client 2 _instantly_ sees thechanges made by client 1?thx and regards,StephanP.S..: For MS Jet databases I know there _is_ a delay between writing datato the database and being able to read this updated value from anotherconnection,so the question refers to "real" DBMs (esp. SQL Server) only ;)
We have a situation where multiple-random client connections to SQL server get disconnected.
The workstations are not consistent, the time is not consistent, and the functions being run are not consistent. One thing that we can reproduce is that sometime, but not always, if a workstation runs a function that calls a specific stored procedure (SQL native client, ADO, SQL Server 2005 SP2), during the course of the parameter validation (after the .execute) SQL sends an ACK, RST followed by two RST TCP packet back to the client and disconnects the connection.
At the same time, several other connections across multiple computers are also dropped by SQL. However, some computers may have multiple connections to SQL and some, but not all of these will be dropped. Other computers will not have their connections dropped at all.
No SQL server errors are logged. Trace flags 4029 and 3689 have been set.
We have the network packet traces and the SQL profiler output to show this.
This is not reproducable at any other site.
Any ideas on what this could be would be greatly appreciated. -- Dana Comolli MS ISV Partner
I've been running SQL Server 2005 for over three months, and have got the database up to speed. Using SSMSE for an interface.
I've have been trying to get the Intranet to link to the database (ASP), but after a little research i found we needed to change the Authentication from 'Windows Authentication' to a mix of windows auth and sql login. Needing to restart the server for the changes to take effect.
After the restart things started to go pear shaped.
Before the restart we were able to run queries from different clients at the same time (4 workstations). Now we are unable to access anything on the database if a query is running on a seperate client. As in table properties, running a query. As i've said, we were able to do this perfectly fine before the restart.
We also use other programs to generate records for the database. These programs now have difficulty connecting to the database. We've gone through the wizards and as far as we are aware things should be working. We have created extra username/logins for these programs so not one computer/client/program uses the same connection login. However, they are unable to connect even after the wizard says there is no problem connecting to the server.
Is there any *restore to factory/default settings* button? We've even tried reverting to Windows Authentication to try and solve the problem, but it didn't work, we're pretty dependant on the database for day to day operations.
I have a system use MS SQL 2005 & .NET 2.0, my tables don't have rowversion, but I heard SQL 2005 manage a rowversion by itself, can I use this to do a "ConflictDetection".All I try to do is I want to get a error when I try to update a row which been modified by someone else after I read row. Thanks.
I have a script that needs to be run for 50 different @ClientID. I dont want to run this script individually for each clientid. Would 'SET @clientID in (111, 222, 333) work? I've been told that it wouldn't. Short version of the script is.....
I think I will have a problem with Id’s when I do merge replication. The problem is, I have several clients (local shops) who can do additions to a (Customer) table. Other tables will link to that table (things that a customer buys) with their foreign key, so the id of this table is very important. Now, twice a day that table with customers is merged from all clients to the central server. (the table with things that the customer buys, does not needs to be merged as it only remains local).
Possible problem: if we assign ranges to identifiers for each client (thus local shop), which will be the best option we found until so far, how can we then detect the doubles? (with doubles, we mean that when the same customer is added in two local shops for a first time, then we will have the same customer twice in the central database)(afterwards, when we delete one customer row in the central database, we might have a id conflict when we merge back to the clients -as a customer might have already bought some goods at the two different shops meanwhile-)
What’s the common practice to resolve this? (we need to do Merge Replication, because during the day, our local shops are disconnected from the central server)
We have multiple databases (1 per client) and we want to use reporting services for ad-hoc reporting. Our authentication is done by using client's database so security is custom.
What is the best way to set this up? Is it possible to somehow allow users/admins to use only their database and never see any others? I know we can install a separate instance of RS and do that but I am wondering if there is a better way to run multiple clients doing different reports using exclusively their databases without having to create a new instance.
Hello,I'm looking into offering a custom data driven web app that I wrote for an organization that I'm apart of to other similar organizations. I would be hosting the data and web application code on my dedicated server. This application is using the membership api supplied in .NET 2.0 and also has my own custom data tables within it.My question is what would be the best way to add clients to this? Should I simply create a new database for each new client like so: ACME_Database, ABC_Database, AAA_Database etc. Or should I add some sort of client "Tag" (tag meaning column within each datatable) to these databases and then update my SQL queries to process them accordingly. I imagine I could do both but I guess I need some advice from people that already had experiance with providing this kind of service. Thanks!Jason
Greetings, I have a requirement for a SQL Server 2005 database to notify 3rd Party applications of a table change. As is stands now, 3rd Party applications access the database via a Data Access Layer (DAL) dll (C#). I'd like to somehow implement an asychronous event notification scheme via the same DAL to these clients.
Can someone offer a clever way to implement such events?
Broker Services? I am under the impression the SSBS is typically deployed when databases are to communicate with one another.
Hello AllI am using SQL server 2000 as the backend of my application but don'twant my clients tobe able to view or edit the database tables, storedprocedures , view etc using enterprise manager or query analyser (orsimilar tools)How can this be done ?I searched a lot for this but unable to get the correct answer isthere anybody to give full solution regarding this.Please relpy me as early as possible
I'm trying to create a database that takes specific information from a number of databases on different servers to make some reporting that we have much easier.
I'm pretty new to SQL so I'm not sure of the best way to proceed. I read an article that suggested I use the OPENROWSET command. The problem is, the version of SQL that came with one of the programmes we use is limited and will not allow you to turn on the allow "Ad Hoc distributed Queries" so the SLQ statement will not execute.
I'm confused why it won't let me to connect through ODBC as I've created a web page that selects data from this database with no problems!
Here is the SQL statement that I've written to make sure it is the correct one (on the msdn library page it said that this was the ODBC connection):
SELECT a.* FROM OPENROWSET('MSDASQL','DRIVER=(SQL Server);SERVER=APPOLOACT7;UID=sa;PWD=***************', 'SELECT * FROM MDCTestAndDev.dbo.TBL_CONTACT') AS a
I've also created the ODBC connection using the tool on Administration Tools>Data Sources ODBC
Any help would be greatly appreciated (also any ways of selecting from one database and inserting it into another will be helpfull)
I'm trying to get the last ten unique clients viewed by each user. I have tried using the TOP (N) but it does not show the last ten just any ten. When a user views a client record, a record is saved to the tblUserRecentViewedClients table and includes logID (key), client_id (int), username (nvarchar), lastviewed (datetime). Here is what I have so far. Can anyone offer any suggestions?SELECT TOP (10) tblUserRecentViewedClients.UserName, tblUserRecentViewedClients.Client_ID, tblClient.FirstName, tblClient.LastName, tblClient.CompanyName FROM tblUserRecentViewedClients INNER JOIN tblClient ON tblUserRecentViewedClients.client_ID = tblClient.client_ID WHERE tblUserRecentViewedClients.UserName=@UserName GROUP BY tblUserRecentViewedClients.UserName, tblUserRecentViewedClients.Client_ID, tblClient.FirstName, tblClient.LastName, tblClient.CompanyName
I have to install SQL 7.0 Client software (query analyzer, client connectivity) on A LOT of workstations that only have Internet Explorer 3.0 ... Is there any way of getting around not upgrading to 4.0 sp1? If I try to just install 7.0 client, it errors out saying I need IE 4.0sp1. I really don't want to have upgrade IE!!!
Are there any issues with retaining both the SQL 6.5 and SQL 7.0 clients as installed components on our desktops? We have a number of SQL 6.5 and 7.0 Servers which have some fairly specific client side requirements and I am trying to ascertain what the potential impact is to rolling out SQL 7.0 components to a separate directory to allow all applications to coexist. My specific concerns are with the shared DLL's in system32 and with updated 7.0 executables that share the same name (i.e. BCP, etc) and resultant path issues.
Any feedback or articles that cover this subject would be appreciated.
Company with one head office and one remote office. In the two offices I have two domains with two PDCs. The two networks are connected with eachother through leased line and the routers are configured properly. The SQL Server is on the PDC in head office and "local" clients connect fine. I cannot connect from the remote office. I think that I have folowing solutions:
1. make trust relationships between two domains - it will be hard a little bit because second PDC is samba on linux
2. make all clients in remote office to be members of the head office domain - potential problems if the leased line drops
3. make all clients to log in with same account as SQL Server logs locally - stupid
Can anyone recommend a tool where I can email to someone both the SQLquery and the result set? Right now, I'm just copying the results to aspreadsheet. No, I can't use Reporting Services or Crystal Reports.
“HELP !! We’ve lost about 25 client’s websites. The databases were backed up along with all the actual files contained within each CSK….in addition, all the original databases are intact & can be reattached to the new SQL server…..the problem that exists where the original CSK files do not recognize the original database once it is reattached to the new SQL server. Any help would be most appreciated. This is the error…… Login failed for user 'DARRYL1ASPNET'. Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. Exception Details: System.Data.SqlClient.SqlException: Login failed for user 'DARRYL1ASPNET'.Source Error:
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below. Stack Trace:
We’re having trouble getting error messages to show up on clients. Our ADO research indicates that the Errors collections is populated, “automatically” – what you do with it is up to the application. Our collection is not being populated. MS says the SQLOLEDB provider has a problem (the collection is not filled) if SET NOCOUNT is OFF. We have SET NOCOUNT ON and still have the problem. We have narrowed the problem down (the example below is an abbreviated version) to “the Errors Collection is not populated if the Raiserror follows a SELECT statement that returns a recordset”.
In the code below the simple select run after the first RAISERROR appears to “block” the Error Collection. Is this by design? Are you never supposed to be able to return records and messages from the same program? We can code around it if we have to, but the documentation seems to indicate our approach is viable.
Option Explicit Dim db As New ADODB.Connection Dim cmd As New ADODB.Command Dim rs As New ADODB.Recordset
Private Sub Command1_Click() On Error GoTo errmsg
Set rs = New ADODB.Recordset Set cmd = New ADODB.Command
With db .Provider = "SQLOLEDB" .ConnectionString = "Data Source=Jeanne;trusted_connection = true;integrated security=sspi" .Open .DefaultDatabase = "DevTime21" End With
I am someting of a newbie to SQL Server, but I am an experienced C++/C# programmer.
I have a SQL Server 2005 DB to which are connected 50 or so clients. The clients are running my software, written in C# and connected to the server by an OleDBConnection. These connections are long-lived; in some cases they remain for days or more. Now and again, one of the clients causes a change to the DB (not structural, just normal adds, update and deletes). But most of the time the clients are just viewing data in the DB.
What I need to happen is that when any item of information changes, the display of that information on any of the clients which are viewing it must be updated quickly. It doesn't have to be instant, but a delay or more than, say, 5 seconds is unacceptable.
It is like a share-dealing or foreign exchange system (although that is not what it is) where the traders' screens have to have up-to-date information at all times. Note that the information received by the clients does not have to describe the change in detail, just a hint to the client as to what change has happened so that the client can refresh its views.
I can think of a way of doing this but it is really nasty. The hints would be recorded in a time-stamped table. Each client would poll every couple of seconds by calling a SP, which would return the hints which have been added since the last time that client polled. But polling is horrible and I am sure that there must be a better way.
A route that looks promising is InfoMessages. But, reading around the subject, it looks like these cannot be unsolicited and spontaneous; they only arrive on a Connection as a result of some action on that Connection.
I may have missed something, or maybe InfoMessages are not the way to go. Can anyone offer me any advice, please
how can i communicate with other clients over SQL 2005?
I mean, i change data of database from a client, how to make othere clients do some actions acording to the data change .( let other client print some report ect.)
I have a couple of client programs continuously dumping data into a SQL 7.0 database. I use ODBC connections that remain open as long as the client programs are running.
The memory consumed by SQL grows until all the system memory is consumed at which point the clients freeze (SQL no longer responds). Restarting SQL Server "cures" the problem for a few hours.
I've tried limiting the amount of memory used by SQL, but this only accelerates the eventual client freeze-up. At the moment, I let SQL dynamically consume memory.
iam under process of upgrading sql7 to sql2000. already i upgraded clients to sql2000. then i got problem with some of our applications to connect to sql7 server. then i replaced in clients new ntwdblib.dll with old one then it works fine. to overcome this problem shall i install MDAC2.6 on server, where sql7 is there.
Is there any problem to SQLserver7.0 with MDAC2.6 ? because i want to install MDAC2.6 on production server with sql7.0.
reading help i know that client for working with mssql remote db must have installed oledbprovider for XXX
i always use ole db provider for ODBC , this ole db provider is installed with mssql, but what exactly must to have the clients which are not familiar with this ole bd provider, what files ?
I am trying to write a query that counts how many clients were part of program at the first of each month.To make it simple, the data comes out of one table which looks like this:
Client # Program Start_date End_date 1 Fruit eater 03-27-2014 01-10-2015 2 Veggi eater 01-16-2015 null 3 Veggi eater 12-05-2013 04-16-2015 4 Fruit eater 10-01-2014 11-30-2014
Currently I have a very ugly solution that I know is not the best one:
Select sum(convert(int,Jan_2014))as Tiers_in_Jan_2014 , sum(convert(int,Feb_2014)) as Tiers_in_Feb_2014 , sum(convert(int,Mar_2014 )) as Tiers_in_Mar_2014 , sum(convert(int,Apr_2014 ))as Tiers_in_Apr_2014
Hey guys!, is there a way to raise an exception through an insert trigger... and that exception will be able to raise on every single application connected to that database at the time? not just the app that actually triggered the insert...
I want to connect over the internet to get data from clients.What wouldbe the easiest method and the most stable methos to do it1.Use a Point to Point prtotcol from the client pc and then upload thedata to our sql server2.Export the data from the clint pc in XML format and then Enter it inour computer.3.Have all clienst ftp the data in a dirctory and then upload the xmlfiles from the directory?Thanking you in anticipation.Would love it if we could discuss anddistribute our thoughts on this.Ajay
Hi,I am having a hard time setting up an SQL Server 2000 DeveloperEdition instance for remote clients. The instance is running well andI can connect to it on the local computer. When I try connecting fromanother computer using Enterprise Manager with the server's IP as theinstance name, I always get the usual "Specified SQL Server not found"error. I have used Enterprise Manager many times to connect to localand remote servers (which were set up by someone else obviously).I used the client network utility on the client to make an alias forthis server and have it use the TCP/IP library for port 1433.I understand that SQL Server listens on port 1433 for connections. Ihave a firewall on the server and setup 1433 forwarding. But when Iuse Enterprise Manager to try to register the server, the firewalldoesn't even show a connection attempt on port 1433 (it logs allconnection attempts).When I use telnet to port 1433, the firewall logs the attempt butthere is still no connection, as if the server isn't actuallylistening on 1433 at all. I can't seem to find any help on getting theserver listening, as if it supposed to be easy to set up so I don'tknow what I'm missing. I guess I have the following questions:1) Does anything have to be done on the server side to set it up tolisten for remote client connections?2) How do I set the port on which the server listens in case I want tochange from 1433?3) Does anything have to be set up on the client side other than usingthe client network utility?4) Why does Enterprise Manager not seem to even attempt a connectionon port 1433 when I try to register this server?Any help is appreciated.
My problem comes from this situation: I have two PC connected via a network calble; on the first I have SQL Server 2005 Express, an MDF data file in a shared directory under the "Document and Settings" path, and my program written in VB .NET 2005. On the second PC I have only my program, and I would like to have it connect to and work on the MDF on the first PC.
The program on the first PC works well and uses a connection string like the following:
Data Source=.SQLEXPRESS;AttachDbFilename=<path><name>.mdf;;Integrated Security=True;User Instance=True I am able to access to SQL Express from the second PC (I have enabled the Client to use the right TCP ports, told the firewall to let them work and enabled the Guest user on the first PC to use SQL Express), but from Visual Studio Server Explorer I cannot reach my data file: any attempt fails telling me that I cannot open it because is in a shared location... I can only open the DBs located in the "Data Directory" of SQL Express...
In other words, what should I do to have two or more clients work on the same DB under SQL Express? Is it mandatory that the DB .MDF file resides in the "C:ProgramsMicrosoft SQL ServerMSSQL.1MSSQLData" directory so that it can be permanently attached to SQL Express?