ORA-00932: inconsistent datatypes: expected CHAR got NUMBER

I am trying to SUBSTR the first 3 character in use this query -> CASE WHEN (RMSTMP_PNG.ota_activity_lotinfo.KEY = ‘TestProgram’) THEN TO_CHAR(SUBSTR(RMSTMP_PNG.ota_activity_lotinfo.VALUE,1,3)) ELSE 0 END AS Test1 But it return me this ORA-00932: inconsistent datatypes: expected CHAR got NUMBER 00932. 00000 – "inconsistent datatypes: expected %s got %s". May i know what wrong in my query? I tried to use To_NUMBER or To CHAR, it also return me same error. Appreciate if someone could help on this issue. Below is my query:

SELECT RMSTMP_PNG.ota_activity.EQP_ID, SUM(CASE WHEN (RMSTMP_PNG.ota_activity.MESSAGE='Load lot success.' AND RMSTMP_PNG.ota_activity_lotinfo.KEY = 'Quantity') THEN 1 ELSE 0 END) AS LOT_ID, SUM(CASE WHEN (RMSTMP_PNG.ota_activity.MESSAGE='Load lot success.' AND RMSTMP_PNG.ota_activity_lotinfo.KEY = 'Quantity') THEN TO_NUMBER(RMSTMP_PNG.ota_activity_lotinfo.VALUE) ELSE 0 END) AS QUANTITY, CASE WHEN (RMSTMP_PNG.ota_activity_lotinfo.KEY = 'TestProgram') THEN TO_CHAR(SUBSTR(RMSTMP_PNG.ota_activity_lotinfo.VALUE,1,3)) ELSE 0 END AS Test1 FROM RMSTMP_PNG.ota_activity  FULL OUTER JOIN RMSTMP_PNG.ota_activity_lotinfo ON RMSTMP_PNG.ota_activity.ID = RMSTMP_PNG.ota_activity_lotinfo.ID  WHERE RMSTMP_PNG.ota_activity.MODIFIED_DATE >= to_date('27-Sep-2020') AND RMSTMP_PNG.ota_activity.MODIFIED_DATE < to_date('27-Sep-2020') + 1  group by RMSTMP_PNG.ota_activity.EQP_ID,RMSTMP_PNG.ota_activity_lotinfo.VALUE, RMSTMP_PNG.ota_activity_lotinfo.KEY order by RMSTMP_PNG.ota_activity.EQP_ID 

Inconsistent spellcasting benefits from prestige classes?

Am I reading these rules right? There seem to be some strange inconsistencies in the benefits some prestige classes grant to the base spellcasting class. Here are some examples, all from the 3.5 DM’s Guide (although the inconsistencies continue in other rulebooks).

Archmage (page 178) buffs spells per day and spells known, but doesn’t mention caster level:

When a new archmage level is gained, the character gains new spells per day (and spells known, if applicable) as if he had also gained a level in whatever arcane spellcasting class in which he could cast 7th-level spells before he added the prestige class level. He does not, however, gain any other benefit a character of that class would have gained (bonus metamagic or item creation feats, and so on).

Eldritch Knight (page 188) buffs spells per day and caster level but doesn’t mention spells known:

From 2nd level on, when a new eldritch knight level is gained, the character gains new spells per day as if she had also gained a level in whatever arcane spellcasting class she belonged to before she added the prestige class. She does not, however, gain any other benefit a character of that class would have gained (bonus metamagic or item creation feats, bard or assassin abilities, and so on). This essentially means that she adds the level of eldritch knight to the level of whatever other arcane spellcasting class the character has, then determines spells per day and caster level accordingly.

Loremaster (page 191) buffs all 3: spells per day, known, and caster level:

A loremaster continues training in magic as well as her field of research. Thus, when a new loremaster level is gained, the character gains new spells per day (and spells known, if applicable) as if she had also gained a level in a spellcasting class she belonged to before she added the prestige class. She does not, however, gain any other benefit a character of that class would have gained (improved chance of controlling or rebuking undead, metamagic or item creation feats, and so on). This essentially means that she adds the level of loremaster to the level of some other spellcasting class the character has, then determines spells per day, spells known, and caster level accordingly.

