質問編集履歴
20
title
CHANGED
File without changes
|
body
CHANGED
File without changes
|
19
title
CHANGED
File without changes
|
body
CHANGED
File without changes
|
18
title
CHANGED
File without changes
|
body
CHANGED
File without changes
|
17
title
CHANGED
File without changes
|
body
CHANGED
File without changes
|
16
title
CHANGED
File without changes
|
body
CHANGED
File without changes
|
15
title
CHANGED
File without changes
|
body
CHANGED
File without changes
|
14
title
CHANGED
File without changes
|
body
CHANGED
File without changes
|
13
title
CHANGED
File without changes
|
body
CHANGED
File without changes
|
12
title
CHANGED
File without changes
|
body
CHANGED
File without changes
|
11
title
CHANGED
File without changes
|
body
CHANGED
File without changes
|
10
title
CHANGED
File without changes
|
body
CHANGED
File without changes
|
9
title
CHANGED
File without changes
|
body
CHANGED
File without changes
|
8
title
CHANGED
File without changes
|
body
CHANGED
File without changes
|
7
title
CHANGED
File without changes
|
body
CHANGED
File without changes
|
6
title
CHANGED
File without changes
|
body
CHANGED
File without changes
|
5
title
CHANGED
File without changes
|
body
CHANGED
File without changes
|
4
title
CHANGED
@@ -1,1 +1,1 @@
|
|
1
|
-
|
1
|
+
うかかなゆかはらやや
|
body
CHANGED
File without changes
|
3
title
CHANGED
File without changes
|
body
CHANGED
File without changes
|
2
title
CHANGED
File without changes
|
body
CHANGED
File without changes
|
1
title
CHANGED
File without changes
|
body
CHANGED
@@ -1,55 +1,21 @@
|
|
1
1
|
```ここに言語を入力
|
2
|
-
select
|
3
|
-
ROW_NUMBER()OVER(ORDER BY a.ID) as ID
|
4
|
-
,姓
|
5
|
-
,名
|
6
|
-
|
2
|
+
コード
|
7
|
-
|
3
|
+
```### ```~~````````````````````````ここに言語を入力
|
4
|
+
ここに言語を入力
|
8
|
-
|
5
|
+
```
|
9
|
-
|
6
|
+
ここに言語を入力
|
10
|
-
|
7
|
+
```
|
11
|
-
|
8
|
+
ここに言語を入力
|
12
|
-
ID
|
13
|
-
,姓
|
14
|
-
,名
|
15
|
-
|
9
|
+
```
|
10
|
+
ここに言語を入力
|
16
|
-
|
11
|
+
```
|
12
|
+
ここに言語を入力
|
17
|
-
|
13
|
+
```
|
18
|
-
|
14
|
+
ここに言語を入力
|
19
|
-
|
15
|
+
```
|
20
|
-
from K3_Sheet1
|
21
|
-
where ID2 is not null
|
22
|
-
) as TA
|
23
|
-
|
16
|
+
ここに言語を入力
|
24
|
-
(select
|
25
|
-
ID
|
26
|
-
|
17
|
+
```
|
27
|
-
|
18
|
+
ここに言語を入力
|
28
|
-
where ID2=2 or ID=15
|
29
|
-
|
19
|
+
```~~
|
30
|
-
on TA.ID=TB.ID-1
|
31
|
-
|
20
|
+
ヘディングのテキスト
|
32
|
-
(select
|
33
|
-
ID
|
34
|
-
|
21
|
+
```
|
35
|
-
from K3_Sheet1
|
36
|
-
where ID2=3 or ID=12 or ID=16
|
37
|
-
) as c
|
38
|
-
on TA.ID=TC.ID-2
|
39
|
-
```### 前提・実現したいこと
|
40
|
-
sqlserver2008で
|
41
|
-
後でデータを追加しても二つ目の図のように表示できるようにしたいです。
|
42
|
-
インサートやアップデートは禁止です。
|
43
|
-
外部結合でなるべく表示してほしいと指示があったので
|
44
|
-
文を作ってみましたがデータが増えた時にこのコードだと書き換えないとだめだと却下されました。
|
45
|
-
ヒントを頂いてもよろしいでしょうか?
|
46
|
-
|
47
|
-
### このExcelの表を
|
48
|
-

|
49
|
-
### 下の図のように出力したい
|
50
|
-

|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
### 補足情報(FW/ツールのバージョンなど)
|
55
|
-
SQLserver 8を使用しています
|