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 6021835
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T03:46:15+00:00 2026-05-23T03:46:15+00:00

I’ve read in forums about people having issues with certain data types when accessing

  • 0

I’ve read in forums about people having issues with certain data types when accessing a database from their website and windows forms application. Mostly the decimal, float and datetime data types.

My DB Table, for example, the Orders table consists of the following Columns. Below each column is the datatype I have chosen to use:

UserId     OrderId     OrderDate     InvoiceTotal      PaymentStatus     DeliveryStatus
int        int         datetime      money             bit               bit

My questions are:

  1. Is (in Windows Forms) DateTime.Now() equivelant to datetime (in WebMatrix DB)? If not, why not? And which method would be best to work with the datetime datatype used in WebMatrix DB?

  2. money Data Type: As far as I know, there is no “money” data type in Windows Forms. You can only use Decimal (which makes sense), but I’ve heard of people also using Float? So, which data type should I use in WinForms so that it just works properly with the money datatype in the DB, and how?

I’m asking these questions because in the past I’ve always had precision problems. Sometimes even inaccuracy problems. I’ve read the docs. Tutorials. Articles, etc. But I feel like I’m missing something…

  • 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-23T03:46:16+00:00Added an answer on May 23, 2026 at 3:46 am

    Firstly, better clear up some confusion:

    1. Windows Forms is a technology built on top of the .NET Framework. When you describe DateTime.Now, you’re discussing types from the base class library, not Windows Forms.

    2. WebMatrix DB, is in fact, Sql Server Compact.

    You might not of come across answers through search if you’re making the mistake of confusing tools with the framework itself.

    If you need a way to compare .NET data types with Sql data types, it’s worth looking at the MSDN Library Page which discusses this very thing.

    For your specific questions:

    1. DateTime can be used with datetime in most scenarios, however Sql Server cannot deal with exceptional date ranges (e.g. < 01/01/1753). I can’t imagine many scenarios you would need to go less than that, but it’s worth a note.

    2. You’re right, there is no money data type in the base class library, the compatible .NET data type is Decimal. Decimal is a fixed-precision data type which means that all values can be represented and stored with a range, whereas Float is an approximate-number data type, and could be prone precision issues.

    There are arguments for using both, for both accuracy and performance reasons, it depends what your application is design to do.

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

Sidebar

Related Questions

public static bool CheckLogin(string Username, string Password, bool AutoLogin) { bool LoginSuccessful; // Trim
I need to clean up various Word 'smart' characters in user input, including but
We are using XSLT to translate a RIXML file to XML. Our RIXML contains
i want to parse a xhtml file and display in UITableView. what is 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.