|
That output looks like the command works as expected. What were you expecting to see?
Your compiler supports C# 7.3, but defaults to 7.0. To turn on 7.3, you need to change the advanced build settings. Open the properties of your project, select the "Build" tab, click the "Advanced" button, and select the language version you want.
NB: For some bizarre reason, you need to change the version separately for each build configuration.
4 ways to enable the latest C# features - Meziantou's blog[^]
"These people looked deep within my soul and assigned me a number based on the order in which I joined."
- Homer
|
|
|
|
|
My point is that the instructions in the SO post, which version of C# am I using - Stack Overflow, which I forgot to cite, imply that it's in the general help message displayed when you pass the compiler "/?" to display the general help message. While that command yields lots of useful tidbits, you must amplify it a bit to get the list of supported C# language versions.
Nevertheless, your reply called to my attention something which I hadn't noticed, which is that the default version in my installation is 7.0, not 7.3, as at first appeared to be the case. Thanks for the additional tidbits about how to override that.
Of the four ways mentioned, the one that calls to me is the properties file, since that supports overriding all sorts of default values for every project. Though I haven't dug into the global property sheets for C#, I've made extensive changes to my C++ settings.
David A. Gray
Delivering Solutions for the Ages, One Problem at a Time
Interpreting the Fundamental Principle of Tabular Reporting
|
|
|
|
|
I never got that too, why not default to the latest stable release?
|
|
|
|
|
Nish Nishant wrote: why not default to the latest stable release? If it was that easy... everyone could do it
M.D.V.
If something has a solution... Why do we have to worry about?. If it has no solution... For what reason do we have to worry about?
Help me to understand what I'm saying, and I'll explain it better to you
Rating helpful answers is nice, but saying thanks can be even nicer.
|
|
|
|
|
That's exactly what I expected it to do. However, I can understand some motivation for setting it to the last whole version.
David A. Gray
Delivering Solutions for the Ages, One Problem at a Time
Interpreting the Fundamental Principle of Tabular Reporting
|
|
|
|
|
I think the idea is to avoid breaking previously-compiling code unless you ask it to.
(I haven't seen any C# 7.0 code that would be broken by the 7.3 compiler; but it's always best to CYA.)
"These people looked deep within my soul and assigned me a number based on the order in which I joined."
- Homer
|
|
|
|
|
Yeah, but Visual Studio 2017 defaults to 7.0 for new projects too.
|
|
|
|
|
I agree, it's annoying.
You can apparently override it by putting a magic file in a directory somewhere above your project:
Customize your build - Visual Studio | Microsoft Docs[^]
<Project>
<PropertyGroup>
<LangVersion>latest</LangVersion>
</PropertyGroup>
</Project>
But I don't like that solution. As soon as you share your project with someone who doesn't have the magic file, they'll start getting compiler errors for all the new features.
"These people looked deep within my soul and assigned me a number based on the order in which I joined."
- Homer
|
|
|
|
|
|
I created a datetime variable like so
LET vTEST = '2018-09-05 13:27:14.5';
Then, I tried various methods to strip the time component from the date. Here are the various techniques for doing this, along with their generated results:
DATE(MAKEDATE(YEAR($(vTEST)), MONTH($(vTEST)), DAY($(vTEST))), 'YYYY-MM-DD HH:MM:SS.FFF') = "2018-09-05 00:27:00.000"
DATE(FLOOR($vTEST)), 'YYYY-MM-DD HH:MM:SS.FFF') = "2018-09-05 00:27:00.000"
DATE(NUM(DATE(FLOOR($(vTEST)) 'YYYY-MM-DD HH:MM:SS.FFF') = "2018-09-05" <======== THIS is what I wanted
A Qlikview datetime is represented by a floating point number with the date on the integer side of the decimal point, and the time on the fractional side. I honestly thought the FLOOR function would do what I want, but it left the minutes untouched, which resulted in the variable still having a time component. The only way I could get the time completely stripped is illustrated in the last example.
Have I mentioned how much I hate working in Qlikview?
".45 ACP - because shooting twice is just silly" - JSOP, 2010 ----- You can never have too much ammo - unless you're swimming, or on fire. - JSOP, 2010 ----- When you pry the gun from my cold dead hands, be careful - the barrel will be very hot. - JSOP, 2013
|
|
|
|
|
Perl scripts?
Is regex possible with this Qlikview crap?
modified 7-Aug-18 10:42am.
|
|
|
|
|
John Simmons / outlaw programmer wrote: YYYY-MM-DD HH:MM:SS.FFF
Seriously? The format strings don't differentiate between "month" and "minute"? 💩
"These people looked deep within my soul and assigned me a number based on the order in which I joined."
- Homer
|
|
|
|
|
Perhaps it's context sensitive.
Everyone is born right handed. Only the strongest overcome it.
Fight for left-handed rights and hand equality.
|
|
|
|
|
I like positive thinking.
|
|
|
|
|
Perhaps the feature "common sense" was integrated. If it sees HH, then the next format will treat minutes regardless of the casing
|
|
|
|
|
John Simmons / outlaw programmer wrote: DATE(NUM(DATE(FLOOR($(vTEST)) 'YYYY-MM-DD HH:MM:SS.FFF')
In my geeky teens I would have thought, "oh wow, this is so cool, 4 levels of parens!" and shown it to all my friends (erm, wait, what friends???) who would have gone "wow, that IS cool!" (if I had any friends.)
Now in my geeky 50's I'm with you -- I look at that and think, wow, what BS is this?
Latest Article - A Concise Overview of Threads
Learning to code with python is like learning to swim with those little arm floaties. It gives you undeserved confidence and will eventually drown you. - DangerBunny
Artificial intelligence is the only remedy for natural stupidity. - CDP1802
|
|
|
|
|
Marc Clifton wrote: "oh wow, this is so cool, 4 levels of parens!"
And your geeky friends would have mocked you because there are 5 levels...
Sent from my Amstrad PC 1640
Bad command or file name. Bad, bad command! Sit! Stay! Staaaay...
AntiTwitter: @DalekDave is now a follower!
|
|
|
|
|
If he were counting parens, 4 would be the average between the left and right side.
edit: sorry, didn't see the post below which mentions this.
"Go forth into the source" - Neal Morse
|
|
|
|
|
qlik example DATE(NUM(DATE(FLOOR($(vTEST)) 'YYYY-MM-DD HH:MM:SS.FFF')
This is the necessary stage of declarative programming* that occurs right before AI takes over and writes all the code for us.
Yes, it's like SQL and yes I hate SQL also*.
<bumpersticker>Real Devs Hate SQL</bumpersticker>
|
|
|
|
|
I'm somewhere between my teens and 50's and two parens would've been fine for me
|
|
|
|
|
I wonder that any of these expressions returns something, since none of them has balanced parentheses.
On the other hand, I have never heard of "Qlikview" (fortunately), and perhaps this "language" can't cope with balanced parentheses
|
|
|
|
|
Does this work for you?
SET DateFormat='YYYY-MM-DD';
LET vTEST = '2018-09-05 13:27:14.5';
dayname(vTEST)
|
|
|
|
|
This will give you the date portion of the string:
LET vTEST = '2018-09-05 13:27:14.5';
LET vResult = Date(vTEST, 'YYYY-MM-DD'); <-- vResult = 2018-09-05
Also, 'MM' for months, 'mm' for minutes.
Sincerely,
-Mark
|
|
|
|
|
I'm - among other things - making a software for the ATMs (for Bitcoins they're called BTMs). Yesterday we've found out that one of our machines has probably a defective touch screen. It was randomly pressing all over the screen. On closer inspection (on site) it turned out to be a branch of a tree randomly waving in the wind and occasionally touching the screen. This branch also managed in this short time to uncover two bugs that two testing teams were unable to find during two years of product lifetime. One was even as simply as touching the screen in a certain time. One was more complex, the branch managed to 'touch' through random screens and created very weird scenarios. One of them was a really obscure bug. The branch became a honorary member of our testing team.
In order to understand stack overflow, you must first understand stack overflow.
|
|
|
|
|
Welcome to fuzzing[^]
Software rusts. Simon Stephenson, ca 1994. So does this signature. me, 2012
|
|
|
|