Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Stored procedures and multiusers

Posted on 2002-05-06
6
Medium Priority
?
150 Views
Last Modified: 2010-04-04
First Question:
I am using interbase 6 with delphi 5. Now i want to create stored procedures for duplication checking and refrential integrity. I want to make some common stored procedure so that i can use one procedure for all the table. Is it possible? How?

Second Question:
With delphi 5 i am using sql server. To make my application multi uses what should i do. Any sites addresses or tips

answer asap :)
Rajni
0
Comment
Question by:rajniyadav
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
6 Comments
 
LVL 27

Expert Comment

by:kretzschmar
ID: 6993062
1. common is not possible, because the tables must be known at compile-time by the server, but you can do a stored-procedure for each table anbd change the name of the storedprocedure in your tstoredproc-object (if you use this)

2. the sql-server takes care of multiuser-access, no need to do something special (excepts your grants and userlogins)

meikl ;-)
0
 
LVL 7

Expert Comment

by:Motaz
ID: 6993063
Instead of stored procedure you can use Query and you can build it at run time such as:

ibQuery1.SQL.Text:= 'select * from ' + Edit1.Text;

Motaz
0
 

Author Comment

by:rajniyadav
ID: 6994249
kretzschmar

SQL server takes care of multiusers
but when we are running two application and two users are trying to modify the same record or when one user is modifying a record while some other user is deleting that record. Those kind of errors how to handle those.
0
Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

 
LVL 27

Accepted Solution

by:
kretzschmar earned 600 total points
ID: 6994543
one user may have no luck and will get an exception thrown by the server forwarded through the connection-protocol to your application

SQL server takes care of multiusers,
doesn't matter if there are more users and/or applications accesses the same record, SQL server knows this, because all must go through the server

well there is a transaction issue,
depending on how you connect to the server (ado,bde,..).
but the default settings are normally useable.

meikl ;-)



0
 
LVL 3

Expert Comment

by:VSF
ID: 6996184
Second question about common store procedures this week!

VSF
www.victory.hpg.com.br
www.boatoda.hpg.com.br
0
 
LVL 1

Expert Comment

by:pnh73
ID: 9005096
No comment has been added lately, so it's time to clean up this TA.
I will leave a recommendation in the Cleanup topic area that this question is:

Accept answer from kretzschmar

Please leave any comments here within the next seven days.
 
PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!
 
Paul (pnh73)
EE Cleanup Volunteer
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Have you ever had your Delphi form/application just hanging while waiting for data to load? This is the article to read if you want to learn some things about adding threads for data loading in the background. First, I'll setup a general applica…
Introduction I have seen many questions in this Delphi topic area where queries in threads are needed or suggested. I know bumped into a similar need. This article will address some of the concepts when dealing with a multithreaded delphi database…
Visualize your data even better in Access queries. Given a date and a value, this lesson shows how to compare that value with the previous value, calculate the difference, and display a circle if the value is the same, an up triangle if it increased…
How to fix incompatible JVM issue while installing Eclipse While installing Eclipse in windows, got one error like above and unable to proceed with the installation. This video describes how to successfully install Eclipse. How to solve incompa…
Suggested Courses

618 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question