I have a requirement to get the ID of a custom field in apex .  When we navigate to Setup-->Create-->Object--> Click on Object --> Click on field .In field detail page url we can find field Id  https://orgaddress/00NG000000EyFpU   how that can be accomplished dynamically through Apex?  Thanks in advance
I am looking for a way to get the 15 character entity ID for a custom field on my Lead object in an Apex controller. I have tried this:  private String getEntityIdFor(String fieldName) {         Map&lt;String, Schema.SObjectField&gt; fieldMap = Schema.SObjectType.Lead.fields.getMap();         return fieldMap.get(fieldName).getDescribe().getId();     }    Of course, there is no getId() method, but this is the closest I got.   Thanks for any help.
How does one prove that the Klein bottle cannot be embedded in $R^3$? I'm talking about smooth embeddings. Finding CPU usage of a service Because my laptop fan was spinning up for no reason, I had a look at the CPU usage and I see  svchost with 12.5% CPU, which is basically a full core.  Now, I'm aware that  svchost runs services and I know how to display the services it runs in Task Manager or Process Explorer ().  Now I know which services are run, but I don't know which service eats the CPU time. I could disable one service after another, but I don't really like doing this (it could break things that are currently in use and I could forget turning the service back on later).  Therefore I'd like to know whether it's possible to instruct Windows to run only one service per svchost the next time I boot my PC. While I might have the slight disadvantage of several processes, I could immediately find out which one it is and it would be a much easier decision of whether or not to stop or restart the service. How can I stop Nautilus from dereferencing symlinks? I use symbolic links to tidy my home folder. This works well in the terminal, since the links create the illusion of normal folders:    In Nautilus, however, the links behave more like , immediately teleporting me to their target:    This is particularly troubling when¹ I later want to navigate "up" to the parent folder, as it strands me somewhere outside of the tree I've carefully tidied.  How can I make Nautilus show symbolic links as normal folders, like the terminal does?  Details   Nautilus did not dereference symlinks in Ubuntu 12.10:   Maybe this new behavior is just a bug? I'm not sure how to tell. Here's what I know:   It's not on the . I've skimmed the  and didn't see anything related. The Nautilus mailing list archive . I received no response from about 120 idlers when posing the question on the GNOME IRC channel. A change was made in Nautilus 3.6 to .  ¹ This is an example. A workaround for this particular scenario does not constitute an answer to my question. Since people seem to be interested in discussing it, though:   Using the Back button is not a suitable workaround; it does not always take me to the parent folder. You can navigate up by pressing Alt+Up. The desired behavior in this example is for "up" to navigate to the parent folder of the symbolic link. The current behavior is to navigate to the parent folder of the target of the symbolic link. How to 'sum' a standard deviation? I have a monthly average for a value and a standard deviation corresponding to that average. I am now computing the annual average as the sum of monthly averages, how can I represent the standard deviation for the summed average ?  For example considering output from a wind farm:  Month        MWh     StdDev January      927     333  February     1234    250 March        1032    301 April        876     204 May          865     165 June         750     263 July         780     280 August       690     98 September    730     76 October      821     240 November     803     178 December     850     250   We can say that in the average year the wind farm produces 10,358 MWh, but what is the standard deviation corresponding to this figure ? Keyboard layout/language changes in every boot CSS :after not adding content to certain elements What is the difference between ANSI/ISO C++ and C++/CLI? Filezilla or WinSCP save password in plain text which is unsecured on public machines. Is there any FTP client can save and encrypt password so that people using it only can access to FTP but not able to see password? Thanks! How do you properly use namespaces in C++? I'm in a freshmen level physics class now, so I don't know much, but something I heard today intrigued me. My TA was talking about how at the research facility he worked at, they were able to accelerate some certain particle to "99.99% the speed of light". I said why not 100%, and I didn't quite understand his explanation, but he said it wasn't possible. This confused me. Since the speed of light is a finite number, why can we go so close to its speed but not quite?  Edit: I read all the answers, and I think I'm sort of understanding it. Another silly question though: If we are getting this particle to 99.99% the speed of light by giving it some sort of finite acceleration, and increasing it more and more, why cant we increase it just a little more? Sorry I know this is a silly question. I totally accept the fact we cant reach 100%, but I'm just trying to break it down. If we've gotten so close by giving it larger and larger acceleration every time, why cant we just supply it with more acceleration? And how much of a difference is there between 99.99% the speed of light, and the speed of light? (I'm not really sure if "difference" is a good word to use, but hopefully you get what I'm asking). Can the Telekinesis spell be used to manipulate liquids? How to create a text file in a folder In windows I right click and then there is an option to create a text file.  How to do so in mac? I know that non-married lovers address each other by saying “This is my girlfriend/boyfriend.” I know that married couples address each other by calling “my wife/husband”.  I also know that gay lovers who are not married (yet?) address each other by saying "my boyfriend" (for gays) and "my girlfriend" (for lesbians).  But if they are married, how do they address each other?  And how do we describe them? I mean if they are gays, are they “husband and husband” or “husband and wife” (one of them acts like the wife)? And if they are lesbians, are they “wife and wife” or “husband and wife” (one of them acts as the husband)?  I know they can be referred to as a gay couple or gay lovers from , but I couldn't find the answer to address each of the two. Why doesn't my flash fire from the hot shoe trigger? I have a Yongnuo YN-560 III and a pair of RF-603II (C3) triggers. I have a Canon Rebel T5i.   I put one trigger on the hot shoe.  When this trigger is in TX mode I get a blue comm light and I can fire a test flash using the large test button on the trigger. But when I press the shutter button to take a picture, there's no flash.  The trigger and flash are on Channel 1. The trigger on the hot shoe is set to TRX. TX is fine, TRX gives me no flash. The flash and camera are in M mode.  I don't have a trigger on the flash because the Mark III has a built-in trigger The problem seems to be the camera.  The trigger can talk to the flash but the camera is not sending a flash command through the trigger in the hot shoe to the flash.  Grateful for anything you could suggest. If $p$ is congruent to $2 \pmod 3$, how can I prove that all $a$, $1 \le a \le p-1$ are cubic residues $\mod p$? If $p$ is congruent to $2 \pmod 3$, how can I prove that all $a$, $1 \le a \le p-1$ are cubic residues $\mod p$?  Here's what I've done:  $1^3$ congruent to $1 \pmod p$ thus, 1 is a cubic residue, Also $(p-1)^3=(p-1) \pmod p$ implies  $$(p-1)^3 - (p-1) = (p-1)[(p-1)^2 -1] = (p-1)(p^2 -2p) = p(p-1)(p-2) $$ implies $$p|(p-1)^3 -(p-1)$$ Thus  $p-1$ is a cubic residue $\mod p$. Now I don't know how to show for $1\lt a \lt p-1$ are all cubic residues when $p$ is congruent to $2\pmod 3$. How do I determine if my integrated Intel graphics support "Shader Model 3"? I am trying to play a Steam game on Ubuntu.  The game requires "Graphics: Shader model 3".  How do I determine if my integrated Intel graphics support Shader Model 3?  At present, when I launch the game, I hear the audio, but the screen is entirely black.  Running glxinfo | grep OpenGL yields:  OpenGL vendor string: Intel Open Source Technology Center OpenGL renderer string: Mesa DRI Intel(R) Haswell Mobile  OpenGL core profile version string: 4.5 (Core Profile) Mesa 18.2.2 OpenGL core profile shading language version string: 4.50 OpenGL core profile context flags: (none) OpenGL core profile profile mask: core profile OpenGL core profile extensions: OpenGL version string: 3.0 Mesa 18.2.2 OpenGL shading language version string: 1.30 OpenGL context flags: (none) OpenGL extensions: OpenGL ES profile version string: OpenGL ES 3.1 Mesa 18.2.2 OpenGL ES profile shading language version string: OpenGL ES GLSL ES 3.10 OpenGL ES profile extensions:   I am not sure which (if any) of the above lines answer my question. What antivirus programs are available for Ubuntu?  We previously used Symantec Endpoint Protection but it does not work in Ubuntu. I'm taking my first crack at  with jQuery. I'm getting my data onto my page, but I'm having some trouble with the JSON data that is returned for Date data types. Basically, I'm getting a string back that looks like this:  /Date(1224043200000)/   From someone totally new to JSON - How do I format this to a short date format? Should this be handled somewhere in the jQuery code? I've tried the jQuery.UI.datepicker plugin using $.datepicker.formatDate() without any success.  FYI: Here's the solution I came up with using a combination of the answers here:  function getMismatch(id) {   $.getJSON("Main.aspx?Callback=GetMismatch",     { MismatchId: id },      function (result) {       $("#AuthMerchId").text(result.AuthorizationMerchantId);       $("#SttlMerchId").text(result.SettlementMerchantId);       $("#CreateDate").text(formatJSONDate(Date(result.AppendDts)));       $("#ExpireDate").text(formatJSONDate(Date(result.ExpiresDts)));       $("#LastUpdate").text(formatJSONDate(Date(result.LastUpdateDts)));       $("#LastUpdatedBy").text(result.LastUpdateNt);       $("#ProcessIn").text(result.ProcessIn);     }   );    return false; }  function formatJSONDate(jsonDate) {   var newDate = dateFormat(jsonDate, "mm/dd/yyyy");   return newDate; }   This solution got my object from the callback method and displayed the dates on the page properly using the date format library. Find the maximum value of $ f(x) = \int^{x}_{0} \sqrt{(x^2-x)^2+y^4}~dy$ Find the maximum value of $f(x)$ when $0 \leq x \leq 1$ and $$ f(x) = \int^{x}_{0} \sqrt{(x^2-x)^2+y^4}~dy$$   I'm guessing that the Fundamental Theorem of Calculus can't be used because the integrand is a function of $x$.  Any help would be greatly appreciated. How to transform negative values to logarithms? I would like to know how to transform negative values to Log(), since I have heteroskedastic data. I read that it works with the formula Log(x+1) but this doesn't work with my database and I continue getting NaNs as result. E.g. I get this Warning message (I didn't put my complete database because I think with one of my negative values is enough to show an example):   &gt; log(-1.27+1) [1] NaN Warning message: In log(-1.27 + 1) : NaNs produced &gt;    Thanks in advance  UPDATE:  Here is an histogram of my data. I'm working with palaeontological time series of chemical measurements, E.g the difference between variables like Ca and Zn is too big, then I need some type of data standardization, that is why I'm testing the log() function.   This is my