The possibility of prestige classes that buff all 3 is especially odd in the context of Sorcerers; I see no reason to continue leveling Sorcerer once you qualify for a prestige class. A Sorcerer 10/Loremaster 10 character gets the same spells per day, known, caster level, HD, base attack bonus, and saves (actually, slightly better Will) as a Sorcerer 20, in addition to the Loremaster class features. (By contrast, Wizards get bonus feats, which they’d give up by pursuing Loremaster.)

I misunderstanding the rules somehow?

Are there heuristics in CSP to help avoid redundancy while checking constraints for inconsistent values?

I’m a complete beginner. Please forgive my ignorance.Trying to learn about CSP online, I noticed a lot of the focus on search methods and heuristics which tell you which variable to expand next (e.g. most constrained variable) and those that tell you which value to try first (e.g. least constraining value) but I’ve yet to see heuristics that relate to the ordering of constraints. Since I’m doing everything by hand, I notice a lot of redundancy when eliminating values from variable domains. How do you go about checking for violated constraints in a way that is efficient? Say constraint A will have me eliminate odd numbers 1 to 1000 and constraint B will have me wipe out everything above 250. Intuitively, it feels like order matters as I would waste my time cherry picking even numbers above 250 to only later find out that anything above 250 was not consistent in the first place. I apologize for lacking the proper terminology, my understanding is mostly intuitive. I hope it makes sense. Thanks in advance! I’m mostly looking to acquire a conceptual understanding of selected topics in computer science so if you have book recommendations or any resource that would be appropriate for me as an interested layman, please don’t hesitate!

What is the safe way to update production data if data found inconsistent

I am in a small company and require to fix a bunch of data in production which are inconsistent. I have written the script to handle the fix.

I understand that writing sql to fix data is way more risky than working on fixes normal front end or backend code. For front end or back end, we can write thousands of test code to automatically test result or even little bug the affect might not be as dramatic.

How do you guys fix the data in production normally if many data was inconsistent? Are there any method or strategy which can reduce the risk

Introducing inconsistent controls: is it appropriate for the sake of usability?

We’re building a web application based on Material UI. Throughout the app there are select components, which behave like shown in the example below: The default label informs about the functionality of the select and when a value is selected, this label shrinks and moves up, so that it is still shown above the selected value.

standard use case

We use those components mainly for standard “organizational” bulk operations, such as sort, group etc. Therefore, no value is selected by default, the default label is shown and the user should know what the control is there for.

However, we also have a settings page (and forms), where there are already set values, like language. This leaves the select in the state where that informational default label has already shrinked to its smaller size (and would always stay that way, since a language can’t be unselected).

Because of this, I’d like to change the select component here, so that the label isn’t shown at all and instead introduce another easy-to-read label that is placed above, like shown on the picture below.

pre-select use case

I feel like this would be a good approach in terms of usability, making the controls easier to recognize and thus helping the user change their settings. (Imagine a multitude of settings and looking for a specific one to change).

However, it also introduces inconsistencies, since there would be two kinds of select throughout the application.

I’d like to know whether those kinds of incosistencies are acceptable for the sake of better usability. Do the benefits outweigh the possibility of irritating the user? Maybe you could provide any related research or real life examples of similar inconsistencies for the sake of usability. Maybe there’s even a way to quantify those “pains vs gains”?

Any input is greatly appreciated!

WordPress default Search function inconsistent in WooCommerce Product Titles

I have a custom query searching by Post title keyword for WooCommerce. But some words return no results and some words do. This simple query doesn’t return all words.

Words that work:
Dressing
Square
Sterile

