skip to Main Content

addressing month date issue – PHP

$myDate = date('m-d-Y 00:00:00', strtotime($myDate)); if($debugs)echo"<br>myDate is: $myDate in line: ".__line__."<br>"; $mysqlstart = date('Y-m-d 00:00:00', strtotime($myDate)); if($debugs)echo"<br>mysqlstart is: $mysqlstart in line: ".__line__."<br>"; From the code above, I would like to show $myDate to the audience while passing $mysqlstart into a…

VIEW QUESTION

SQL Server: convert JSON variable to XML

I have a variable which contains a single JSON object like declare @jsonVar nvarchar(max) = N'{"key1":"value1","key2":"value2"}'; I need to convert it to XML and get something like this (or without 'root' at all) <root> <key1>value1</key1> <key2>value2</key2> </root> The solution should…

VIEW QUESTION

How to Join 2 table with json key in Postgres? – Postgresql

I have 2 table CREATE TABLE json_data_table(d_id int, d1_json json, d2_json json); CREATE TABLE user_data(uid int, username varchar); and data respectively are INSERT INTO user_data VALUES (1,'test_user_1'), (2,'test_user_2'), (3,'test_user_3'); INSERT INTO json_data_table VALUES (1,'{"stage1":1,"stage2":2 }', '{ "stage1": { "date": "12-01-2023",…

VIEW QUESTION
Back To Top
Search