Ognacの雑感

木漏れ日々

目次

Blog 利用状況

書庫

ギャラリ

ネーミング規則

開発標準の重要な事項にネーミングルールがあります。といっても、何桁構成で頭はi始まりとかいうレベルでなく、ネーミング視点の話です。
VSSなどのドキュメント管理ツールではにCheckIn/Outという用語を使います。これは、ドキュメントライブラリーからみて、出し入れを言います。自分のところに持ってくるのだからで引き出しだすのがCheckInだと錯覚する人がいまだにいます。
RDBからデータを取得し、データインスタンスに取り込むプログラムで
  Class.method  は get_顧客行()  となってます。
  その中で呼ぶストアード名が  sp_Set_顧客行()  となってました。
バグってるやん、と追跡すると、 sp_Set_顧客行() は select * from xxx where xxx となっている。
確かに、仕様通りに走る、違和感一杯。
  なんで、sp_Set_顧客行() という名前?  問い合わせると、
このストアードはデータを取得して、相手のデータクラスのメンバにセットするので sp_Set_顧客行にしました。データクラスがアプリケーションの主体だから、命名規則の視点はそこを基準にするべきだ。とのこと。

確かに、命名するときの視点は固定にすべきだと主張してます。しかしこれは間違っている。ストアードだから、RDB視点で命名しないと一貫性が崩れます。視点固定ルールにそぐわない事象に直面すれば、「なんか変」と感じて欲しいものです。

以前に書いた「命名のルールと視点 」http://blogs.wankuma.com/ognac/archive/2008/04/16/133279.aspx と被るのですが、
極東や中近東という言葉があります。これは、日本周辺や、イランイラク周辺を意味しますが、変な用語です。 日本視点でないので、読む時に引っ掛かります。
西洋からみて、東に位置するから中近東(near East/ middle East)であり、最も東の端だから極東(far East)です。これを直訳しただけなんですが、日本視点の用語になってません。日本語で文章を構築するときは、日本視点の用語で統一すると読み易いですが、視点がプレると読みにくいてす。
上越新幹線と上越市と上越地方は無関係です。これもネーミング視点の不統一が生んだややこしさでしょう。
上越新幹線は上越市を通過しません。上野国と越後国を結んでいるところに由来し、上越地区とは無関係てす。
福岡県に京都郡があり、北海道に北広島があるように、地名の由来は、柵があり、ルール化はできませんし、Renameもできません。しかし。合併などで、新しい地名をつけるときや、新しい用語を作るときは、一定した視点でユニークな名前を付けて欲しいものです。 東京都xxxx保険組合保養所 を見たとき、戸惑いました、京都地場の東-京都xxx会社の保養所でした。
統一すれば、楽なのになぁと思うのです。しかし。
聖書などによくでてくるペテロは peterのことだし、ベネチアはペニスのことだし、(別物と思っている人もたまにいますが)
切手と小切手、にっぽんとにほん、貯金と預金、振込と振替.....類似語を的確に無意識に使い分けている日本人の言語感覚って素晴らしいなぁと思うのです。
 なおさら、新語を作る人は気を配って欲しいと思います。

投稿日時 : 2008年7月28日 0:05

Feedback

# re: ネーミング規則 2008/07/28 1:30 れい

えーと…
かな入力固有の恥ずかしい間違いが。

もちろん、「別物」ですよ。
語源も違いますしね。

# re: ネーミング規則 2008/07/28 1:34 Pasie.

 命名基準は難しいですね。策定したところで遵守してもらうための努力を相当に強いられる割に、徹底率はあがりませんから。

 私はプログラミングとは名前付けだと思っているのですが、名前なんてなんであっても、ロジックが正しければ正しく動くのでレビューなどでも指摘しづらい。
 有名なところではハンガリアン表記の是非がありますが、その他にも省略名の是非や大文字小文字問題、メソッドは動詞でプロパティは名詞、動詞は先頭か(GetData)末尾か(DataGet)、日本語の可否、ブロックコードの是非、変数名の文字数など、枚挙にいとまがありません。
 保守を考えるとたとえ現在正常に動くロジックでも名前がいまひとつなら変えさせたいが、これは相当な抵抗が出ます。そして味方はいないんだなあ。

 そして広島にも北広島はあるんだなあ。

 困ったもんです -_-;

# re: ネーミング規則 2008/07/28 1:43 Pasie.

>えーと…

気づきませんでした(笑
すげーなあ。コードレビュアーとは斯くあるべきか…
2^nの時もそうですが、脱帽であります。

# re: ネーミング規則 2008/07/28 1:45 れい

そうだ。
ネーミングで質問。
Ognacさんは「ストアード」と表記されますよね。
発音もそうなのでしょうか?
それはなぜでしょう?

元の英語だとStored Procedureですから
日本語で発音するなら
「ストアードプロシージャー」
が恐らく一番近いですよね。

それを「4音節に省略」してストアドだと思っていたのですが、
Ognacさんの表記の仕方だと「後半の省略」ですよね。

そういう業界があるのかしら?

# re: ネーミング規則 2008/07/28 1:46 れい

> 私はプログラミングとは名前付けだと思っている

よくわからないけど名言発見。

# re: ネーミング規則 2008/07/28 9:35 やじゅ

ストアードはストアドと表記しているのが多い
ですね。

# re: ネーミング規則 2008/07/28 9:36 やじゅ

ぺとベの違いは今回は大きいですね。

# re: ネーミング規則 2008/07/28 10:02 れい

へぺべ
ヘベペ

カタカナとひらがなの違いのテスト

へ へ
の の
 も
 へ

べ べ
め め
 く
 し

全角空白がつぶれるかどうかのテスト

# re: ネーミング規則 2008/07/28 10:10 Ognac

>かな入力固有の恥ずかしい間違いが。
へへへ..wwww....orz..^^)

>もちろん、「別物」ですよ。
イタリア語のVenetiaをラテン読みするか英語読みするかの差だと思ってましたが、別物ですか?

名前は「get_xxx, do_xxxなど動詞+名詞で、どちらの視点から見みたネーミングにする」と明確な指針を出しても、ばらばらな名前で仕上がってくるのは、どうしてでしょう。個々人の言語感覚か国語力か、難しいものです。

>コードレビュアーとは斯くあるべきか…
関心も得心もします。煙たがられるコードレビュアーでも、いて欲しい存在です。

>Ognacさんは「ストアード」と表記されますよね。
>それはなぜでしょう?
これはおそらく、メーカー文化と思います。とくにIBM文化の影響を受けて、脱皮しきれていない人が私も含めています。
IBMのRDBにDB2 があり、汎用機に搭載されたころ、研修等で「ストアード」呼称を連打されました。
ググってみるといまでもDB2関連では残っているようです。

・該当URLでは SPAM Checkで投稿できないようですので、引用します。


DB2 UDB for iSeries SQL プログラミング 概念 V5R1
ストアード・プロシージャー
ストアード・プロシージャーとは、SQL CALL ステートメントを使用して呼び出すことができるプログラムのことです。DB2 UDB for iSeries は、外部ストアード・プロシージャーおよび SQL プロシージャーをサポートします。外部ストアード・プロシージャーは、どのシステム・プログラムまたは REXX プロシージャーであっても構いません。ただし、システム/36 のプログラムまたはプロシージャー、あるいは、サービス・プログラムであってはなりません。SQL プロシージャーは、全体が SQL で定義され、(SQL 制御ステートメントを含む) SQL ステートメントを含めることができます。ストアード・プロシージャーについて詳しくは、本書の「ストアード・プロシージャー」を参照してください。


キーボードのことを「鍵盤装置」と称したり。フロッピーディスクドライブが3.5型駆動機構、ハードディスクドライブがハードディスク駆動機構など、
強引に邦名に置換する文化があり、トラウマ的に頭に入ってます。
参考:
http://www.amy.hi-ho.ne.jp/~lepton/program/prog/prog91.html


