SoftTree Technologies SoftTree Technologies
Technical Support Forums
RegisterSearchFAQMemberlistUsergroupsLog in
[11.5.362 Pro] - Picking a sequence from popup (Postgres)

 
Reply to topic    SoftTree Technologies Forum Index » SQL Assistant View previous topic
View next topic
[11.5.362 Pro] - Picking a sequence from popup (Postgres)
Author Message
gemisigo



Joined: 11 Mar 2010
Posts: 2100

Post [11.5.362 Pro] - Picking a sequence from popup (Postgres) Reply with quote
It's nice to have SA encapsulate the selected sequence when picking it from a popup but sometimes the resulting code is more of a hindrance than a help.

For example, when trying to drop a sequence,
Code:

DROP SEQUENCE "stage".nextval('"seq_obu_status_data"')

will not run.

Neither will work the following one when trying to select the next value from a sequence not from the current schema:
Code:

SELECT "stage".nextval('"seq_obu_status_data"');


In both cases, the schemas were expanded using the right arrow key, which, as I've been told in another topic a long time ago, inserts the schema and then reopens another popup. When the schema is expanded by clicking on the + sign the whole procedure happens in a single popup and only the schema_name.sequence_name is inserted, which is good for a DROP statement, but does not help the SELECT statement by encapsulating with the nextval function.

These codes are all auto-generated by SA when picking the sequence from the popup. Check the following short video here.
Tue Apr 20, 2021 1:44 pm View user's profile Send private message
SysOp
Site Admin


Joined: 26 Nov 2006
Posts: 7833

Post Reply with quote
In my test database I'm able to reproduce the nonsense code generated for DROP SEQUENCE. For select SELECT it appears similarly and also incorrect. I'm using factory default settings.

It looks like whenever it finds sequence selected in the popup, it always inserts ...nextval(...) without evaluating the context.



Tue Apr 20, 2021 2:49 pm View user's profile Send private message
SysOp
Site Admin


Joined: 26 Nov 2006
Posts: 7833

Post Reply with quote
Here is the tracking issue number for this defect #SA0040783

As a short term workaround, please use drag and drop from DB Explorer to the editor to copy the sequence name.
Wed Apr 21, 2021 2:49 pm View user's profile Send private message
Display posts from previous:    
Reply to topic    SoftTree Technologies Forum Index » SQL Assistant All times are GMT - 4 Hours
Page 1 of 1

 
Jump to: 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


 

 

Powered by phpBB © 2001, 2005 phpBB Group
Design by Freestyle XL / Flowers Online.