{"id":5325,"date":"2014-03-30T20:43:27","date_gmt":"2014-03-30T20:43:27","guid":{"rendered":"https:\/\/unknownerror.org\/index.php\/2014\/03\/30\/problem-about-case-sensitive-collection-of-common-programming-errors\/"},"modified":"2022-08-30T15:47:14","modified_gmt":"2022-08-30T15:47:14","slug":"problem-about-case-sensitive-collection-of-common-programming-errors","status":"publish","type":"post","link":"https:\/\/unknownerror.org\/index.php\/2014\/03\/30\/problem-about-case-sensitive-collection-of-common-programming-errors\/","title":{"rendered":"problem about case-sensitive-Collection of common programming errors"},"content":{"rendered":"<ul>\n<li><img decoding=\"async\" src=\"http:\/\/www.gravatar.com\/avatar\/d4a28b46d4ac5f2cc601f588becf9f74?s=32&amp;d=identicon&amp;r=PG\" \/><br \/>\nHonza Javorek<br \/>\nmysql regex case-sensitive case-insensitive<br \/>\nI use regular expressions in MySQL on multibyte-encoded (utf-8) data, but I need it to be match case-insensitively. As MySQL has bug (for many years unresolved) that it can&#8217;t deal properly with matching multibyte-encoded strings case-insensitively, I am trying to simulate the &#8220;insensitiveness&#8221; by lowercasing the value and the regexp pattern. Is it safe to lowercase regexp pattern such way? I mean, are there any edge cases I forgot?Could following cause any problems?LOWER(&#8216;s\u00e1rKA&#8217;) = REGEXP LOWER(<\/li>\n<li><img decoding=\"async\" src=\"http:\/\/www.gravatar.com\/avatar\/8fdf1ac64238f4b04c5e490e47859617?s=32&amp;d=identicon&amp;r=PG&amp;f=1\" \/><br \/>\nuser3371139<br \/>\nc# select datatable case-sensitive camelcasing<br \/>\nI am performing a search on a DataTable and am getting unexpected results. The table contains a column called Name. One of the rows contains the value &#8220;MustHaveRings&#8221; for the Name column. Both the DataSet and DataTable have the CaseSensitive property set to false which should perform a case-insensitive search.When I perform the search with the following, no rows are returned which is unexpected.string input = &#8220;musthaverings&#8221;; var foundRows = ds.Tables[5].Select(&#8220;Name= &#8216;&#8221; + input + &#8220;&#8216;&#8221;);After exp<\/li>\n<li><img decoding=\"async\" src=\"http:\/\/www.gravatar.com\/avatar\/8d9d863d04f5bae9e73ff1d2c4a92c82?s=32&amp;d=identicon&amp;r=PG\" \/><br \/>\nClayton Hughes<br \/>\nbash case-sensitive tr<br \/>\nI&#8217;m trying to make a convenience function to fix issues when I accidentally have my caps locks on and am trying to run some case-sensitive tools.e.g. I occasionally find myself typing MAKE DEBUG instead of make debug.What I have now is pretty straightforward: alias MAKE=&#8221;make&#8221; and editing the makefiles to duplicate the rules, e.g. DEBUG: debug.I&#8217;d prefer a solution that works on the arguments, without having to modify the tools involved.<\/li>\n<li><img decoding=\"async\" src=\"http:\/\/www.gravatar.com\/avatar\/52b6e4f1831bcd153f645a14f29aa185?s=32&amp;d=identicon&amp;r=PG\" \/><br \/>\nNick Craver<br \/>\njquery contains case-sensitive case-insensitive<br \/>\nI&#8217;m trying to use &#8220;contains&#8221; case insensitively. I tried using the solution at the following stackoverflow question, but it didn&#8217;t work:Is there a case insensitive jQuery :contains selector?For convenience, the solution is copied here:jQuery.extend(jQuery.expr[&#8216;:&#8217;], { Contains : &#8220;jQuery(a).text().toUpperCase().indexOf(m[3].toUpperCase())&gt;=0&#8221; });Here is the error:Error: q is not a function Source File: \/js\/jquery-1.4.js?ver=1.4 Line: 81Here&#8217;s where I&#8217;m using it:$(&#8216;input.preset&#8217;).keyup(functio<\/li>\n<li><img decoding=\"async\" src=\"http:\/\/www.gravatar.com\/avatar\/090c675ed8bd4dc75f7b313074e7a26d?s=32&amp;d=identicon&amp;r=PG\" \/><br \/>\nShiki<br \/>\nosx mac tar case-sensitive compression<br \/>\nI have a Linux tarball that can&#8217;t be unpacked. It gives me an unexpected error. I am told this is due to case insensitive on MAC OS X. How can I untar this file?tar -zxvf file.tar.gz &#8230; x output\/common.xml tar: Error exit delayed from previous errors.<\/li>\n<li><img decoding=\"async\" src=\"http:\/\/www.gravatar.com\/avatar\/a648ccb47bbbe9497c073315aac4d33e?s=32&amp;d=identicon&amp;r=PG\" \/><br \/>\nJoachim Sauer<br \/>\njava linux case-sensitive filenotfoundexception<br \/>\nMy web application runs on Windows. I would like to run my app on Linux also. I seem to have overcome most of the problems such as path separator, etc. Real problem now is I get FileNotFoundException when the Java code tries to open a file say Abc.txt when only abc.txt exists. :(I can&#8217;t go on changing all the filenames to lowercase or uppercase as i have a whole lot of files. Without changing code much is that any possible way to avoid this?<\/li>\n<li><img decoding=\"async\" src=\"http:\/\/www.gravatar.com\/avatar\/78a0a4bb106d07b6c6f33a51988155e3?s=32&amp;d=identicon&amp;r=PG\" \/><br \/>\nPeter Mortensen<br \/>\nvb.net vba case-sensitive case-insensitive<br \/>\nI&#8217;m not trying to start an argument here, but for whatever reason it&#8217;s typically stated that Visual Basic is case insensitive and C languages aren&#8217;t (and somehow that is a good thing).But here&#8217;s my question: Where exactly is Visual Basic case insensitive? When I type&#8230;Dim ss As String Dim SS As String&#8230;into the Visual\u00a0Studio\u00a02008 or Visual Studio 2010 IDE, the second one has a warning of &#8220;Local variable SS is already declared in the current block&#8221;. In the VBA VBE, it doesn&#8217;t immediat<\/li>\n<li><img decoding=\"async\" src=\"http:\/\/www.gravatar.com\/avatar\/dc69af7dd7151a00843602888638fabb?s=32&amp;d=identicon&amp;r=PG\" \/><br \/>\nNick Johnson<br \/>\npython unicode case-sensitive<br \/>\nI&#8217;m making a Google AppEngine Application. Does the Python 2.5.2 runtime environment follow the Unicode Standards? (For example, the lower() and upper() methods on unicode objects.)<\/li>\n<li><img decoding=\"async\" src=\"http:\/\/www.gravatar.com\/avatar\/1eaa94cb676b57eca63e0723787bd16b?s=32&amp;d=identicon&amp;r=PG\" \/><br \/>\ndr. evil<br \/>\nvb.net comparison like case-sensitive<br \/>\nIs there anyway to use LIKE operator in VB.NET as case sensitive or insensitive during runtime? For example use a flag to do case sensitive or insensitive comparisons.Obviously this can be done by simple converting them into lower case and forcing application to Option Compare Binary but maybe there is a better way to do this?<\/li>\n<li><img decoding=\"async\" src=\"http:\/\/www.gravatar.com\/avatar\/fa4abc5a6682c36b15205e8e88d68ec1?s=32&amp;d=identicon&amp;r=PG\" \/><br \/>\nSherlock<br \/>\nwindows case-sensitive<br \/>\nI&#8217;ve got serious troubles with Windows 7 not having a case-sensitive file system. I&#8217;m the only developer who&#8217;s working on Windows in my team (and we wanna keep it that way for cross-OS checks), and I&#8217;m the one producing occasional errors due to Windows not crashing on files with different cases.Is there any way to make Windows go crazy when I try to include &#8216;aSdF.php&#8217; where I meant &#8216;asdf.php&#8217;?<\/li>\n<li><img decoding=\"async\" src=\"http:\/\/www.gravatar.com\/avatar\/d8238ae773f9d75e510abe305209189f?s=32&amp;d=identicon&amp;r=PG\" \/><br \/>\ntrusktr<br \/>\nwindows-7 windows filesystems ntfs case-sensitive<br \/>\nI want to make Windows 7 case-sensitive when it reads\/writes anything on the hard drive (the C drive, or any other NTFS drive).I found a video via google that says to change the registry keyHKEY_CURRENT_USER\\Software\\Microsoft\\Windows\\CurrentVersion\\Explorer\\Advanced\\DontPrettyPathto a value of 1 (source).I also found a Windows support item that says something about modifying the registry keyHKLM\\SYSTEM\\CurrentControlSet\\Control\\Session Manager\\kernel\\obcaseinsensitivethat leads me to assume put<\/li>\n<li><img decoding=\"async\" src=\"http:\/\/www.gravatar.com\/avatar\/5b1ee6ff5efd7c20047d2bb93b5c20c6?s=32&amp;d=identicon&amp;r=PG\" \/><br \/>\nPallavi<br \/>\niphone case-sensitive<br \/>\nI am a starter in iPhone. I wanted to do case-insensitive search. Database helper used: Core Data. Following is my code:-(WebAttendee *) FindAttendeeBy:(NSString *) badgeID_{AppDelegate_Shared *delegate1 = [[UIApplication sharedApplication]delegate];badgeID_=[badgeID_ stringByReplacingOccurrencesOfString:@&#8221;\\\\&#8221; withString:@&#8221;\\\\\\\\&#8221;];badgeID_=[badgeID_ stringByReplacingOccurrencesOfString:@&#8221;&#8216;&#8221; withString:@&#8221;\\\\'&#8221;];self.managedObjectContext = delegate1.managedObjectContext;return (WebAttendee *)[self F<\/li>\n<li><img decoding=\"async\" src=\"http:\/\/www.gravatar.com\/avatar\/b6116ac3c4b5835c6745570ea73a85c1?s=32&amp;d=identicon&amp;r=PG\" \/><br \/>\nCharles<br \/>\nzend-framework migration case-sensitive controllers<br \/>\nI&#8217;m getting the following error migrating my code across from my Windows dev machine to my linxu production machine. I&#8217;m aware there are always separator and case sensitivity issues (which I have fixed), however this one seems to be coming from the Framework itself. My controllers are all following the convention (Uppercase first camel).I&#8217;m using the bootstrap provided by Zend_App and this is all working (well with no errors) on my dev box.Its parsing Plugins, however can&#8217;t seem to get to contro<\/li>\n<li><img decoding=\"async\" src=\"http:\/\/i.stack.imgur.com\/A9Ov3.jpg?s=32&amp;g=1\" \/><br \/>\ndrudge<br \/>\nphp header case-sensitive array-key<br \/>\nUpdated Question:When using get_headers() with the format option to use named array keys (rather than numbered keys), how can I account for situations like the server using Content-type rather than Content-Type?Original Question: PHP problem getting header of a file that has a colon in url Hi, I am having trouble retrieving header information of a remote url which has a colon in it. I have tried using urldecode and it decodes %3A into :, however it does not solve the problem. What to do? This ur<\/li>\n<li><img decoding=\"async\" src=\"http:\/\/www.gravatar.com\/avatar\/eb12cd42a3508351122a02dbc0c4f186?s=32&amp;d=identicon&amp;r=PG\" \/><br \/>\nRobert Koritnik<br \/>\njquery case-sensitive attr<br \/>\nI have a select element with few custom attributes that I use to validate it on the fly and display appropriate messages. Attribute&#8217;s name is camel cased as in&lt;select validationMessage=&#8221;Must select something&#8221; &#8230; &gt;&#8230;The problem is that in jQuery version older than 1.6 .attr() seems to be case sensitive. What&#8217;s even more problematic, that it won&#8217;t fetch originally cased attributes. This works the same in Firefox in Chrome, but works as expected (case insensitive as it should be) in Interne<\/li>\n<li><img decoding=\"async\" src=\"http:\/\/www.gravatar.com\/avatar\/294278694c313539a55cd2ddbfb4b13a?s=32&amp;d=identicon&amp;r=PG\" \/><br \/>\nCoder<br \/>\nphp case-sensitive array-key<br \/>\nAm using DB2 with my PHP. DB2 returns all column names in UPPERCASE. If I use db2_fetch_assoc, then the result would be like thisArray { [USERID] =&gt; 4 }But in my php file, the array values assigned like this and its in camelstyle$this-&gt;userId = $row[&#8216;userId&#8217;];So it throws the error Error : Undefined index userIdI can use array_change_key_case() function to convert the array to lowercase. But I have hundreds of files which get and assign the array values. Its not possible to change in all o<\/li>\n<li><img decoding=\"async\" src=\"http:\/\/www.gravatar.com\/avatar\/7504b530d1df33b972a3431d3640f618?s=32&amp;d=identicon&amp;r=PG\" \/><br \/>\nChris Travers<br \/>\nphp exception yii case-sensitive<br \/>\nI&#8217;ve just moved my site from developing on my mac with sqlite to putting it on a shared host running linux with postgres.The static pages display fine, but as soon as I display anything dynamic, I get a CDbException:CDbCommand failed to execute the SQL statement: SQLSTATE[42P01]: Undefined table: 7 ERROR: missing FROM-clause entry for table &#8220;assetchanges&#8221;I seems to be either due to case sensitivity or quotes around the table\/column aliases.How can I start to fix these issues? Where do I look? Wh<\/li>\n<li><img decoding=\"async\" src=\"http:\/\/www.gravatar.com\/avatar\/862008df68d24dde3ec3a1d3bf1be8fa?s=32&amp;d=identicon&amp;r=PG\" \/><br \/>\nnaitsirch<br \/>\nphp mysql doctrine case-sensitive<br \/>\nI have a problem with the case of a column name in Doctrine version 1.1.0.I have a record (entity) with this definition:abstract class BaseProductsXsell extends Doctrine_Record {public function setTableDefinition(){$this-&gt;setTableName(&#8216;products_xsell&#8217;);$this-&gt;hasColumn(&#8216;ID&#8217;, &#8216;integer&#8217;, 4, array(&#8216;type&#8217; =&gt; &#8216;integer&#8217;, &#8216;length&#8217; =&gt; 4, &#8216;primary&#8217; =&gt; true, &#8216;autoincrement&#8217; =&gt; true));$this-&gt;hasColumn(&#8216;products_id&#8217;, &#8216;integer&#8217;, 4, array(&#8216;type&#8217; =&gt; &#8216;integer&#8217;, &#8216;length&#8217; =&gt; 4, &#8216;unsigne<\/li>\n<\/ul>\n<p>Web site is in building<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Honza Javorek mysql regex case-sensitive case-insensitive I use regular expressions in MySQL on multibyte-encoded (utf-8) data, but I need it to be match case-insensitively. As MySQL has bug (for many years unresolved) that it can&#8217;t deal properly with matching multibyte-encoded strings case-insensitively, I am trying to simulate the &#8220;insensitiveness&#8221; by lowercasing the value and the [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1,8],"tags":[],"class_list":["post-5325","post","type-post","status-publish","format-standard","hentry","category-uncategorized","category-zend-framework"],"_links":{"self":[{"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/posts\/5325","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/comments?post=5325"}],"version-history":[{"count":1,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/posts\/5325\/revisions"}],"predecessor-version":[{"id":8948,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/posts\/5325\/revisions\/8948"}],"wp:attachment":[{"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/media?parent=5325"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/categories?post=5325"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/unknownerror.org\/index.php\/wp-json\/wp\/v2\/tags?post=5325"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}