Unable to update after accidentally pressed '\' in sqldeveloper - oracle-sqldeveloper

I'm trying to update a table in sqldeveloper but I accidentally pressed \ when I pressed enter. So the query becomes like this.
UPDATE students SET name='Brock' WHERE id='1';\
The scriptrunner task is running forever. When I closed the program and try again, SELECT worked but not for UPDATE.

Related

Magento 2 problem with reindexing at adminside

I am trying to re-indexing from admin side for stock and inventory as update on save. But it return error
We couldn't change indexer(s)' mode because of an error.
And in debug log is showing error like
1360 Trigger does not exist, query was: DROP TRIGGER IF EXISTS `trg_cataloginventory_stock_item_after_insert`
I am using magento version 2.3 series.
Thank you in advance.
I tried with indexing command then It will works fine but issue is at adminside re-indexing only.

User is getting "You tried to lock table '' while opening it, but the table cannot be locked because it is currently in use."

Getting this error, with no table listed, when the user logs in to the order system.
The query is, roughly
SELECT FormParts.*, qrySomeOtherColumns.*, CBool(0) AS ObjMissing INTO Temp_SessionFormParts
FROM FormParts INNER JOIN qrySomeOtherColumns ON FormParts.ID = qrySomeOtherColumns.FormPartID
WHERE EmpId = EmpID();
The data is coming from linked tables with a Postgres back end.
The data is going into the local table "Temp_SessionFormParts"
This is a local table in the front end, so no one else should have access to it.
Everyone else has a copy of the same database, but no one else gets the error.
Where it gets weird is that she only gets the error when she starts the app with our standard shortcut that copies the latest version.
copy "\\NASdiskstation\Install\Deploy\pgFrontEnd.accde" "C:\Merge Documents\"
start "" MSAccess.exe "C:\Merge Documents\pgFrontEnd.accde"
But if she starts Access from the Start Menu, and then opens the same database from the selections, it works fine.
Seems to me that those two routes should give the same result since she's already copied the latest to C:.
I went ahead an posted this question, since I had it written up, because I've seen this error a few times. So this may be helpful.
Normally, you can't SELECT INTO an existing table. But Access detects that situation and helpfully deletes the table before executing the insert.
Somehow this was failing.
DROP TABLE Temp_SessionFormParts
before the INSERT fixed the issue.
No idea why it sometimes didn't work for some people or why running Access directly changed that.

Oracle Forms 10g LOV not showing up second time

I have created Oracle Forms 10g form and want to display LOV by pressing the button. On When-Button-Pressed trigger I have:
go_item('MyBlock.Item1');
do_key('LIST_VALUES');
LOV has 6 columns and 2 of them are bound to 2 items: MyBlock.Item1 and MyBlock.Item2. When I press the button LOV appears and I can make a choice. LOV inserts data into MyBlock.Item1 and MyBlock.Item2 and everything is fine.
But if I want to make another choice and press the button again LOV doesn't appear. I don't know what is the problem.
Button and both items are in the same data block, I set Update Allowed and Required to No for both items and Mouse Navigate to No for button (I saw this on few forums).
Try putting synchronize command between these two lines:
go_item('MyBlock.Item1');
Synchronize;
do_key('LIST_VALUES');
I finally found solution (using oracle's OTN discussion).
The problem was stored procedure I call after first popping up of LOV. First time, after I chose a value I delete record of another block using stored procedure. In that procedure I set values of columns MyBlock.Item1 and MyBlock.Item2 are connected with. But on the form the old values remains on items. I removed update this two columns in procedure and it works now. But I needed this two fields to be updated to null automatically.
The solution is that I first change values of those items on form and then I call stored procedure. It works now.

Oracle Forms 10g - why do I have to click save so that my insert query will save to database

why do i have to click save button in the upperleft on formservlet so that my insert query will save to database? im sorry guys, quite newbie here thanks
here is my pl sql code in add button trigger:
begin
insert into tb_distributor
(distributor_id, distributor_name, distributor_type, distributor_desc)
values
(distributor_id.nextval,:DISTRIBUTOR_NAME, :DISTRIBUTOR_TYPE, :DISTRIBUTOR_DESC);
commit;
end;
Oracle Forms provides a great deal of functionality for you so that you don't have to write it. For example, if you base a block on a table, and if the user enters data and clicks "Save", Oracle Forms knows whether to execute Insert, Update or Delete statements appropriately followed by a Commit.
In your case, you have ignored that functionality and have hardcoded an Insert and Commit in your button code. Therefore, the user does not have to click the Save button, because the data has already been "saved" by your Add button.
open the property palette for this data block and change the database data block item to NO
and start writing your PL/SQL manually.

How do I delete a table from the MySQL Workbench catalog?

Recently I started using MySQL Workbench to design my data structures with an UML diagram. However, there is one thing I could figure out.
It seems that if I delete a table from the EER-diagram view, the table persists in the catalog view (as illustrated by the screenshot below). I could find a way to delete from the catalog view and it still list in the foreign key table reference selection screen.
This is very confusing. How can I effectively remove the table (not only from the view but from the whole project?
Notice, the two question tables one of which I deleted in the view and redesigned.
In case if the right-click and delete didn't work,
Simply drag and drop the table from the Catalog Tree to the Design area. Then you will see the table gets inserted there. From there, right-click on the table and select delete table. Then the table will get deleted from the whole project (assuming correspondent objects which are needed deleting as well).
Just had this problem before.
CMD + Backspace / delete on the keyboard will only delete the figure in the designer.
To completely delete the table and figure, instead try: Right-click > Delete 'table'.
I am using "MySQL Workbench Community (GPL) for Mac OS X version 6.2.3 revision 12313 build 2282 (32 bit)" and the action "delete 'table'" in the context menu (right-click on the table) did not work for me.
Believe it or not I had to restart the whole application. After the restart the delete action worked as expected. (1 object(s) deleted) [nothing about the object is kept in the DB]
This is how I discovered the difference between "delete" and "remove figure".
The "delete" deletes tables from the whole project, the "remove figure" only from the diagram (the tables still stay in the catalog).