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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 11, 20262026-05-11T22:11:05+00:00 2026-05-11T22:11:05+00:00

I am wraping some SQL Stored Procs with in/out parameters. This of course means

  • 0

I am wraping some SQL Stored Procs with in/out parameters. This of course means I have to do ugly stuff like declare my parameters as by reference and use mutables.

How would I do this in F#?

  • 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-11T22:11:06+00:00Added an answer on May 11, 2026 at 10:11 pm

    F# does indeed have a byref parameter. Here’s an example from the MSDN page:

    type Incrementor(z) =
        member this.Increment(i : int byref) =
           i <- i + z
    

    Mutable variables also exist (though there’s an important difference between using ref and mutable variables, either of which can be used for many of the same purposes). The MSDN page on this subject is very informative – including a discussion of when to use which keyword/construct.

    Example of reference variables:

    // Declare a reference.
    let refVar = ref 6
    
    // Change the value referred to by the reference.
    refVar := 50
    

    Example of mutable variables:

    // Declare a reference.
    let mutable refVar = 6
    
    // Change the value referred to by the reference.
    refVar <- 50
    

    As you can see, the syntax for assignment (as well as retrieval) differs between the two constructs, too.

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

Sidebar

Related Questions

I have discovered recently that's possible to call anoymous blocks from jdbc like this:
Our framework requires wrapping certain functions in some ugly boilerplate code: def prefix_myname_suffix(obj): def
This question is related to my question: SQL Server and TransactionScope (with MSDTC): Sporadically
I am wrapping some unmanaged C++ code inside a .NET project. For this I
I need some help wrapping my head around this. I am trying to develop
I am having some trouble wrapping my head around virtual proxies. I have read
I use some anonymous inner classes like foo(){ A a = new A(arg1){ //it
I have an object of objects, which I'd like to sort by property... having
I have a table where I wish to update some of the rows. All
Using Razor how/can you write straight text with out wrapping it in some type

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.