有没有办法在reverse-interactive-search
模式下使用C# interactive
?我无法找到它。
我正在reverse-i-search
或bash
中寻找与irb
类似的功能。
答案 0 :(得分:0)
DO $$
DECLARE
-- currentRow [relevant datatype];
BEGIN
FOR counter IN 1..(SELECT count(*)FROM territory2_t) LOOP -- There are 13 total rows
-- **assign currentRow to counter**
RAISE NOTICE 'Counter: %', counter; -- debugging purposes
UPDATE terriory2_t
SET total_sales_person = ((SELECT count(*)
FROM salesperson_t
WHERE salesterritoryid = currentRow.territoryid)*1) -- *1 is for debuggin puporses
WHERE territoryid = currentRow.territoryid;
-- **increase currentRow by 1**
END LOOP;
END; $$
中没有确切的功能reverse-i-search
,但您可以navigate in the history by prefix。