javascript – Como crear Boton que muestre día de la semana, correspondiente a fecha seleccionada en Imput Type Date

Hola necesito crear un boton que muestre el día de semana y que se corresponda con la fecha seleccionada a partir de un input type date, estoy usando este código pero no doy con la solución. Soy nueva en este mundo y comenzando en Java. No logro ni siquiera un botón que muestre la fecha. No se que estoy haciendo mal.

          <script type="text/javascript">

function mostrardiasemana(){ 
var d=new Date(document.getElementById("fecha").value);
d.setDate(d.getDay() + 1);

var dia=new Array(7);
var n= dia(d.getDay());

alert("La fecha seleccionada en el elemento fecha es un:" + n)}

<p> Fecha de la Encuesta </p>
                <input type="date" id="fecha" name="fecha" min="2019-01-01"
                  max="2021-12-31" value="2019-01-01"/> 
 <button class="botonera" value="Mostrar Dia Semana" onclick="mostrardiasemana"> Mostrar <br/> Día Semana </button>


Convert from Text to Date in Excel

I need your help in converting text – “Price FOR THE PERIOD 08/01/21 THROUGH 15/01/21 ” to date 15/01/2021.I am using the formula “=DATE(RIGHT(TRIM(RIGHT(SUBSTITUTE(TRIM(Edited!A2),” “,REPT(” “,100)),100))&”20″,4),MID(TRIM(RIGHT(SUBSTITUTE(TRIM(Edited!A2),” “,REPT(” “,100)),100))&”20″,4,2),LEFT(TRIM(RIGHT(SUBSTITUTE(TRIM(Edited!A2),” “,REPT(” “,100)),100))&”20″,2))” but the output i am getting is 15/01/2120 instead of 15/01/2021. Can someone please help on the above? – Zoom Webinars: How to extend end date for recurring series

My organization has several webinars that recur weekly. In order to avoid offering sessions too far in advance, the “End Date” for the recurring webinars is set month-to-month. However, we have recently experienced issues with some sessions extended this way not showing up on the registration page. I’m new to the webinar management team, and I was a bit confused when I went to extend a series and encountered this message:

Registration information for the occurrences that you changed will be removed. If you uncheck this option, registrants of the changed occurrences will not see the registration email and will not be able to join the webinar.

Can someone explain what actually happens when the end date is changed and/or the above option is checked/unchecked? i.e. Are customers “un-registered” every time we change the end date? Is this the reason for our issues with customers not being able to see/register for sessions?

functions – Order column custom date using pre_get_posts

How I want to sort my custom column contain string date with format j F Y

my column data contains string example “21 januari 2021”, how I can change the format to date so I sort it.

My value from postmeta with meta_key “datepicker”.

here my code:

    add_action( 'pre_get_posts', 'manage_wp_posts_be_qe_pre_get_posts', 1 );
function manage_wp_posts_be_qe_pre_get_posts( $query ) {

   if ( $query->is_main_query() && ( $orderby = $query->get( 'orderby' ) ) ) {

      switch( $orderby ) {

         case 'delivery_date':

            // set our query's meta_key, which is used for custom fields
            $query->set( 'meta_key', 'datepicker' );

            $query->set( 'orderby', 'meta_value' );




how I can orderby meta_valuewith format date?

postgresql copy comand with date in filename

I have a query and want the output in a .csv file with today’s date and time in the name (I am using PostgreSQL v12).

(SELECT * FROM mytable)
TO 'C:Usersmemylocationfilename_date_time.csv' CSV HEADER

where date_time is YYYY-MM-DD-h_m_s (or similar)

I have seen some solutions to this using bash. For various reasons I am on a Windows machine with no bash.

I would like to do this using psql please.

mysql – Find max sum of daily total within date range

MYSQL question (NOT spreadsheet question) I’ve been stumped on this for a week (spreadsheet below is just for illustration purposes)

Orders are entered per customer within date range

  • order_number, quantity, start_date, end_date

  • 01, 100, 2021-01-14, 2021-01-16

  • 02, 125, 2021-01-14, 2021-01-16

  • 03, 200, 2021-01-17, 2021-01-23

  • 04, 050, 2021-01-14, 2021-01-19

  • 10, 150, 2021-01-21, 2021-01-16

I need to find the MAX within an entered date range as illustrated in the table below.
ie. I enter variable start_date_search (2021-01-14) and end_date_search (2021-01-23), and I come up with the MAX on any given day within the range (675 in this example below.)

I don’t need to output the totals for each day, but that would be cool too.

data table of reservations by date

group by – Efficient way to get data for each date range intervals using single query | MongoDB

Sorry if I misunderstood or asked a duplicate question!

I have collections about products and purchases. I need to get statistics for each time interval.
I need following:

Name quantity (date 1 range) quantity (date 2 range)
Name One 500 400
Name Two 251 450
Name Three 444 600

I have following collections:

 name: {
    type: String,
    required: (true, "The prodcut name is required"),
    unique: true,
price: {
    type: mongoose.Types.Decimal128,
    default: "0.0",

//Orders model scheme
   product: {
    type: Schema.Types.ObjectId, ref: "Products",
price: {
    type: mongoose.Types.Decimal128,
    default: "0.0",
quantity: {
    type: Number,
    default: 0,
orderDate: {
        type: Date,
        default:, //new Date(),

And I have the following aggregate function:

            { $match: { orderDate: { $gte: new Date( sdt ), $lte: new Date( edt  ) } } },
                    _id: "$product_name", //{ name: "$name"},
                    totalQuantity: { $sum: "$quantity" },
                $project: {
                    _id: 1,
                    qty: "$totalQuantity",

This query is working, but only for one time interval. But I need to get results for some time interval.
But I need to get results for more than one date range interval. I’m new to NoSQL, I’ve tried retrieving data from one or more-time intervals but couldn’t find it. How can I solve this problem? That is, I need to get the sales total Quantity of a product at different time intervals.

2010-01-01 to 2012-01-01
2015-01-01 to 2017-01-01

Time intervals can be dynamic. There can be a minimum of 1 and a maximum of 4 time intervals.
Thanks for answers!

Trying to filter by date range using Query but its not working in google sheets


I am trying to filter data by date range using Query. I want data from 31/12/2019 onwards. This is the formula I used:

=Query(ImportRange("ID", "AvevaGroupPrice"),"select C D WHERE C >= 43830")

I also tried the date formats but it did now work.

I took examples from here and here, and have been following this guide.


Is there a way to only draw data from this date onwards using Query?