Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8316867
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T21:27:18+00:00 2026-06-08T21:27:18+00:00

My question is why do a MySQL row’s integer values have an ‘L’ suffix?

  • 0

My question is why do a MySQL row’s integer values have an ‘L’ suffix? Here are the details:

The following dictionary — artificially formatted here for ease of display —

{'estimated': '', 
 'suffix': '', 
 'typeofread': 'g', 
  'acct_no': 901001000L, 
  'counter': 0, 
  'time_billed': datetime.datetime(2012, 5, 1, 9, 5, 33), 
  'date_read': datetime.datetime(2012, 3, 13, 23, 19, 45), 
  'reading': 3018L, 
  'meter_num': '26174200'}

is comprised of a MySQL database table’s columns zipped with the result of reading once from the table.

I can remove the ‘L’ by passing these values into int(), so if that dictionary were in a variable named snapped_read, I could do this:

int(snapped_read['reading']) and 3018L would change to 3018.

I’m just curious as to why integers show up this way.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-08T21:27:19+00:00Added an answer on June 8, 2026 at 9:27 pm

    Because in versions of Python before Python 3, long integer literals were indicated with an l or L suffix. In Python 3, ints and longs have been merged into just int, which functions pretty much like long used to.

    Do note that, technically, Python( 2)’s int was equivalent to C’s long, while Python’s long was more like a BigNumber-type thing with unlimited precision (which is now the case for Python 3’s int type.)

    http://docs.python.org/library/stdtypes.html#numeric-types-int-float-long-complex

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have 2 mysql tables : Question with the following columns : id, question,
Anyone could help me with a mysql Question? I have a row with a
I have a question about MySQL InnoDB. For example: I have the following table
This question here: MySQL: INSERT IGNORE or ON DUPLICATE KEY UPDATE with checking multiple
I have a short access/mySQL question. I have a mapping table on the format
I have a question about my mysql query. I want to count the number
The question I have is kind of simular to this one - MySQL select
I have the same tables as in this question: MySql query over many-to-many relationship
Here's a question for you mysql + python folks out there. Why does this
I have a somewhat complicated question related to MySQL. This is the table I

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.