・お騒がせしまして、恐縮です。゛゜の区別は、付きにくいものですね。改めて実感

# re: ネーミング規則 2008/07/28 12:48 れい

> イタリア語のVenetiaをラテン読みするか英語読みするかの差だと思ってましたが、別物ですか?

VxxxxとPxxxxでは別物です、というだけの話です。

> 煙たがられるコードレビュアー
すみません…。

> DB2関連では残っているようです。
ほぉ。
DB2界隈ではストアードなのですね。
#私にはちょっと言いにくいです。

# re: ネーミング規則 2008/07/28 13:15 biac

前振りにつっこみ f(^^;

ソースコードリポジトリーをホテル、 ソースコードを泊り客にたとえます。 すると、 ソースコードがリポジトリに入るのはチェックインで、 出てくるのはチェックアウト。
これで割と覚えてもらえる f(^^;

# 先週の MSKK のお達しに従って 「リポジトリー」w

# re: ネーミング規則 2008/07/28 18:51 Ognac

>ソースコードリポジトリーをホテル、 ソースコードを泊り客にたとえます。
解りやすい!
「自分の所にデータをもってくるからCheckInであって、CheckOutはおかしい」と言われました。うーん。視点の説明って難しいです。

># 先週の MSKK のお達しに従って 「リポジトリー」
「ー」で終わるのは、不細工ですっていう文化は、どこが作ったのかなぁ。それより、音引きが引き起こす不具合を解消して欲しいものです。

# re: ネーミング規則 2008/07/28 21:49 RUN

>聖書などによくでてくるペテロは peterのことだし
人名に対して違和感ってどうなんでしょうね。

例えば、某ナイトライダーで有名な
【マイケル】と言う名前は
英語だとマイケル、仏語でミッシェル、西語でミゲール、
独語でミヒャエル、露語でミハイル、希語でミカエル
だったりしますが、
だからと言ってミッシェル・ジャクソンとかマイケル・エンデ
とかっていいませんよね。
むしろ、所属国と別の読みをした方が違和感があると思います。
聖書は基本、希語なのでペテロに成るのは普通かと思います。

# re: ネーミング規則 2008/07/28 22:56 Pasie.

そういえば。

>極東(far East)です。これを直訳しただけなんですが、日本視点の用語になってません。

これですが、日本視点でもOKです。かつては私も"辺境"って意味合いで捉えてていい気がしませんでしたが、よく考えてみると、日本は"日本"ですから
>> 日出る処の天子,書を,日没する処の天子に致す。恙なきや。
なんで、東にあって当然なんですよ。ええ ^_^
Viva! "+"0900(JST) #ぉぃ

# re: ネーミング規則 2008/07/28 23:18 Pasie.

>むしろ、所属国と別の読みをした方が違和感があると思います。

 とはいえ、毛沢東をマオツェトンってのは違和感が…
漢字名は音読みで勘弁して欲しいところです。>朝鮮とかも含む

 あとTritonがトライトンってのも勘弁してって感じですが、キリストとかカエサルとかはどーしたもんかって感じはあります。

 ニッポン/ニホン/ハポン/ヤーパン/ジャパン/リーベン、みんな読み方の相違で、語源は"日本"または"にっぽん"なんですよね。これについては、いいんじゃないの好きに呼べばって感じです。
 ただ「正式にはどれが正しいんだ(特に「にっぽん」と「にほん」)と言われると、お札か切手を見ろ!ってことにしています。 -_-;

# re: ネーミング規則 2008/07/29 1:22 Ognac

>なんで、東にあって当然なんですよ。ええ ^_^
解釈の視点を変えるわけですね。  そのように解釈すれば、納得!!!.... 違う気もしますがマいいか。

>人名に対して違和感ってどうなんでしょうね。
>漢字名は音読みで勘弁して欲しいところです。>朝鮮とかも含む
こちらは、見解の分かれるところですね、放送局では相互呼称協定が存在していて、自国語で読むか現地読みするか、を協定し、それに従うというのがあります。対中国では自国語読みで、米国や韓国は現地読み、になっているそうです。
正解というのは存在しないので、認識の仕方に依存するのでしょうね。
 発音でなく、スペルに従うのが波風たたなくて良いと思って、
>ペトロでなくPeter
と書いたのですが、違和感を与えた様です。固有名詞の扱いは難しいものです。
・固有名詞はIDの意味が成立すればよくて読み方はどうでもいい...と言う人と
・固有名詞は個人を表すので間違うのは失礼だ...................と言う人に分かれます。
トレードオフの関係みたいで、困ることがあります。可能な限り相手にあわせますが、相手がこの二種類居るとお手上げです。下駄を預けて、判定待ちに持ち込みます....wwww

原則は現地読みなんでしようが、現地読みが想像できないのでこまります。日本語読み、ローマ字読みになるのは仕方ないのか...となると ペトロが正解でピーターはバツになるのかなぁ.....混乱してます。

国内でも東京文化と大阪文化で読み方が異なります。谷という字は、東京文化圏では「ヤ」と読み、大阪文化圏では「タニ」と読みます。 中谷さんは「なかたにさん」であり「なかやさん」でもあります。
ふりがながないときは、大阪では「なかたにさん」がデフォルトです。東京では「なかやさん」でしょう。
本人にしてみれば、どちらかが本当でどちらかが嘘になります。しかし本人が読み方をアピールしないと、両地区の人は、デフォルト読みが正しいと思うでしょう。
 固有名詞の扱いは難しい。 本文で固有名詞を例に出したのが間違いでした.ww!

# re: ネーミング規則 2008/07/29 8:28 Pasie.

> 相互呼称協定

 へえ。そうなんですか。知りませんでした。(なんとなくは気づいていたけど)
 しかし誰に断ってそんな勝手なことを(笑

 別に朝鮮系が現地音でもいいんですよ。だったらカタカナで書いてくださいよ。漢字を表記してそれを読ませようとするのは勘弁してくださいって感じです。同じことをアラビア語圏の人が主張したら、同じくルビなしでアラビア文字だけで出版物にするんですか?と小一時間問い詰めたい…

 なんかこのあたりは差別的な何かが潜んでいそうな気がするので単純にはいかないのでしょうが。

# Hi there to all, because I am genuinely keen of reading this webpage's post to be updated on a regular basis. It includes fastidious information. 2021/08/30 4:10 Hi there to all, because I am genuinely keen of re

Hi there to all, because I am genuinely keen of reading
this webpage's post to be updated on a regular basis.
It includes fastidious information.

# Hi! I know this is somewhat off-topic however I needed to ask. Does managing a well-established blog such as yours require a massive amount work? I am brand new to blogging however I do write in my journal on a daily basis. I'd like to start a blog so I 2021/09/02 7:16 Hi! I know this is somewhat off-topic however I ne

Hi! I know this is somewhat off-topic however I needed to ask.
Does managing a well-established blog such as yours require a massive
amount work? I am brand new to blogging however I do write in my journal on a daily
basis. I'd like to start a blog so I can share my personal experience and views online.
Please let me know if you have any ideas or tips for new aspiring
bloggers. Appreciate it!

# Hi! I know this is somewhat off-topic however I needed to ask. Does managing a well-established blog such as yours require a massive amount work? I am brand new to blogging however I do write in my journal on a daily basis. I'd like to start a blog so I 2021/09/02 7:17 Hi! I know this is somewhat off-topic however I ne

Hi! I know this is somewhat off-topic however I needed to ask.
Does managing a well-established blog such as yours require a massive
amount work? I am brand new to blogging however I do write in my journal on a daily
basis. I'd like to start a blog so I can share my personal experience and views online.
Please let me know if you have any ideas or tips for new aspiring
bloggers. Appreciate it!

# Hi! I know this is somewhat off-topic however I needed to ask. Does managing a well-established blog such as yours require a massive amount work? I am brand new to blogging however I do write in my journal on a daily basis. I'd like to start a blog so I 2021/09/02 7:18 Hi! I know this is somewhat off-topic however I ne

Hi! I know this is somewhat off-topic however I needed to ask.
Does managing a well-established blog such as yours require a massive
amount work? I am brand new to blogging however I do write in my journal on a daily
basis. I'd like to start a blog so I can share my personal experience and views online.
Please let me know if you have any ideas or tips for new aspiring
bloggers. Appreciate it!

# Hi! I know this is somewhat off-topic however I needed to ask. Does managing a well-established blog such as yours require a massive amount work? I am brand new to blogging however I do write in my journal on a daily basis. I'd like to start a blog so I 2021/09/02 7:19 Hi! I know this is somewhat off-topic however I ne

Hi! I know this is somewhat off-topic however I needed to ask.
Does managing a well-established blog such as yours require a massive
amount work? I am brand new to blogging however I do write in my journal on a daily
basis. I'd like to start a blog so I can share my personal experience and views online.
Please let me know if you have any ideas or tips for new aspiring
bloggers. Appreciate it!

# I every time used to read article in news papers but now as I am a user of internet therefore from now I am using net for posts, thanks to web. 2021/09/03 1:40 I every time used to read article in news papers b

I every time used to read article in news papers
but now as I am a user of internet therefore from now I am using net for posts, thanks to web.

# I every time used to read article in news papers but now as I am a user of internet therefore from now I am using net for posts, thanks to web. 2021/09/03 1:41 I every time used to read article in news papers b

I every time used to read article in news papers
but now as I am a user of internet therefore from now I am using net for posts, thanks to web.

# I every time used to read article in news papers but now as I am a user of internet therefore from now I am using net for posts, thanks to web. 2021/09/03 1:42 I every time used to read article in news papers b

I every time used to read article in news papers
but now as I am a user of internet therefore from now I am using net for posts, thanks to web.

# Good day! I could have sworn I've visited this web site before but after going through some of the posts I realized it's new to me. Nonetheless, I'm definitely delighted I found it and I'll be bookmarking it and checking back regularly! 2021/09/03 3:50 Good day! I could have sworn I've visited this web

Good day! I could have sworn I've visited this web site before but after going through some of the posts I
realized it's new to me. Nonetheless, I'm definitely
delighted I found it and I'll be bookmarking it and checking back regularly!

# Good day! I could have sworn I've visited this web site before but after going through some of the posts I realized it's new to me. Nonetheless, I'm definitely delighted I found it and I'll be bookmarking it and checking back regularly! 2021/09/03 3:51 Good day! I could have sworn I've visited this web

Good day! I could have sworn I've visited this web site before but after going through some of the posts I
realized it's new to me. Nonetheless, I'm definitely
delighted I found it and I'll be bookmarking it and checking back regularly!

# Good day! I could have sworn I've visited this web site before but after going through some of the posts I realized it's new to me. Nonetheless, I'm definitely delighted I found it and I'll be bookmarking it and checking back regularly! 2021/09/03 3:52 Good day! I could have sworn I've visited this web

Good day! I could have sworn I've visited this web site before but after going through some of the posts I
realized it's new to me. Nonetheless, I'm definitely
delighted I found it and I'll be bookmarking it and checking back regularly!

# Good day! I could have sworn I've visited this web site before but after going through some of the posts I realized it's new to me. Nonetheless, I'm definitely delighted I found it and I'll be bookmarking it and checking back regularly! 2021/09/03 3:53 Good day! I could have sworn I've visited this web

Good day! I could have sworn I've visited this web site before but after going through some of the posts I
realized it's new to me. Nonetheless, I'm definitely
delighted I found it and I'll be bookmarking it and checking back regularly!

# Howdy! I simply wish to offer you a big thumbs up for the great information you have got here on this post. I am returning to your website for more soon. 2021/09/05 16:07 Howdy! I simply wish to offer you a big thumbs up

Howdy! I simply wish to offer you a big thumbs up for the great information you
have got here on this post. I am returning to your website for more soon.

# Howdy! I simply wish to offer you a big thumbs up for the great information you have got here on this post. I am returning to your website for more soon. 2021/09/05 16:08 Howdy! I simply wish to offer you a big thumbs up

Howdy! I simply wish to offer you a big thumbs up for the great information you
have got here on this post. I am returning to your website for more soon.

# Howdy! I simply wish to offer you a big thumbs up for the great information you have got here on this post. I am returning to your website for more soon. 2021/09/05 16:09 Howdy! I simply wish to offer you a big thumbs up

Howdy! I simply wish to offer you a big thumbs up for the great information you
have got here on this post. I am returning to your website for more soon.

# Howdy! I simply wish to offer you a big thumbs up for the great information you have got here on this post. I am returning to your website for more soon. 2021/09/05 16:10 Howdy! I simply wish to offer you a big thumbs up

Howdy! I simply wish to offer you a big thumbs up for the great information you
have got here on this post. I am returning to your website for more soon.

# Very good article. I will be facing some of these issues as well.. quest bars http://bit.ly/3C2tkMR quest bars 2021/09/10 22:32 Very good article. I will be facing some of these

Very good article. I will be facing some of these issues as well..
quest bars http://bit.ly/3C2tkMR quest bars

# I read this article fully on the topic of the difference of most recent and previous technologies, it's remarkable article. scoliosis surgery https://coub.com/stories/962966-scoliosis-surgery scoliosis surgery 2021/09/13 11:23 I read this article fully on the topic of the diff

I read this article fully on the topic of the difference of most recent
and previous technologies, it's remarkable article.
scoliosis surgery https://coub.com/stories/962966-scoliosis-surgery scoliosis surgery

# For most up-to-date information you have to pay a quick visit internet and on the web I found this site as a most excellent web site for most up-to-date updates. quest bars https://www.iherb.com/search?kw=quest%20bars quest bars 2021/09/14 3:24 For most up-to-date information you have to pay a

For most up-to-date information you have to pay a quick visit internet and on the
web I found this site as a most excellent web site for most up-to-date
updates. quest bars https://www.iherb.com/search?kw=quest%20bars quest bars

# For most up-to-date information you have to pay a quick visit internet and on the web I found this site as a most excellent web site for most up-to-date updates. quest bars https://www.iherb.com/search?kw=quest%20bars quest bars 2021/09/14 3:25 For most up-to-date information you have to pay a

For most up-to-date information you have to pay a quick visit internet and on the
web I found this site as a most excellent web site for most up-to-date
updates. quest bars https://www.iherb.com/search?kw=quest%20bars quest bars

# For most up-to-date information you have to pay a quick visit internet and on the web I found this site as a most excellent web site for most up-to-date updates. quest bars https://www.iherb.com/search?kw=quest%20bars quest bars 2021/09/14 3:26 For most up-to-date information you have to pay a

For most up-to-date information you have to pay a quick visit internet and on the
web I found this site as a most excellent web site for most up-to-date
updates. quest bars https://www.iherb.com/search?kw=quest%20bars quest bars

# For most up-to-date information you have to pay a quick visit internet and on the web I found this site as a most excellent web site for most up-to-date updates. quest bars https://www.iherb.com/search?kw=quest%20bars quest bars 2021/09/14 3:27 For most up-to-date information you have to pay a

For most up-to-date information you have to pay a quick visit internet and on the
web I found this site as a most excellent web site for most up-to-date
updates. quest bars https://www.iherb.com/search?kw=quest%20bars quest bars

タイトル
名前
Url
コメント