sharepoint online – Update People picker column using REST API in Power Automate

Using REST API, You can update People or Group field by setting field with user or group ID.

Considering field name is AssignedTo, the format for user field value:

Single-valued user field: 'AssignedToId' : 1

Multi-valued user field: 'AssignedToId' : { 'results': [1, 2, 3] }

Where 1, 2, 3 are ID of users/groups.

Example:

enter image description here

References:

  1. Update a people field in a SharePoint List using REST API using Power Automate
  2. HOW TO UPDATE THE SHAREPOINT PEOPLE PICKER FIELD USING POWER AUTOMATE

Unable to Download File Update Info

“Unable to Download File Update Info” I keep getting this error message and then SB closes, any idea how to solve this?

What Is New Seo Algorithm Update..?

 

Pattern for a form state/content, after an update data fail

I’m wondering about something: usually when you have a form on your website, a user fills it in then saves it. If the saving operation fails, is considered as a good UX practice the fact of restoring the form with the data that was entered, as the user shouldn’t have to type it again before retry.

That’s the behavior I expect for edit areas, checkboxes and most of UI elements in which can be entered data.

But some days ago, I was using the following kind of element: a dropdown containing a tree, implemented as checkboxes (see picture). I checked all the checkboxes, hitted “save”, which failed. The dropdown remained in the same state, I mean all of the checkboxes that I selected were still selected. “Normal” behavior, as said before.
But it seemed weird to me! And I really don’t know why, I was expecting that the dropdown content would have been “reseted” to its actual state. Why was I thinking that behavior? Am I used to it? From where?

enter image description here

So for now I’m trying to find out some examples, some advices or any other information about: this kind of UI element, your feelings about that or even better your feedback if you have encoutered such a situation.
Thanks!

Settings option has disappeared from the dash as of this morning’s update to 20.10

This morning (2021.01.20) Software Updater suggested some updates to 20.10. I installed them. But now when I go to the dashboard to turn on Bluetooth, ‘settings’ has disappeared.

magento2 – unable to update extension from composer

I am trying to update one of my payment gateway extension through composer and the command is

composer update razorpay/update

But I am getting the below errors

Problem 1
– guzzlehttp/guzzle 7.2.0 requires php ^7.2.5 || ^8.0 -> your PHP version (7.1.33) does not satisfy that requirement.
– guzzlehttp/guzzle 7.1.1 requires php ^7.2.5 -> your PHP version (7.1.33) does not satisfy that requirement.
– guzzlehttp/guzzle 7.1.0 requires php ^7.2.5 -> your PHP version (7.1.33) does not satisfy that requirement.
– guzzlehttp/guzzle 7.0.1 requires php ^7.2.5 -> your PHP version (7.1.33) does not satisfy that requirement.
– guzzlehttp/guzzle 7.0.0 requires php ^7.2.5 -> your PHP version (7.1.33) does not satisfy that requirement.
– Conclusion: don’t install facebook/php-business-sdk 9.0.3
– Conclusion: don’t install facebook/php-business-sdk 9.0.2
– Conclusion: don’t install facebook/php-business-sdk 9.0.1
– Conclusion: remove guzzlehttp/guzzle 6.4.1
– Installation request for facebook/php-business-sdk ^9.0 -> satisfiable by facebook/php-business-sdk(9.0.0, 9.0.1, 9.0.2, 9.0.3).
– Conclusion: don’t install guzzlehttp/guzzle 6.4.1
– facebook/php-business-sdk 9.0.0 requires guzzlehttp/guzzle ^6.5 || ^7.0 -> satisfiable by guzzlehttp/guzzle(6.5.0, 6.5.1, 6.5.2, 6.5.3, 6.5.4, 6.5.5, 7.0.0, 7.0.1, 7.1.0, 7.1.1, 7.2.0).
– Can only install one of: guzzlehttp/guzzle(6.5.0, 6.4.1).
– Can only install one of: guzzlehttp/guzzle(6.5.1, 6.4.1).
– Can only install one of: guzzlehttp/guzzle(6.5.2, 6.4.1).
– Can only install one of: guzzlehttp/guzzle(6.5.3, 6.4.1).
– Can only install one of: guzzlehttp/guzzle(6.5.4, 6.4.1).
– Can only install one of: guzzlehttp/guzzle(6.5.5, 6.4.1).
– Installation request for guzzlehttp/guzzle (locked at 6.4.1) -> satisfiable by guzzlehttp/guzzle(6.4.1)

