Results 1 to 7 of 7
  1. #1
    Lou_Reed is offline VIP
    Windows 7 64bit Access 2010 64bit
    Join Date
    Mar 2015
    Posts
    1,664

    Meaning of Prefixes

    In the file that I have attached to this post, I have a few what I think are simple straightforward questions.



    They use terms like tblHelpDeskTickets.lngTicketID. I am not sure what the lng prefix is all about.
    It does define a new column in the tblHelpDeskTickets so maybe that explains it. Is there some kind of naming convention that I am missing here?

    They also use tblHelpDeskTickets.ysnTicketAssigned. this one is much for difficult. There is no column in the tbl.HelpDeskTickets named
    ysnTicketAsigned. If there is then I have not seen it. Yet from the syntax of the strSQL statement, it appears that to be a category of the
    tbl.HelpDeskTickets. Again, is there some kind of naming convention that I am missing here?

    That last one is truly confusing. I think I know what the tblHelpDeskTickets.lngTicketID is all about; but I do not have a clue what the tblHelpDeskTickets.ysnTicketAssigned
    is about. Yet it is used in the strSQL update statement.


    Also what does SET tblHelpDeskTickets.ysnTicketAssigned = -1 mean?


    It seems confusing at least to me.


    Any help appreciated. Thanks in advance.


    Respectfully,


    Lou Reed
    Attached Files Attached Files

  2. #2
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows 10 Access 2013 32bit
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,922
    Here's a link to one of the naming conventions: http://www.xoc.net/standards/rvbanc.asp#DAO

  3. #3
    John_G is offline VIP
    Windows 7 32bit Access 2010 32bit
    Join Date
    Oct 2011
    Location
    Ottawa, ON (area)
    Posts
    2,615
    If you open the table tblHelpDeskTickets in design view, you will see there are fields called lngTicketID and ysnTicketAssigned. In the naming convention the table designer has used, the first three characters of the field name indicate the data type of the field. lng is Numeric - Long, and ysn is Yes/No.

    When you see something like tblHelpDeskTickets.ysnTicketAssigned in SQL, it is using tablename.fieldname (or queryname.fieldname) notation. Much of the time tablename or queryname is not needed (i.e. where there is only one table in the query), but MS Access always uses it in the SQL generated by query designer.

  4. #4
    Lou_Reed is offline VIP
    Windows 7 64bit Access 2010 64bit
    Join Date
    Mar 2015
    Posts
    1,664
    Thanks for your input that clears some things up. Much appreciated.

    I do have two questions though on the operation of this form.

    1.When the ticket is assigned and the email sent, the Ticket Assigned yes/no checkbox gets a check in it.

    This occurs on the CurrentDb Execute strSQL, dbFailOnError
    line?

    2. Then the task is completed and the user can now close the form.

    However, when the form is reopened the TicketAssigned yes/no checkbox is still checked.

    I believe that is wrong. Opening the form now the checkbox should be unchecked.

    We are starting anew and this checkbox with a check in it is just a holdover from a previous task.

    Is this correct?

    Respectfully,

    Lou reed
    Last edited by Lou_Reed; 03-23-2017 at 11:39 AM. Reason: correction

  5. #5
    John_G is offline VIP
    Windows 7 32bit Access 2010 32bit
    Join Date
    Oct 2011
    Location
    Ottawa, ON (area)
    Posts
    2,615
    However, when the form is reopened the TicketAssigned yes/no checkbox is still checked.
    Yes, because the checkbox is bound to the field ysnTicketAssigned in the tblHelpDeskTickets table, and it displays whatever value it had when the record was last saved.

    Is this correct?
    Whether it is right or wrong has nothing to do with MS Access. Determining when the checkbox gets checked or unchecked is a decision that is made by the application developer, and the "business rules" that are being followed.

  6. #6
    Micron is online now Virtually Inert Person
    Windows 7 32bit Access 2007
    Join Date
    Jun 2014
    Location
    Ontario, Canada
    Posts
    12,737
    Or, if it is a new record, the table has a default setting of True/Yes on that field?
    The more we hear silence, the more we begin to think about our value in this universe.
    Paraphrase of Professor Brian Cox.

  7. #7
    orange's Avatar
    orange is online now Moderator
    Windows 10 Access 2010 32bit
    Join Date
    Sep 2009
    Location
    Ottawa, Ontario, Canada; West Palm Beach FL
    Posts
    16,716

Please reply to this thread with any new information or opinions.

Similar Threads

  1. rs.EOF Meaning
    By jo15765 in forum Modules
    Replies: 2
    Last Post: 03-18-2015, 06:34 PM
  2. Where to put Name prefixes
    By Malavia in forum Access
    Replies: 2
    Last Post: 06-10-2013, 02:00 PM
  3. ID Autogeneration with Prefixes
    By Britty in forum Programming
    Replies: 1
    Last Post: 04-05-2012, 10:49 AM
  4. Autonumber Prefixes into a Query
    By Osiris in forum Queries
    Replies: 4
    Last Post: 06-22-2011, 06:58 AM
  5. What is the meaning of this query?
    By doci4a in forum Queries
    Replies: 2
    Last Post: 03-15-2011, 07:11 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums