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

  • Home
  • SEARCH
  • 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 6574221
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T15:14:04+00:00 2026-05-25T15:14:04+00:00

I want to store version in database table and don’t want to use varchar(max)

  • 0

I want to store version in database table and don’t want to use varchar(max) for that. I want something fixed varchar(xxx)

Could you please tell, what’s the maximum possible length of FileVersionInfo.FileVersion on Windows Platforms?

Actually figured out how to get proper version:

var ver = FileVersionInfo.GetVersionInfo("D:\\oraociei11.dll").FileVersion;

This returns for Oracle lib:

OraOCIEI11.dll - 11.2.0.1.0 Production
oracore11.dll - 11.2.0.1.0 Production
oranls11.dll - 11.1.0.6.0 Production
orasnls11.dll - 11.1.0.6.0 Production
oraunls11.dll - 11.1.0.6.0 Production
oravsn11.dll - 11.2.0.2.0 Production
oracommon11.dll - 11.2.0.2.0 Production
orageneric11.dll - 11.2.0.2.0 Production
oraclient11.dll - 11.2.0.2.0 Production
orapls11.dll - 11.1.0.6.0 Production
orasql11.dll - 11.1.0.6.0 Production
oraxml11.dll - 11.1.0.6.0 Production
orahasgen11.dll - 11.2.0.1.0 Production
oraocrutl11.dll - 11.2.0.1.0 Production
oraocr11.dll - 11.2.0.1.0 Production
oraocrb11.dll - 11.2.0.1.0 Production
oranbeq11.dll - 11.2.0.2.0 Production
orantcp11.dll - 11.2.0.2.0 Production
orantcps11.dll - 11.2.0.2.0 Production
orannmp11.dll - 11.2.0.2.0 Production
orancds11.dll - 11.2.0.2.0 Production
oranldap11.dll - 11.2.0.2.0 Production
oraldapclnt11.dll - 10.1.4.0.1 Production
oraolapapi11.dll - 
oranhost11.dll - 11.2.0.2.0 Production
orantns11.dll - 11.2.0.2.0 Production
oranoname11.dll - 
oransgr11.dll - 11.2.0.2.0 Production
orancrypt11.dll - 11.2.0.2.0 Production
oransgr11.dll - 11.2.0.2.0 Production
oranl11.dll - 11.2.0.2.0 Production
oranro11.dll - 11.2.0.2.0 Production
oranbeq11.dll - 11.2.0.2.0 Production
orantcps11.dll - 11.2.0.2.0 Production
orannmp11.dll - 11.2.0.2.0 Production
orancds11.dll - 11.2.0.2.0 Production
oranldap11.dll - 11.2.0.2.0 Production
oraldapclnt11.dll - 10.1.4.0.1 Production
orannzsbb11.dll - 11.0.0.1.0 Production
oran11.dll - 11.2.0.2.0 Production
orannzmcs11.dll - 11.0.0.1.0 Production
oranjssl11.dll - 11.2.0.2.0 Production
oranjni11.dll - 11.2.0.2.0 Production
oranipc11.dll - 11.2.0.2.0 Production

To get version of file in proper way:

var versionInfo = FileVersionInfo.GetVersionInfo("D:\\oraociei11.dll");
var properVersion = string.Format("{0}.{1}.{2}.{3}", versionInfo.FileMajorPart, versionInfo.FileMinorPart, versionInfo.FileBuildPart, versionInfo.FilePrivatePart);

Thanks guys for participating!

  • 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-05-25T15:14:04+00:00Added an answer on May 25, 2026 at 3:14 pm

    No, FileVersion is a string and can contain anything. The Visual Studio resource editor allows entering a string of up to 300 characters. That is however not enforced by the resource compiler, longer strings can be entered by editing the .rc file by hand.

    What you’ll want to do is synthesize the version string yourself, like this:

            var info = System.Diagnostics.FileVersionInfo.GetVersionInfo(path);
            var version = string.Format("{0}.{1}.{2}.{3}", 
                info.FileMajorPart, info.FileMinorPart, info.FileBuildPart, info.FilePrivatePart);
    

    Which then ensures this string can never be larger than 23 characters.

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

Sidebar

Related Questions

I want to store some hashes of some strings in my Database table. For
I want to store a large number of sound files in a database, but
I want to store a large result set from database in memory. Every record
I see wordpress database on wp_posts table, there are 2 columns to store post
I want to store a blog post in a database. I thought it would
I have a stored procedure written in T-SQL and want to use a table
I am having problems trying to use a different MySQL database engine. (I want
I want to store an HTML code in an SQL database. It stores everything
I am a new developer on Android and I want store user data in
I want to store the current URL in a session variable to reference the

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.