Every time that I try to set the caption of this variable, it gives me “unspecified error” and I have concluded… I’ve tried to set the caption straight from the TADOQuery and by assigning the value …
Join two table with specific conditions in mysql
I have two table Table 1: (user) id,name,username,password table 2: (order) id,user,status status column have two value: 1(cancel order) or 2(success order) I want show all user list with order …
specific select within sql server
I have a table vbap : For all distinct POSNR, PARVW, I need to check if POSNR=POSNR2, if it’s the case I select KUNNR. if POSNR<>POSNR2 and POSNR2 =’00000′ I select KUNNR Result: I didn’t …
Update jsonb column with value from row_to_json()
I have a table containing a data that look like: col1 col2 col3 col4 json_data —————————————————- a b c d {“mock”:”…
Change empty string to NULL when column has DATE constraint
This might be impossible but I was wondering if someone more experienced knew if this is possible to do in postgresql. I have a column in my create statement CREATE table IF NOT EXISTS (other cols, …
Get totals from difference between rows
I have a table, with the following structure: ( id SERIAL PRIMARY KEY, user_id integer NOT NULL REFERENCES user(id) ON UPDATE CASCADE, status text NOT NULL, created_at timestamp with …
Getting first two unique records from two table joined – Mysql
Table 1: employee_detail: id name 1 ABC 2 CCC 3 FFF 4 ggg 5 jjj Table 2: performance_appraisal id …
Error 424 object required after NULL SQL query
I am running some EXCEL VBA code to update the contents of an ACCESS database table along the lines suggested here: IF @@Rowcount = 0 — SQL Syntax Error in Access . When I execute the SELECT query, …
How to SUM multiple DECODE values?
I have the following decodes in my SELECT case: DECODE (table_name, ‘RECHNUNG’, SUM(beleg_betrag_offen) ) as re_be_of, DECODE (table_name, ‘GUTSCHRIFT’, SUM(beleg_betrag_offen) ) as gs_be_of, DECODE (…
Replace text from VIEW Definition
I have the following VIEW definition: create view v_1 as select * from t1 where [date] between ‘2010-01-01’ and ‘2019-01-01’ union all select * from t2 where [date] between ‘2012-01-01’ and ‘2019-01-…