[英]Plpgsql: How can i perform the following task in plpgsql?
--SQL Server中的語法
SET @InnerQuery = @InnerQuery + N'SELECT * from [' + @TableName + '] UNION ALL';
-在這里我嘗試在plpgsql中進行上述查詢。
innerquery:= innerquery UNION ALL select * from '%',TableName; --Not in working state
嘗試這個:
execute innerQuery || ' union all select * from "'
|| tableName || '"';
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.