Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 4 years ago.
Improve this question
I want to monitor changes that occur in the database. Say, for instance when an item is removed from the database. I want to be able to use an interface to monitor such changes and create an alert of how many no of items are left in the database . Every 5 min or so. Is there any plugin for java, or some kind of interface or something else? I will be grateful for the help.
Best Option Use DDL TRIGGER as it is DB change event meaning
CREATE DDL TRIGGER
ON DB AFTER DELETE AS
"YOUR ACTION STATEMENT" ;
Related
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 5 years ago.
Improve this question
I am making an online test with predefined questions and it's correct answer I let student enter their answer to each question and I took them and check them against correct form DB. is it better to call DB to for each answer to check or get all question right answer and make loop o(n)^2.I am using hibernate
A bulk operation is the best. It requires a single database roundtrip and you can do all the processing in the database so that you don't have to move one million records back and forth the DB.
For more details about Bulk Updates, check out this article.
In your example, it does not matter if the user had a test with 1000 questions. If they have a predefined right answer, you can match that in the DB automatically.
If you need to manually validate answers, do it with batch processing and process only N answers at a time and send all answers in a single batch to the DB.
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 5 years ago.
Improve this question
Currently, I can get back a list of users from an Active Directory group but I would like to return more than just their CN/name. How would I do this?
For example, I have an AD group with 20 members. I can get their names but I would also like to return their job title in the output as well.
In fact, you can get their DNs from the group. To get any other attribute, you need to do an additional query (getAttributes) for each member.
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 5 years ago.
Improve this question
English is not my first language, so sorry if there is a mistake in the grammar.
My question is, I have a database where I have bills, so when the bills are paid, I put a C of cancel in the table. Now, I am trying to do something in java, I want my jtable show me the bills that are not yet paid. I can import everything from the database to the jtable, but, what I need to do is import just the bills that are not paid?
Thanks
assuming you are using JDBC
you should write something like
SELECT * FROM TABLE_NAME WHERE BILL_PAYED <> 'C'
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 7 years ago.
Improve this question
I think I have to ask my question in another way.
At transactional database which of the following case has been recommended:
writing multi or 2 insert query for saving log of program on DB that has more pressure on server .
writing trigger after inserting for saving log of program on DB that has more pressure on DB.
Thanks for attention.
If you are sure that the insert to the DB will happen only from your application end then I would go for the first option by creating a procedure and include both the INSERT statement in a TRANSACTION block. which will make sure atomic operation.
But, in case there are possibilities that insert to the DB may happen through adhoc query or through third party ETL tool then you have no other option than having a trigger AFTER INSERT TRIGGER to perform the log insert operation (2nd option) since there is no way to call the other INSERT statement automatically or explicitly.
Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 8 years ago.
Improve this question
I am working on encrypting and decrypting of savable data of my application. For that i need to know the strings that saving in my database(I need them exactly just before saving into DB).
How to track that data while before saving ?? any help ??
thanks .
Hinernate supports the concept of interceptors and events. You can use the public boolean onSave(...)
You can do this with the help of Data Access Object design pattern. where u can track data before going to save by implementing your custom function