<og:query command="{@command}" debug="{@debug}" dbid="{@DBID1}" maxRowCount="{@maxRowCount}">
	select '1' WRITABLE,'' TABLE_NAME,CLM,NAME_JA,EDITOR,RENDERER,DBTYPE,'' BIKO,UNIQ,SYSTEM_ID
	from GEA03 A
	where A.SYSTEM_ID in ( '{@SYSTEM_ID1}','{@AST1}')
	and   A.FGJ       = '1'
	and   ( A.EDITOR = 'MENU' OR A.RENDERER = 'MENU' )
	ORDER BY A.CLM
</og:query>

<og:tableFilter
	classId	= "DBSELECT"
	dbid	= "{@DBID1}"
	keys	= "APPEND"
	vals	= "true"
	selectedAll	= "true"
>
	select CASE
			WHEN B.LNAME LIKE '%:%' THEN B.LNAME
			ELSE A.CODE{@DBF.CON}':'{@DBF.CON}B.LNAME END BIKO
	from GEA04 A inner join GEA08 B
	on A.CLM{@DBF.CON}'.'{@DBF.CON}A.CODE = B.CLM
	and A.FGJ = B.FGJ
	and A.SYSTEM_ID = B.SYSTEM_ID
	where A.SYSTEM_ID = [SYSTEM_ID]
	and A.CLM = [CLM]
	and A.FGJ = '1'
	and B.LANG = 'ja'
	order by A.CLM,A.SEQNO
</og:tableFilter>

<og:query command="{@command}" debug="{@debug}" dbid="{@DBID2}" maxRowCount="{@maxRowCount}" scope="request">
	select '0' WRITABLE,UPPER(TABLE_NAME) AS TABLE_NAME,UPPER(CLM) AS CLM,NAME_JA,EDITOR,RENDERER,DBTYPE,BIKO,UNIQ,SYSTEM_ID
	from GF05 A
	where A.SYSTEM_ID in ( '{@SYSTEM_ID2}','{@AST2}')
	and   A.TBLSYU    = '{@TBLSYU2}'
	and   A.FGJ       = '1'
	and   ( A.EDITOR = 'MENU' OR A.RENDERER = 'MENU' )
	order by CLM,TABLE_NAME
</og:query>

<og:tableMerge
	action        = "DIFFERENCE"
	masterScope   = "session"
	masterKeys    = "CLM"
	diffKeys      = "BIKO"
	modifyClms    = "UNIQ"
	slaveScope    = "request"
	display       = "true"
/>

<og:value key="lblKey" value="C" />

<og:hidden name="SQL">
	UPDATE GF05 SET
			BIKO      = [BIKO],
			CDKH      = 'C',
			DYUPD     = '{@USER.YMDH}',
			USRUPD    = '{@USER.ID}',
			PGUPD    = '{@GUI.KEY}'
	WHERE UNIQ = [UNIQ]
</og:hidden>