Words that do not work:
Promogran
Oasis
Silver
Drawtex

      /* Get all Products by keyword*/       $  args = array(       'post_type' => 'product',       'posts_per_page' => -1,       's' => $  prodkeywords       );     $  the_query = new WP_Query( $  args );     // Posts are found     if ( $  the_query->have_posts() ) {         while ( $  the_query->have_posts() ) :            $  the_query->the_post();             global $  post;           /* Return Results Here */           endwhile;     } 

Inconsistent link coloring in WordPress editor

I am experiencing inconsistent color styling on <a> tags in the WordPress classic WYSIWYG editor.

If I highlight the text in the link, the editor wraps the inner text in a <span> but if I double click the text it wraps the entire a tag in a span.

Highlight result: <a href=""><span style="color: #f00">Link text</span></a>

Double click result: <span style="color: #f00"><a href="">Link text</a></span>

Example

Ideally what I’d want is the result to be: <a href="" style="color: #f00">Link text</a>

Any help/recommendations would be great!

Weird and Inconsistent Behaviour Syncing Books with iTunes

I have spent quite a bit of time debugging this, and still can’t figure it out.

While debugging, I ended up turning off the “Sync Books” option in iTunes. My iTunes sidebar, after clicking on the phone icon in the top left, would look like this,

Screenshot of iTunes Sidebar

except for one thing – every other time I would sync, the “Books” entry in the “Settings” section would be missing. (In order to make the “Books” entry appear or disappear, it was necessary to quit iTunes, and restart it – just leaving iTunes running and syncing again wouldn’t do it.)

I figured out how to make this strange phenomenon stop – I opened the Book app on the phone. Even though “Sync Books” was turned off, I could see all my books. If I set the phone in aeroplane mode, though, I was unable to access them, so I guess they are in iCloud rather than stored locally.

Once I did this, the “Books” entry in the “Settings” section of the sidebar seemed to become permanent. However, there is still bizarre oscillating behaviour. Every other time I run iTunes, if I click on the phone icon, and then the “Books” entry in the “Settings” section, I see this on the right.

Empty book list

So no books at all. Every other time, I see this.

Full book list

That is, the books are all there.

Checking the “Sync books” box launches me into yet another cycle. The first sync seems normal enough, but after that, every time iTunes starts, I get this pop-up window asking me to transfer purchased items from the phone to iTunes.

Transfer purchased items

This window now comes up every time, despite choosing “transfer” the time before. During the sync, 73 books (out of 74) are transferred from the phone to the computer. But it, doesn’t matter, the next time, I am asked again. There is still cyclical behaviour here – every other time, clicking on the “Books” entry in the “Settings” section of the sidebar results in zero books displayed on the right side at the beginning of the sync, and 73 books at the end of the sync. But the other times iTunes is started, there is one book displayed on the right side at the beginning of the sync (the one I was last reading), and 74 books at the end of the sync.

Opening the Books app on the phone, at various points in the cycle, does not seem to change behaviour. Clicking “Don’t Transfer” launches me into another weird alternating cycle, which I can describe further if needed.

What could possibly be going on here? Has anyone seen anything like this, or know how to fix it?

In all cases, the oscillating behaviour occurs when the iTunes program is closed and started again. Just clicking on “Sync” again doesn’t do it.

iPhone 6s plus – iOS 12.3.1 iTunes 12.9.5.5 on recent MacBook Pro

Inconsistent package.xml – Magento 1

I tried finding a Slack or Discord server for Magento before coming here.

I am trying to submit a Magento 1 extension for technical review @ marketplace and the package.xml won’t pass marketplace validation. I manually fixed specific fields that failed, but the error is now Repo rejected file upload - Failed.

The error is a bit abstract, but I’m pretty sure it’s related to the package.xml. I regenerated it for post-1.5 releases via Magento Connect (running on Magento 1.9.4.1), but the generated XML is quite different than the previous one, and I can’t seem to find anything useful in official docs.

The previous XML had a calculated hash for each file under contents, the current one has only one hash.

Can someone explain the difference(s) between https://github.com/sendwithus/extension-magento/blob/master/dist/package.xml and https://github.com/meanbee/magento-diymage/blob/master/package.xml?