Thanks to Greg, Dave, Dagon and Carp.
My bad..I was not clear enough...
The table I am getting the data from is pretty much static (that is the data does not get modified/updated when I am fetching). And the table to which I am going to insert, is a staging table from which websphere picks the...
Ok..the scenario is very simple...........I do not commit after the first insert (as indicated in my code) and I still do not commit until I have looped through the cursor and inserted rest of the data. Only when I have no more records to insert..then I issue Commit.
Yes Greg. I am aware only on Commit it will be available for other users. And what do you mean by data is changed when I generate the INSERT?
My question is more on the sequence of how it is saved in the database.
Hi,
In the following cursor, I need to raise an exception when the Insert in the Loop fails.
My objective is, if all the records retrieved by the cursor are NOT inserted, then abort the insert transaction and do not commit.
Should my EXCEPTION be just before the loop ends or after the loop...
Hi,
My question is how oracle treats an INSERT transaction before issuing a COMMIT.
While I am doing an INSERT transaction, will oracle wait until I have inserted all my records within that procedure and then when I issue a COMMIT statement will the records be saved in a sequence for this...
Hello,
We have our offices across Europe and Asia. Our users in these offices access and run crystal reports (Business Objects Enterprise R 3.1 sp4)that is installed in our location in New Jersey.
There seems to be an issue with using date time functions like Currentdate, Today, Now...
Hello,
We have our offices across Europe and Asia. Our users in these offices access and run crystal reports (Business Objects Enterprise R 3.1 sp4)that is installed in our location in New Jersey.
There seems to be an issue with using date time functions like Currentdate, Today, Now...
I have 2 tables. Table A has information about inactivated print jobs and Table B has the description for Inactivation.
Note: Print jobs can be reactivated and again Inactivated. That is why Table A can have the same print job id more than once.
Now my objective is to retrieve Inactivated...
I have 2 tables. Table A has information about inactivated print jobs and Table B has the description for Inactivation.
Note: Print jobs can be reactivated and again Inactivated. That is why Table A can have the same print job id more than once.
Now my objective is to retrieve Inactivated...
SimonSellick,
I got my answer but just for information.
I kind of screwed up my tables, it is actually like this.
Table_1
ID DOC_ID DOC_VERSION NAME
Y1 ABC1234 2 DOC1
Y11 POI2322 1 DOC3
Y3 ABC1234 1 DOC1
Y5 EFGH904 3 DOC2
Y7 EFGH904 2 DOC2
Y9 EFGH904 1 DOC2
Table_4
COLID VERSIONID PROPERTYID...
Please ignore my above comment.
Thanks to GM it works like a charm!
However, I have seen one of your posts regarding pivots and I noticed that you have used MIN and gave an explanation that it would ignore NULLs.
In my case, I tried using MIN and it worked the same.
Is there any particular...
I have tried that and the output is not correct.
MAXV DOCUMENT_NAME DOCCODE DOCTYPE
2 DOC1 doccode3 pptdocument
3 DOC2 doccode3 pptdocument
1 DOC3 doccode3 pptdocument
I was able to flatten a table (made rows into columns). However my output has NULLS. I want to have just one row for every document name.
I do not want to create Procedure or use a Cursor. I want to know can this still be done with a query.
Thanks for your help!
Table_1
ID(PK) DOC_ID...
I am a Crystal Reports developer and I have always been working with Oracle database and this is my first time with SQL Server.
This is what I have been desperately searching for.
From my local PC, I want to connect to a SQL SERVER database which is on a database server.
I am aware that I...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.