Pravin Shirke

Ranch Hand
+ Follow
since Apr 05, 2008
Pravin likes ...
Eclipse IDE Chrome Java
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
1
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Pravin Shirke

Thanks a ton Jeanne.
7 years ago
Hi All,

I am thinking of getting my self certified in TOGAF v9.1. I have gone through the FAQ's, but still have some questions

1) Is there any pre-requisite for TOGAF v9.1???

2) Are there any classroom courses available in Mumbai (India)???

3) Other than study guide, do we have any other resources???

4) If i register for both the exams i.e. Part-1 & Part-2 do i have to attempt both the exams on a single day???.



8 years ago

ya but the process would fail if the scripts are turned off.....


Yes agreed. but i don't think there would be any practical scenario wherein scripts are disabled in this dynamic and user interaction driven applications world...
10 years ago
Hi Sourabh,

For implementation of resetting the flag to 'N' once the user closes the browser window, you need to invoke javascript function like:
Assuming, you have set the session id in context, then the listener would do the rest as its SessionDestroyed() method would be called; wherein you need to invoke DB call for the particular user to reset the flag to 'N'.
10 years ago
Hi Rajesh,

If i have not interpreted it wrongly... then you need to display some text instead of those url and on click it should take you to the url mentioned. If this is the question then you should use. html anchor tag
Hope this helps
10 years ago
Hi Manish,

I suggest you keep a flag in your user maintenance table, with default value as 'N'. (i.e. not logged in) and once you login successfully into the application update the flag as logged in (some flagging value like 'Y') and every time you try to login to the application for a particular user just check that the value of the flag is 'N' if it is 'Y' redirect to login page and failed the login process with appropriate message for the user. This will work irrespective of machine the user has logged i.e. it will ensure that only once session exists for a user.

Now in order to handle the other scenarios of handling if the user close the browser without logout and if session times out; Then in this case you need to implement a SessionListener and that should be called when the user closes the browser window upon which it will update the flag to 'N'.

Hope this helps...
10 years ago
Hi Ranchers,

I want to create an OS user in windows using Java 5/6. Can anyone guide me in how to implement this functionality.

Thanks in advance.
11 years ago
Hi,
i have one requirement where there is master table with some number of columns and i have a common transaction table for all masters with some columns as given below.

Master table
test1
tranid | ename | eaddr
rams001 | pravin | pune
rams002 | kaka | nashik

and my transaction table as:-
Transaction table

tran1
tranid | tablename| fieldname | old_value | new_value
rams001 | test1 | eaddr | marol | pune
rams001 | test1 | ename | pravin shirke | pravin
rams002 | test1 | ename | mama | kaka

here as per my table structure value for tranid rams001 have changed for columns ename and eaddr. so there are two records in transaction table as shown above with previous and current value.
In, transaction table we are maintaining tablename and fieldname also to identify the master and the columns which were updated/changed. and my desired output is as follows:

transid |ename | eaddr | old_value | new_value
rams001 |pravin | pune | eaddr=marol;ename=pravin shirke | eaddr=pune;ename=pravin;
rams002 |kaka | nashik | ename=mama; | ename=kaka;

the values in old_value and new_value should be semicolon separated with column names as well only those columns which were changed.
i have used the below query but the ouput and the output does not match kindly help in acheiving what i want.

select t1.tranid,t1.ename,t1.eaddr,t2.old_value,t2.new_value from test1 t1, tran1 t2 where t1.tranid=t2.tranid;

i also thought of using pivot where we convert 'n' rows to columns dynamically any help in that also would be appreciated as i have never used pivot.
Please Help....
Hi ranchers,

Our production server is AIX and our db is DB2 and our Application server is WAS(Websphere application server).In our application their are couple of triggers on production servers which gets executed most of the times. but sometimes the trigger fails and because of which their is inconsistency in the tables. Also we are not able to find any exception or error message in the application log. So my question is can we monitor the trigger activity or log the trigger failure in the logs.
we dont want to create another trigger for logging the trigger activity in the logs. Also, we dont want to modify our triggers.

Please help i am stuck here . any pointers on how to proceed further will be appreciated.

Thanks & Regards.
Hi Neo,
In struts ActionServlet is the default Controller. you are right till here, but you can create your our controller's extending one of Action,DispatchAction etc. please search for it, and create a servlet or CustomAction to generate the pdf. which you can call using javascript from your jsp.
Hope this helps

13 years ago
JSP
Hi Adi,
Can you post the url please. whether it is relative url or absolute url? which you have used?
13 years ago
Hi Arjun,
Congrats for your SCJP. and for SCWCD or SCBCD. SCWCD is for web applications. (i.e) Servlets and Jsp. whereas, SCBCD is for Enterprise Component (EJB) so you decide what you want to do. and the prefered book for SCWCD is Head first servlets and jsp by cathy seirra and bert bates, another is SCWCD 1.4 Books Study Guide by hanumant deshmukh.

Hope this helps and once again congrats for SCJP
Hi ravi,
servlets are not singleton please refer to the link provided by Eduardo.

Note: Eduardo

load on startup does not means that the container will create 5 instances. please go through scwcd faq's and links in javaranch.
hope it helps
13 years ago
Hi rumana,
please use code tags.

and for your error, try using prepareStatment and use setString or setInt according to your column type. i think this will suffice.

good luck
13 years ago
JSP
Hi David,
thats what i am asking how should i proceed in achieving the same. any pointers for same will do.

thanks
13 years ago