# Accounting package model naming

**URL:** <https://www.ruby-forum.com/t/accounting-package-model-naming/72867>\
**Category:** Rails\
**Created:** [October 19, 2006, 3:12pm UTC](https://www.ruby-forum.com/t/accounting-package-model-naming/72867 "2006-10-19T15:12:41Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![fbeausoleil](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/f/ec9cab/32.png) [@fbeausoleil](https://www.ruby-forum.com/u/fbeausoleil)\
**Post date:** [October 19, 2006, 3:12pm UTC](https://www.ruby-forum.com/t/accounting-package-model-naming/72867/1 "2006-10-19T15:12:41Z")

</div>

Hello everyone,

I’m a native French speaker, and I’m struggling with some model names.  
I’m working on the accounting package for an app. I have Accounts  
and TransactionRecords, and now I must relate accounts with  
transactions. What should the model between be named ?

I thought of AffectedAccount, RecordMember, TransactionMember, but  
none of these feels very satisfactory. Even in French I’m not sure  
how I would name these objects…

So, if anybody found a good solution, I’d be interested in hearing it.

## Thanks !

FranÃ§ois Beausoleil  
[http://blog.teksol.info/](http://blog.teksol.info/)  
[http://piston.rubyforge.org/](http://piston.rubyforge.org/)

---

<div class="post-metadata">

**Author:** ![fbeausoleil](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/f/ec9cab/32.png) [@fbeausoleil](https://www.ruby-forum.com/u/fbeausoleil)\
**Post date:** [October 19, 2006, 3:30pm UTC](https://www.ruby-forum.com/t/accounting-package-model-naming/72867/2 "2006-10-19T15:30:47Z")

</div>

Hi Francois,

Francois B. wrote:

> I’m working on the accounting package for an app.  
> I have Accounts and TransactionRecords, and now  
> I must relate accounts with transactions. What  
> should the model between be named ?

I’m not completely sure I understand your question, but perhaps this  
will  
help.

If you are asking about naming the models for your tables…

Models in Rails are, by convention, named the singular version of the  
name  
of the table on which they are based. The model for your Accounts table  
should be named Account. The model for TransactionRecords should be  
named  
TransactionRecord.

If you are asking about naming a model that relates ‘accounts with  
transactions’, without more information I’m not sure why you would want  
a  
seperate model for this. It seems like a simple has\_namy / belongs\_to  
relationship would work. If not, please say more.

Sorry I couldn’t be more help.

Best regards,  
Bill

---

<div class="post-metadata">

**Author:** ![fbeausoleil](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/f/ec9cab/32.png) [@fbeausoleil](https://www.ruby-forum.com/u/fbeausoleil)\
**Post date:** [October 19, 2006, 5:14pm UTC](https://www.ruby-forum.com/t/accounting-package-model-naming/72867/3 "2006-10-19T17:14:37Z")

</div>

On Oct 19, 2006, at 6:08 AM, Francois B. wrote:

> I’m a native French speaker, and I’m struggling with some model names.  
> I’m working on the accounting package for an app. I have Accounts  
> and TransactionRecords, and now I must relate accounts with  
> transactions. What should the model between be named ?
> 
> I thought of AffectedAccount, RecordMember, TransactionMember, but  
> none of these feels very satisfactory. Even in French I’m not sure  
> how I would name these objects…

I would think:

Accounts-\>TransactionRecords-\>Ledgers

–  
– Tom M., CTO  
– Engine Y., Ruby on Rails Hosting  
– Reliability, Ease of Use, Scalability  
– (866) 518-YARD (9273)

---

<div class="post-metadata">

**Author:** ![fbeausoleil](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/f/ec9cab/32.png) [@fbeausoleil](https://www.ruby-forum.com/u/fbeausoleil)\
**Post date:** [October 19, 2006, 10:31pm UTC](https://www.ruby-forum.com/t/accounting-package-model-naming/72867/4 "2006-10-19T22:31:20Z")

</div>

Hello Tom,

2006/10/19, Tom M. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid):

> Accounts-\>TransactionRecords-\>Ledgers

Ah! Bingo, exactly what I wanted.

## Thanks !

FranÃ§ois Beausoleil  
[http://blog.teksol.info/](http://blog.teksol.info/)  
[http://piston.rubyforge.org/](http://piston.rubyforge.org/)

---

<div class="post-metadata">

**Author:** ![fbeausoleil](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/f/ec9cab/32.png) [@fbeausoleil](https://www.ruby-forum.com/u/fbeausoleil)\
**Post date:** [October 20, 2006, 12:49pm UTC](https://www.ruby-forum.com/t/accounting-package-model-naming/72867/5 "2006-10-20T12:49:02Z")

</div>

Perhaps not very useful in this case but I find looking up a thesaurus  
to be  
very useful in coming up with good model names sometimes.

Hammed

---

<div class="post-metadata">

**Author:** ![fbeausoleil](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/f/ec9cab/32.png) [@fbeausoleil](https://www.ruby-forum.com/u/fbeausoleil)\
**Post date:** [October 20, 2006, 11:48am UTC](https://www.ruby-forum.com/t/accounting-package-model-naming/72867/6 "2006-10-20T11:48:03Z")

</div>

On 10/19/06, Tom M. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> > how I would name these objects…
> 
> I would think:
> 
> Accounts-\>TransactionRecords-\>Ledgers

Sounds pretty similar to what we’re doing here (though our naming is a  
bit off, we inherited some made-up-english terms), but could you  
elaborate on what each table contains?

Accounts is straight forward enough. But, if someone else store the  
accounts for different entities (we call them ‘clients’) in one db,  
I’d love to see how you tie accounts to reporting.

I’m not sure about TxRecord vs. Ledger, though.

Isak