Previously I am trying to install the Facebook Pixel extension due to some technical issues we didn’t install.
After that when I am trying to install or update the extension I am getting the above error.

For reference please find the attached image.
enter image description here

postgresql – SELECT FOR UPDATE (NOWAIT) on auxilliary table for serializing updates?

Background:

I have an inventory tracking application which needs to avoid the following sort of situation where the same inventory might be used twice due to lack of serialization. The constraint is that each item of inventory from a pool of inventory must in use only once at any given time (much simplified example):

CREATE TABLE inventory_use (id serial, ref varchar);

Transaction 1:
BEGIN;
SELECT * FROM inventory_use;
INSERT INTO inventory_use (ref) VALUES ('T1 insert');

Transaction 2:
BEGIN;
SELECT * FROM inventory_use;
INSERT INTO inventory_use (ref) VALUES ('T2 insert');

Transaction 1:
COMMIT;

Transaction 2:
COMMIT; -- fails (as desired) at SERIALIZABLE, commits (not desired) at REPEATABLE READ

SERIALIZABLE prevents this from occurring by causing the last commit to fail (and REPEATABLE READ does not). However, even though my application does not involve many concurrent writes, I’m reluctant to go for SERIALIZABLE because my understanding of its performance characteristics is weak: I’m not yet confident I know how to predict for example what the effect of concurrent reads or of (read or write) throughput will be on performance, perhaps especially on concurrent transactions that aren’t connected directly with inventory tracking and probably are not critical to the application. Probably I should educate myself more about SERIALIZABLE since it looks very useful, but I’d like to understand the alternatives too.

So this question is about alternative approaches to SERIALIZABLE for this kind of problem, in particular using SELECT FOR UPDATE NOWAIT to serialize inventory tracking updates through row locking while running at the READ COMMITTED isolation level.

What I’ve tried:

I implemented FOR UPDATE NOWAIT locking on the table that records inventory users. That seems to work fine.

However, that may cause trouble because it can block some other updates to that table that need not be serialized. This may well not be critical in my application, but it led me to see if I could use a separate table, created just for the purpose of locking, to do the FOR UPDATE locking. To implement that, before the SELECT FOR UPDATE, I would begin by checking whether an INSERT is needed to represent the pool of inventory whose use needs to be serialized — perhaps via INSERT ... ON CONFLICT DO NOTHING — in order to ensure that there is a suitable row that can be locked to serialize the updates.

Question:

I’ve not been able to find other people using SELECT FOR UPDATE in this style in which:

  1. there is an auxiliary table whose only function is FOR UPDATE row locking, not to store any application data.
  2. FOR UPDATE row locking on existing rows is being used to serialize the creation of new rows

That makes me wonder whether this is a bad way to solve this problem.

I’ve seen other suggested approaches that are similar, for example using REPEATABLE READ with an auxiliary table and using an UPDATE to that table to implicity acquire a lock: https://peter.grman.at/postgres-repeatable-read-vs-serializable/

Is this (the SELECT FOR UPDATE style I describe above) a sensible technique for solving a problem of this kind, and if so, how should it be done? I don’t have specific “how should it be done” issues in mind other than to benefit from experience here.

actions – Run a function when a custom post is update?

I want to run a function when a post is updated. I have tested three 3 hooks for that. I tested post_updated, save_post and wp_insert_post. Neither of those is working. Here is my code:

For wp_insert_post:

function insert_values( $post_id, $post ) {
print_r($post);
if ( $post->post_type == 'product' ) {
    if( $post->post_date != $post->post_modified ){
        echo "Post is updated";         
    }
    else {
        echo "Post is created";     
    }
  }
}
add_action( 'wp_insert_post', 'insert_values', 10, 2 );

For post_updated :

function check_values($post_ID, $post_after, $post_before){
    echo '<b>Post ID:</b><br />';
    var_dump($post_ID);

    echo '<b>Post Object AFTER update:</b><br />';
    var_dump($post_after);

    echo '<b>Post Object BEFORE update:</b><br />';
    var_dump($post_before);
 }
 add_action( 'post_updated', 'check_values', 10, 3 );

For save_post:

function test_save_hook( $post_id, $post, $update ){
    $updated = ($update) ? "updated" : "saved";
    echo "Post type " . $post->post_type . " was " . $updated;
}
add_action( 'save_post', 'test_save_hook', 10, 3 );

Those 3 hooks are not working. It only works when a post is created.

sharepoint online – Update Library name and add library to menu using Power Automate

Stack Exchange Network


Stack Exchange network consists of 176 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange